Search results

SvgRenderer

Properties

height

number

Specifies the height of the canvas element.

Defaults to null

width

number

Specifies the width of the canvas element.

Defaults to null

Methods

createCanvas

To create a Html5 canvas element Dummy method for using canvas/svg render in the same variable name in chart control

Returns HTMLCanvasElement

createClipPath

To create clip path in SVG

Parameter Type Description
options BaseAttibutes Options needed to create clip path

Returns Element

createDefs

To create defs element in SVG

Returns Element

createForeignObject

To create foreign object in SVG

Parameter Type Description
options BaseAttibutes Options needed to create foreign object

Returns Element

createGroup

To create group element in SVG

Parameter Type Description
options BaseAttibutes Options needed to create group

Returns Element

createLinearGradient

To create linear gradient in SVG

Parameter Type Description
colors GradientColor[] Array of string specifies the values for color
name string Specifies the name of the gradient
options LinearGradient Specifies the options for gradient

Returns string

createPattern

To create pattern in SVG

Parameter Type Description
options PatternAttributes Required options to create pattern in SVG
element string Specifies the name of the pattern

Returns Element

createRadialGradient

To create radial gradient in SVG

Parameter Type Description
colors GradientColor[] Specifies the colors required to create radial gradient
name string Specifies the name of the gradient
options RadialGradient value for radial gradient

Returns string

createSvg

To create a Html5 SVG element

Parameter Type Description
options SVGAttributes Options to create SVG

Returns Element

createTSpan

To create a tSpan

Parameter Type Description
options TextAttributes Options to create tSpan
label string The text content which is to be rendered in the tSpan

Returns Element

createText

To draw a text

Parameter Type Description
options TextAttributes Options needed to draw a text in SVG
label string Label of the text

Returns Element

createTitle

To create a title

Parameter Type Description
text string The text content which is to be rendered in the title

Returns Element

drawCircle

To draw a circle

Parameter Type Description
options CircleAttributes Required options to draw a circle in SVG

Returns Element

drawCircularClipPath

To create circular clip path in SVG

Parameter Type Description
options CircleAttributes Options required to create circular clip path

Returns Element

drawClipPath

To render a clip path

Parameter Type Description
options BaseAttibutes Options required to render a clip path

Returns Element

drawEllipse

To draw an ellipse

Parameter Type Description
options EllipseAttributes Options required to draw an ellipse

Returns Element

drawGradient

To render the gradient element in SVG

Parameter Type Description
gradientType string Specifies the type of the gradient
options RadialGradient | LinearGradient Options required to render a gradient
colors GradientColor[] Array of string specifies the values for color

Returns Element

drawImage

To draw an image

Parameter Type Description
options ImageAttributes Required options to draw an image in SVG

Returns Element

drawLine

To draw a line

Parameter Type Description
options LineAttributes Options to draw a line in SVG

Returns Element

drawPath

To draw a path

Parameter Type Description
options PathAttributes Options to draw a path in SVG

Returns Element

drawPolygon

To draw a polygon

Parameter Type Description
options PolylineAttributes Options needed to draw a polygon in SVG

Returns Element

drawPolyline

To draw a polyline

Parameter Type Description
options PolylineAttributes Options required to draw a polyline

Returns Element

drawRectangle

To draw a rectangle

Parameter Type Description
options RectAttributes Required options to draw a rectangle in SVG

Returns Element

setElementAttributes

To set the attributes to the element

Parameter Type Description
options SVGCanvasAttributes Attributes to set for the element
element Element | HTMLElement The element to which the attributes need to be set

Returns Element | HTMLElement