[Webkit-unassigned] [Bug 252903] [SVG] The `getBoundingBox` of a non-empty SVG element is 0x0

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 24 08:50:12 PST 2023


https://bugs.webkit.org/show_bug.cgi?id=252903

--- Comment #1 from cathiechen <cathiechen at igalia.com> ---
According to [1],

> Web content can also contain SVG elements. SVG elements that do not have associated CSS layout boxes define bounding box instead of a content box. Content rect for the SVGGraphicsElements without CSS layout boxes is a rect whose:
> width is bounding box width
> height is bounding box height

So from ResizeObserver size, it is correct to call `downcast<SVGElement>(*m_target).getBoundingBox()` in `ResizeObservation::computeObservedSizes()`.

I'll leave this bug to an SVG Expert.

[1] https://drafts.csswg.org/resize-observer/

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20230224/2d963f72/attachment.htm>


More information about the webkit-unassigned mailing list