Open Bug 1917324 Opened 1 year ago Updated 7 months ago

Firefox disagrees with other browsers on getBBox() results, when viewBox transforms are involved

Categories

(Core :: SVG, defect)

defect

Tracking

()

People

(Reporter: dholbert, Unassigned, NeedInfo)

References

(Blocks 1 open bug, )

Details

(Keywords: webcompat:platform-bug)

User Story

user-impact-score:60

Attachments

(1 file)

[spinning this off as the underlying platform bug behind bug 1893281]

STR:

  1. Load https://bug1893281.bmoattachments.org/attachment.cgi?id=9422610
  2. Look at the values in the alert(), and compare to other browsers

ACTUAL RESULTS:
Firefox gives me:
-2461.079833984375 -20775.599609375 16518.87890625 54525.1015625

EXPECTED RESULTS:
Chromium and WebKit (epiphany / gnome-web) give me:
-2461.079833984375 -20775.599609375 14468.4423828125 34832.453125

Notably, the 3rd and 4th components (the width and height) differ by quite a lot.

longsonr provided this context in bug 1893281 comment 9, as the reason behind the difference here:

We think a viewBox transform only applies to your children, chrome does not do that though and applies it to the element itself as well (at least when returning the bounding box). We don't think that makes sense because a viewBox doesn't change the element's bounds, it changes its children.

Jonathan, Robert, how do we make progress on this?

Flags: needinfo?(longsonr)
Flags: needinfo?(jwatt)
User Story: (updated)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: