ICanvasDrawingStyles class

ICanvasDrawingStyles class

The ICanvasDrawingStyles interface provides methods and properties control how lines are drawn and how text is laid out.

The ICanvasDrawingStyles type exposes the following members:

Properties

PropertyDescription
line_widthWidth of lines. Default 1.0
line_capType of endings on the end of lines. Possible values: butt (default), round, square.
line_joinDefines the type of corners where two lines meet. Possible values: round, bevel, miter (default).
miter_limitMiter limit ratio. Default 10.
line_dash_offsetSpecifies where to start a dash array on a line.
fontFont setting. Default value 10px sans-serif
text_alignText alignment setting. Possible values: start (default), end, left, right or center.
text_baselineBaseline alignment setting. Possible values: top, hanging, middle, alphabetic (default), ideographic, bottom.

Methods

MethodDescription
set_line_dashSets the current line dash pattern.
get_line_dashReturns the current line dash pattern array containing an even number of non-negative numbers.

See Also