Class: xrx.svg.Line

xrx.svg. Line

(private) new xrx.svg.Line(element)

SVG class representing a line.
Parameters:
Name Type Description
element SVGLineElement The SVG line element.
Source:

Extends

Members

xrx.svg.Line#element_ :SVGElement

The SVG element.
Type:
  • SVGElement
Inherited From:
Source:

Methods

(static) xrx.svg.Line.create()

Creates a new poly-line.
Source:

xrx.svg.Line#draw(x1, y1, x2, y2, strokeColor, strokeWidth)

Draws this line.
Parameters:
Name Type Description
x1 number The x coordinate of the start point.
y1 number The y coordinate of the start point.
x2 number The x coordinate of the end point.
y2 number The y coordinate of the end point.
strokeColor string The stroke color.
strokeWidth number The stroke width.
Source:

xrx.svg.Line#getElement() → {SVGElement}

Returns the SVG element.
Inherited From:
Source:
Returns:
The SVG element.
Type
SVGElement

xrx.svg.Line#setCoords(x1, y1, x2, y2)

Sets the coordinates for this line.
Parameters:
Name Type Description
x1 number The x coordinate of the start point.
y1 number The y coordinate of the start point.
x2 number The x coordinate of the end point.
y2 number The y coordinate of the end point.
Source:

xrx.svg.Line#setFillColor(color)

Sets the fill color of the stylable element.
Parameters:
Name Type Description
color string The fill color.
Inherited From:
Source:

xrx.svg.Line#setFillOpacity(factor)

Sets the fill opacity of the stylable element.
Parameters:
Name Type Description
factor number The fill opacity.
Inherited From:
Source:

xrx.svg.Line#setStrokeColor(color)

Sets the stroke color of the stylable element.
Parameters:
Name Type Description
color string The stroke color.
Inherited From:
Source:

xrx.svg.Line#setStrokeWidth(width)

Sets the stroke width of the stylable element.
Parameters:
Name Type Description
width number The stroke width.
Inherited From:
Source:

(private) xrx.svg.Line#strokeAndFill_()

Inherited From:
Source: