Interface ISvgContext

Hierarchy

Index

Properties

Methods

Properties

optional public alias?: Array<string>

[Config Option] (String[])

optional public alternateClassName?: any

[Config Option] (String/String[])

optional public config?: any

[Config Option] (Object)

optional public extend?: string

[Config Option] (String)

optional public inheritableStatics?: any

[Config Option] (Object)

optional public mixins?: any

[Config Option] (Object)

optional public platformConfig?: any

[Config Option] (Object)

optional public self?: IClass

[Property] (Ext.Class)

optional public singleton?: boolean

[Config Option] (Boolean)

optional public statics?: any

[Config Option] (Object)

optional public uses?: Array<string>

[Config Option] (String[])

Methods

optional public arc(x?: any, y?: any, radius?: any, startAngle?: any, endAngle?: any, anticlockwise?: any)

[Method] Adds points to the subpath such that the arc described by the circumference of the circle described by the arguments

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

  • radius?: any optional

    Object

  • startAngle?: any optional

    Object

  • endAngle?: any optional

    Object

  • anticlockwise?: any optional

    Object

optional public arcSvg(r1?: any, r2?: any, rotation?: any, large?: any, swipe?: any, x2?: any, y2?: any)

[Method] Arc command using svg parameters

Parameters

  • r1?: any optional

    Object

  • r2?: any optional

    Object

  • rotation?: any optional

    Object

  • large?: any optional

    Object

  • swipe?: any optional

    Object

  • x2?: any optional

    Object

  • y2?: any optional

    Object

optional public arcTo(x1?: any, y1?: any, x2?: any, y2?: any, radiusX?: any, radiusY?: any, rotation?: any)

[Method] Adds an arc with the given control points and radius to the current subpath connected to the previous point by a str

Parameters

  • x1?: any optional

    Object

  • y1?: any optional

    Object

  • x2?: any optional

    Object

  • y2?: any optional

    Object

  • radiusX?: any optional

    Object

  • radiusY?: any optional

    Object

  • rotation?: any optional

    Object

optional public beginPath()

[Method] Resets the current default path

optional public bezierCurveTo(x1?: any, y1?: any, x2?: any, y2?: any, x3?: any, y3?: any)

[Method] Adds the given point to the current subpath connected to the previous one by a cubic B zier curve with the given con

Parameters

  • x1?: any optional

    Object

  • y1?: any optional

    Object

  • x2?: any optional

    Object

  • y2?: any optional

    Object

  • x3?: any optional

    Object

  • y3?: any optional

    Object

optional public callOverridden(args?: any): any

[Method] Call the original method that was previously overridden with override This method is deprecated as callParent does

Parameters

  • args?: any optional

    Array/Arguments The arguments, either an array or the arguments object from the current method, for example: this.callOverridden(arguments)

Returns

any

Object Returns the result of calling the overridden method

optional public callParent(args?: any): any

[Method] Call the parent method of the current method

Parameters

  • args?: any optional

    Array/Arguments The arguments, either an array or the arguments object from the current method, for example: this.callParent(arguments)

Returns

any

Object Returns the result of calling the parent method

optional public callSuper(args?: any): any

[Method] This method is used by an override to call the superclass method but bypass any overridden method

Parameters

  • args?: any optional

    Array/Arguments The arguments, either an array or the arguments object from the current method, for example: this.callSuper(arguments)

Returns

any

Object Returns the result of calling the superclass method

optional public clear()

[Method] Clears the context

optional public closePath()

[Method] Marks the current subpath as closed and starts a new subpath with a point the same as the start and end of the newly

optional public createLinearGradient(x0?: any, y0?: any, x1?: any, y1?: any): IGradient

[Method] Returns an object that represents a linear gradient that paints along the line given by the coordinates represented b

Parameters

  • x0?: any optional

    Object

  • y0?: any optional

    Object

  • x1?: any optional

    Object

  • y1?: any optional

    Object

Returns

IGradient

Ext.draw.engine.SvgContext.Gradient

optional public createRadialGradient(x0?: any, y0?: any, r0?: any, x1?: any, y1?: any, r1?: any): IGradient

[Method] Returns a CanvasGradient object that represents a radial gradient that paints along the cone given by the circles rep

Parameters

  • x0?: any optional

    Object

  • y0?: any optional

    Object

  • r0?: any optional

    Object

  • x1?: any optional

    Object

  • y1?: any optional

    Object

  • r1?: any optional

    Object

Returns

IGradient

Ext.draw.engine.SvgContext.Gradient

optional public destroy()

[Method]

optional public drawImage(image?: any, sx?: any, sy?: any, sw?: any, sh?: any, dx?: any, dy?: any, dw?: any, dh?: any)

[Method] Draws the given image onto the canvas

Parameters

  • image?: any optional

    Object

  • sx?: any optional

    Object

  • sy?: any optional

    Object

  • sw?: any optional

    Object

  • sh?: any optional

    Object

  • dx?: any optional

    Object

  • dy?: any optional

    Object

  • dw?: any optional

    Object

  • dh?: any optional

    Object

optional public ellipse(x?: any, y?: any, radiusX?: any, radiusY?: any, rotation?: any, startAngle?: any, endAngle?: any, anticlockwise?: any)

[Method] Adds points to the subpath such that the arc described by the circumference of the ellipse described by the arguments

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

  • radiusX?: any optional

    Object

  • radiusY?: any optional

    Object

  • rotation?: any optional

    Object

  • startAngle?: any optional

    Object

  • endAngle?: any optional

    Object

  • anticlockwise?: any optional

    Object

optional public fill()

[Method] Fills the subpaths of the current default path or the given path with the current fill style

optional public fillRect(x?: any, y?: any, width?: any, height?: any)

[Method] Paints the given rectangle onto the canvas using the current fill style

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

  • width?: any optional

    Object

  • height?: any optional

    Object

optional public fillStroke(attr?: any, transformFillStroke?: boolean)

[Method] Note After the method guarantees the transform matrix will be inverted

Parameters

  • attr?: any optional

    Object The attribute object

  • transformFillStroke?: boolean optional

    Boolean Indicate whether to transform fill and stroke. If this is not given, then uses attr.transformFillStroke instead.

optional public fillText(text?: any, x?: any, y?: any)

[Method] Fills the given text at the given position

Parameters

  • text?: any optional

    Object

  • x?: any optional

    Object

  • y?: any optional

    Object

optional public getInitialConfig(name?: string): any

[Method] Returns the initial configuration passed to constructor

Parameters

  • name?: string optional

    String When supplied, value for particular configuration option is returned, otherwise the full config object is returned.

Returns

any

Object/Mixed

optional public initConfig(instanceConfig?: any): any

[Method] Initialize configuration for this class

Parameters

  • instanceConfig?: any optional

    Object

Returns

any

Object mixins The mixin prototypes as key - value pairs

optional public lineTo(x?: any, y?: any)

[Method] Adds the given point to the current subpath connected to the previous one by a straight line

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

optional public moveTo(x?: any, y?: any)

[Method] Creates a new subpath with the given point

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

optional public rect(x?: any, y?: any, width?: any, height?: any)

[Method] Adds a new closed subpath to the path representing the given rectangle

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

  • width?: any optional

    Object

  • height?: any optional

    Object

optional public restore()

[Method] Pops the state stack and restores the state

optional public save()

[Method] Pushes the context state to the state stack

optional public setTransform(xx?: any, yx?: any, xy?: any, yy?: any, dx?: any, dy?: any)

[Method] Changes the transformation matrix to the matrix given by the arguments as described below

Parameters

  • xx?: any optional

    Object

  • yx?: any optional

    Object

  • xy?: any optional

    Object

  • yy?: any optional

    Object

  • dx?: any optional

    Object

  • dy?: any optional

    Object

optional public stroke()

[Method] Strokes the subpaths of the current default path or the given path with the current stroke style

optional public strokeRect(x?: any, y?: any, width?: any, height?: any)

[Method] Paints the box that outlines the given rectangle onto the canvas using the current stroke style

Parameters

  • x?: any optional

    Object

  • y?: any optional

    Object

  • width?: any optional

    Object

  • height?: any optional

    Object

optional public strokeText(text?: any, x?: any, y?: any)

[Method] Strokes the given text at the given position

Parameters

  • text?: any optional

    Object

  • x?: any optional

    Object

  • y?: any optional

    Object

optional public transform(xx?: any, yx?: any, xy?: any, yy?: any, dx?: any, dy?: any)

[Method] Changes the transformation matrix to apply the matrix given by the arguments as described below

Parameters

  • xx?: any optional

    Object

  • yx?: any optional

    Object

  • xy?: any optional

    Object

  • yy?: any optional

    Object

  • dx?: any optional

    Object

  • dy?: any optional

    Object