Closed Bug 1715387 Opened 3 years ago Closed 3 years ago

Need to flush style if GetOrBuildPathForMeasuring() is called from WebIDL

Categories

(Core :: SVG, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
97 Branch
Tracking Status
firefox97 --- fixed

People

(Reporter: boris, Assigned: boris)

References

Details

Attachments

(1 file)

Bug 1340422 makes d attribute as a presentation attribute, so we get the svg path from style. However, we have to make sure we flush the style if the API is called from WebIDL. For example, SVGPathElement::GetOrBuildPathForMeasuring() may be called from internal or WebIDL, so we have to make sure we flush the style well from the caller if necessary. Also, we may have to add some tests to make sure it works properly.

See https://phabricator.services.mozilla.com/D115566#inline-649699 for more detail.

Blocks: 1744599
Assignee: nobody → boris.chiou
Status: NEW → ASSIGNED

In order to make sure these APIs work properly, we have to flush style before
building the path to make sure the d property is up-to-date.

  1. isPointInFill()
  2. isPointInStroke()
  3. getTotalLength()
  4. getPointAtLength()
  5. getPathSegAtLength() (note: Legacy API, only Gecko and WebKit support.)
Pushed by bchiou@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/72adcadcd2fd Flush style properly for DOM APIs which use d property. r=jwatt,hiro,emilio
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 97 Branch
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/32054 for changes under testing/web-platform/tests
Upstream PR merged by moz-wptsync-bot
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: