W3cubDocs

/DOM

SVGGeometryElement.isPointInStroke

The SVGGeometryElement.isPointInStroke() method determines whether a given point is within the stroke shape of an element. Normal hit testing rules apply; the value of the pointer-events property on the element determines whether a point is considered to be within the stroke. The point argument is interpreted as a point in the local coordiante system of the element.

Syntax

boolean someElement.isPointInStroke(DOMPoint point);

Parameters

point
A DOMPoint interpreted as a point in the local coordinate system of the element.

Return value

A boolean indicating whether the given point is within the stroke or not.

Specifications

Specification Status Comment
Scalable Vector Graphics (SVG) 2
The definition of 'SVGGeometryElement.isPointInStroke()' in that specification.
Candidate Recommendation Initial definition

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support Yes ? No ? Yes ?
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support Yes Yes ? No Yes ? ?

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/SVGGeometryElement/isPointInStroke