(private) new xrx.svg.Image(element)
SVG class representing an image.
Parameters:
| Name | Type | Description |
|---|---|---|
element |
SVGImageElement | The SVG image element. |
Extends
Members
-
xrx.svg.Image#element_ :SVGElement
-
The SVG element.
Type:
- SVGElement
- Inherited From:
- Source:
Methods
-
(static) xrx.svg.Image.create()
-
Creates a new image.
-
xrx.svg.Image#draw(image)
-
Draws the image.
Parameters:
Name Type Description imageHTMLImageElement The image to draw. Make sure that image has naturalWidth and naturalHeight attributes. -
xrx.svg.Image#getElement() → {SVGElement}
-
Returns the SVG element.
- Inherited From:
- Source:
Returns:
The SVG element.- Type
- SVGElement
-
xrx.svg.Image#setFillColor(color)
-
Sets the fill color of the stylable element.
Parameters:
Name Type Description colorstring The fill color. - Inherited From:
- Source:
-
xrx.svg.Image#setFillOpacity(factor)
-
Sets the fill opacity of the stylable element.
Parameters:
Name Type Description factornumber The fill opacity. - Inherited From:
- Source:
-
(private) xrx.svg.Image#setHeight()
-
xrx.svg.Image#setImage(image)
-
Sets a new HTML image element.
Parameters:
Name Type Description imageImage The HTML image element. -
xrx.svg.Image#setStrokeColor(color)
-
Sets the stroke color of the stylable element.
Parameters:
Name Type Description colorstring The stroke color. - Inherited From:
- Source:
-
xrx.svg.Image#setStrokeWidth(width)
-
Sets the stroke width of the stylable element.
Parameters:
Name Type Description widthnumber The stroke width. - Inherited From:
- Source:
-
(private) xrx.svg.Image#setWidth()
-
(private) xrx.svg.Image#strokeAndFill_()
-
- Inherited From:
- Source: