SVGPathElement.getPointAtLength() method returns the point at a given distance along the path.

注意: In SVG 2 this property was moved to the SVGGeometryElement interface, from which the SVGPathElement inherits it.

句法

SVGPoint someElement.getPointAtLength(float distance);
					

参数

distance

A float referring to the distance along the path.

返回值

SVGPoint indicating the point at a given distance along the path.

规范

规范 状态 注释
Scalable Vector Graphics (SVG) 1.1 (Second Edition)
The definition of 'SVGPathElement.getTotalLength()' in that specification.
推荐 初始定义

浏览器兼容性

The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request. 更新 GitHub 上的兼容性数据
桌面 移动
Chrome Edge Firefox Internet Explorer Opera Safari Android webview Chrome for Android Firefox for Android Opera for Android Safari on iOS Samsung Internet
getPointAtLength 弃用 Chrome Yes Edge 12 Firefox Yes
Yes
From version 53, this method is defined on the parent SVGGeometryElement 接口。
IE Yes Opera Yes Safari Yes WebView Android Yes Chrome Android Yes Firefox Android Yes
Yes
From version 53, this method is defined on the parent SVGGeometryElement 接口。
Opera Android ? Safari iOS ? Samsung Internet Android Yes

图例

完整支持

完整支持

兼容性未知 ?

兼容性未知

弃用。不要用于新网站。

弃用。不要用于新网站。

见实现注意事项。

另请参阅

元数据

  • 最后修改: