Closed Bug 905122 Opened 11 years ago Closed 11 years ago

SVG getScreenCTM() seems to be broken or at least changed in Firefox 23 on nested SVG.

Categories

(Core :: SVG, defect)

23 Branch
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: huebner, Unassigned)

References

()

Details

(Keywords: regression)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 6.2; WOW64; rv:24.0) Gecko/20100101 Firefox/24.0 (Beta/Release) Build ID: 20130806170643 Steps to reproduce: try to paint a rectangle: http://svg-edit.googlecode.com/svn/branches/2.6/editor/svg-editor.html Actual results: getScreenCTM() is called on the nested svg#svgcontent to calculate the coords and this returns other values than in Firefox 22 and Chrome. Expected results: The rectangle should be painted at the position of the mouse cursor.
Component: Untriaged → SVG
Product: Firefox → Core
Regression window(m-c) Good: http://hg.mozilla.org/mozilla-central/rev/c8e47b184aba Mozilla/5.0 (Windows NT 6.1; WOW64; rv:23.0) Gecko/20130505 Firefox/23.0 ID:20130505000859 Bad: http://hg.mozilla.org/mozilla-central/rev/b109e2dbf03b Mozilla/5.0 (Windows NT 6.1; WOW64; rv:23.0) Gecko/20130505 Firefox/23.0 ID:20130505171547 Pushlog: http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=c8e47b184aba&tochange=b109e2dbf03b Regression window(m-i) Good: http://hg.mozilla.org/integration/mozilla-inbound/rev/87ee7b242241 Mozilla/5.0 (Windows NT 6.1; WOW64; rv:23.0) Gecko/20130505 Firefox/23.0 ID:20130505000858 Bad: http://hg.mozilla.org/integration/mozilla-inbound/rev/745a6846cf43 Mozilla/5.0 (Windows NT 6.1; WOW64; rv:23.0) Gecko/20130505 Firefox/23.0 ID:20130505002546 Pushlog: http://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=87ee7b242241&tochange=745a6846cf43 Regressed by: b8b048e24dcd Robert Longson — Bug 863994 - Support transform attribute on <svg> elements. r=dholbert
Blocks: 863994
Attached image testcase
It changed, and as far as I can see it's now correct. Try the testcase in Opera and it gives 1 0 0 1 **1** 0 for the first case but the markup is the same for all elements. The elements co-ordinates should not be included in getScreenCTM.
Status: UNCONFIRMED → RESOLVED
Closed: 11 years ago
Resolution: --- → INVALID
If you want the x and y co-ordinates in the CTM then create a child element and get the screenCTM of that.
While I agree that the new behavior is better in terms of consistency with the "from user space" concept, the old, unpleasant inclusion of the x/y values is at least interoperable across browsers. We should consider what we can do to go back to the old behavior I suspect. huebner, in the meantime you probably want to change svg-edit to use Robert's suggestion from comment 3. Calling getScreenCTM on a child <g> should give the same result in all browsers as the old behavior of calling it on the <svg>.
Status: RESOLVED → UNCONFIRMED
Resolution: INVALID → ---
I'll hold off requesting tracking for now to see if we get any more reports.
Keywords: regression
OS: Windows 8 → All
Hardware: x86_64 → All
Looks like svg-edit will be fixing things on their end, perhaps we can just leave things as they are in that case.
svg-edit is fixed now so perhaps we can mark this invalid (again).
(In reply to Robert Longson from comment #8) > svg-edit is fixed now so perhaps we can mark this invalid (again). confirmed. It works. http://hg.mozilla.org/releases/mozilla-esr24/rev/d06a17a96fa2 Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Firefox/24.0 ID:20140131092626 https://hg.mozilla.org/mozilla-central/rev/31113754db3b Mozilla/5.0 (Windows NT 6.1; WOW64; rv:30.0) Gecko/20100101 Firefox/30.0 ID:20140224030203
Status: UNCONFIRMED → RESOLVED
Closed: 11 years ago11 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: