WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
37325
SVG Padding stops mouse events
https://bugs.webkit.org/show_bug.cgi?id=37325
Summary
SVG Padding stops mouse events
Peter Josling
Reported
2010-04-09 03:33:20 PDT
Creating an SVG image with padding (ie <svg style = "padding:10px" etc.) causes onclick/onmousedown/onmouseover etc events to stop working. The image still displays properly, but mouse events do not register.
Attachments
A simple SVG image with a rectangle - alert box appears on click. Works as expected
(303 bytes, image/svg+xml)
2010-06-01 09:58 PDT
,
Peter Josling
no flags
Details
Same image as before - but style="padding:100px;" added to the SVG element. Rectangle no longer responds to click.
(327 bytes, image/svg+xml)
2010-06-01 09:59 PDT
,
Peter Josling
no flags
Details
Fix SVG hit testing when padding is present and add associated test
(3.52 KB, patch)
2011-11-14 19:13 PST
,
Philip Rogers
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Dirk Schulze
Comment 1
2010-05-09 23:19:57 PDT
Peter, can you add a simple test case to this bug please?
Peter Josling
Comment 2
2010-06-01 09:58:21 PDT
Created
attachment 57555
[details]
A simple SVG image with a rectangle - alert box appears on click. Works as expected
Peter Josling
Comment 3
2010-06-01 09:59:15 PDT
Created
attachment 57556
[details]
Same image as before - but style="padding:100px;" added to the SVG element. Rectangle no longer responds to click.
Peter Josling
Comment 4
2010-06-01 09:59:40 PDT
Added test case
Philip Rogers
Comment 5
2011-11-14 19:13:36 PST
Created
attachment 115086
[details]
Fix SVG hit testing when padding is present and add associated test
Nikolas Zimmermann
Comment 6
2011-11-15 06:20:13 PST
Comment on
attachment 115086
[details]
Fix SVG hit testing when padding is present and add associated test View in context:
https://bugs.webkit.org/attachment.cgi?id=115086&action=review
Looks great to me, please update the comment and land manually, or reuploaded it and I'll set the flags again.
> Source/WebCore/rendering/svg/RenderSVGRoot.cpp:431 > // Note: For now, we're ignoring hits to border and padding for <svg>
This comment is invalid now, no?
Philip Rogers
Comment 7
2011-11-15 06:23:39 PST
(In reply to
comment #6
)
> (From update of
attachment 115086
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=115086&action=review
> > Looks great to me, please update the comment and land manually, or reuploaded it and I'll set the flags again. > > > Source/WebCore/rendering/svg/RenderSVGRoot.cpp:431 > > // Note: For now, we're ignoring hits to border and padding for <svg> > > This comment is invalid now, no?
I think it's still valid, it was just implemented wrong. We still do ignore mouse movements on the padding and borders of a SVG element, but now the positioning is correct so we don't account for the padding twice.
Nikolas Zimmermann
Comment 8
2011-11-15 06:29:25 PST
Comment on
attachment 115086
[details]
Fix SVG hit testing when padding is present and add associated test Fair enough, cq+ then.
WebKit Review Bot
Comment 9
2011-11-15 07:38:24 PST
Comment on
attachment 115086
[details]
Fix SVG hit testing when padding is present and add associated test Clearing flags on attachment: 115086 Committed
r100280
: <
http://trac.webkit.org/changeset/100280
>
WebKit Review Bot
Comment 10
2011-11-15 07:38:28 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug