SVGTextPathElement

The SVGTextPathElement interface corresponds to the <textPath> element.

Constants

Method types

Name Value Description
TEXTPATH_METHODTYPE_UNKNOWN 0 The 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.
TEXTPATH_METHODTYPE_ALIGN 1 Corresponds to the value align.
TEXTPATH_METHODTYPE_STRETCH 2 Corresponds to the value stretch.

Spacing types

Name Value Description
TEXTPATH_SPACINGTYPE_UNKNOWN 0 The 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.
TEXTPATH_SPACINGTYPE_AUTO 1 Corresponds to the value auto.
TEXTPATH_SPACINGTYPE_EXACT 2 Corresponds to the value exact.

Properties

This interface also inherits properties from its parent interface, SVGTextContentElement, and also implements properties of SVGURIReference.

SVGTextPathElement.startOffset Read only
An SVGAnimatedLength corresponding to the X component of the startOffset attribute of the given element.
SVGTextPathElement.method Read only
An SVGAnimatedEnumeration corresponding to the method attribute of the given element. It takes one of the TEXTPATH_METHODTYPE_* constants defined on this interface.
SVGTextPathElement.spacing Read only
An SVGAnimatedEnumeration corresponding to the spacing attribute of the given element. It takes one of the TEXTPATH_SPACINGTYPE_* constants defined on this interface.

Methods

This interface does not provide any specific methods, but implements those of its parent, SVGTextContentElement, and also implements methods of SVGURIReference.

Specifications

Specification Status Comment
Scalable Vector Graphics (SVG) 2
The definition of 'SVGTextPathElement' in that specification.
Candidate Recommendation No change
Scalable Vector Graphics (SVG) 1.1 (Second Edition)
The definition of 'SVGTextPathElement' in that specification.
Recommendation Initial definition

Browser compatibility

DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
SVGTextPathElementChrome Full support YesEdge Full support 12Firefox Full support YesIE Full support YesOpera Full support YesSafari Full support YesWebView Android Full support YesChrome Android Full support YesFirefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android Full support Yes
methodChrome Full support YesEdge Full support 12Firefox Full support YesIE ? Opera Full support YesSafari Full support YesWebView Android Full support YesChrome Android Full support YesFirefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android Full support Yes
spacingChrome Full support YesEdge Full support 12Firefox Full support YesIE ? Opera Full support YesSafari Full support YesWebView Android Full support YesChrome Android Full support YesFirefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android Full support Yes
startOffsetChrome Full support YesEdge Full support 12Firefox Full support YesIE ? Opera Full support YesSafari Full support YesWebView Android Full support YesChrome Android Full support YesFirefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android Full support Yes

Legend

Full support
Full support
Compatibility unknown
Compatibility unknown

See also