SVG path segment interface
The SVGMarkerElement interface corresponds to the marker element.
Interface overview
| Also implement | None |
|---|---|
| Methods |
|
| Properties |
|
| Constants |
|
| Normative document | SVG 1.1 (2nd Edition) |
Constants
Orientation
| Name | Value | Description |
|---|---|---|
SVG_MARKER_ORIENT_UNKNOWN |
0 | The marker orientation is not one of predefined types. It is invalid to attempt to define a new value of this type or to attempt to switch an existing value to this type. |
SVG_MARKER_ORIENT_AUTO |
1 | Attribute orient has value 'auto'. |
SVG_MARKER_ORIENT_ANGLE |
2 | Attribute orient has an angle value. |
Units
| Name | Value | Description |
|---|---|---|
SVG_MARKERUNITS_UNKNOWN |
0 | The marker unit type is not one of predefined types. It is invalid to attempt to define a new value of this type or to attempt to switch an existing value to this type. |
SVG_MARKERUNITS_USERSPACEONUSE |
1 | Attribute markerUnits is 'userSpaceOnUse'. |
SVG_MARKERUNITS_STROKEWIDTH |
2 | Attribute markerUnits is 'strokeWidth'. |
Properties
This interface also inherits properties from its parent interface, SVGElement, and implements properties from SVGExternalResourcesRequired, SVGAnimatedPreserveAspectRatio, and SVGStylable.
| Name | Type | Description |
|---|---|---|
refX |
SVGAnimatedLength |
Corresponds to attribute refX on the given marker element. |
refY |
SVGAnimatedLength |
Corresponds to attribute refY on the given marker element. |
markerUnits |
SVGAnimatedEnumeration |
Corresponds to attribute markerUnits on the given marker element. One of the Marker Unit Types defined on this interface. |
markerWidth |
SVGAnimatedLength |
Corresponds to attribute markerWidth on the given marker element. |
markerHeight |
SVGAnimatedLength |
Corresponds to attribute markerHeight on the given marker element. |
orientType |
SVGAnimatedEnumeration |
Corresponds to attribute orient on the given marker element. One of the Marker Orientation Types defined on this interface. |
orientAngle |
SVGAnimatedAngle |
Corresponds to attribute orient on the given marker element. If markerUnits is SVG_MARKER_ORIENT_ANGLE, the angle value for attribute orient; otherwise, it will be set to zero. |
Methods
This also inherits methods from its parent, SVGElement, and implements properties from SVGStylable.
setOrientToAngle(in SVGAngle angle) |
|
void |
Sets the value of attribute Exceptions:
|
setOrientToAuto() |
|
void |
Sets the value of attribute Exceptions:
|
Browser compatibility
| Desktop | Mobile | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
SVGMarkerElement |
Chrome ? | Edge ? | Firefox ? | IE ? | Opera ? | Safari ? | WebView Android ? | Chrome Android ? | Firefox Android ? | Opera Android ? | Safari iOS ? | Samsung Internet Android ? |
Legend
- Full support
- Full support
- No support
- No support
- Compatibility unknown
- Compatibility unknown
