Bug 6487

Summary: "Make Text Bigger/Smaller" affects SVGs when it probably shouldn't
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: SVGAssignee: Rob Buis <rwlbuis>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: ahmad.saleem792, bfulgham, eoconnor, ian, kling, sabouhallawa, simon.fraser, zimmermann
Priority: P4    
Version: 420+   
Hardware: Mac   
OS: OS X 10.4   
See Also: https://bugs.webkit.org/show_bug.cgi?id=76162
https://bugs.webkit.org/show_bug.cgi?id=259435
Attachments:
Description Flags
First attempt
none
Better approach
none
Now with the right patch... none

Description Eric Seidel (no email) 2006-01-10 21:30:04 PST
"Make Text Bigger/Smaller" affects SVGs when it probably shouldn't

I know that FireFox also has this "problem".  I'm not sure what the right solution here is.  Should we zoom 
the whole SVG?  Should we disable text zoom, or should we leave it as is?
Comment 1 John Sullivan 2006-01-11 06:28:25 PST
We decided to make these menu items be equivalents for zoom in/out in PDF, though the concepts are of 
course not exactly the same. Doing the same thing for SVG seems sensible.
Comment 2 Rob Buis 2007-05-15 01:00:28 PDT
Created attachment 14559 [details]
First attempt

How this option now works is not intuitive IMHO, either the whole svg should zoom in/out or this setting should be ignored, but just zooming svg text only clearly is wrong. This patch turns this behaviour off, thus no SVG text is affected by zoomFactor. Note that I think the patch still allows html text in foreignObject to zoom.
Note that this setting feels similar to zooming and panning, I made a patch for that and will attach it to another bug report soon (will make a reference here). These subjects could be dependent.
Cheers,

Rob.
Comment 3 Dave Hyatt 2007-05-15 01:04:28 PDT
We have a CSS property that can turn off text zoom.  We use it in Safari RSS.  It's called -webkit-text-size-adjust.  Not sure if it would be helpful for you or not, but it is there and usable.
Comment 4 Rob Buis 2007-05-15 02:17:20 PDT
Created attachment 14561 [details]
Better approach

I think Dave's approach is better as it doesnt require extra #if ENABLE(SVG).
Cheers,

Rob.
Comment 5 Dave Hyatt 2007-05-15 02:22:19 PDT
Did you attach the wrong patch here?
Comment 6 Rob Buis 2007-05-15 02:27:56 PDT
Created attachment 14562 [details]
Now with the right patch...

Doh!
Cheers,

Rob.
Comment 7 Dave Hyatt 2007-05-15 02:41:00 PDT
Comment on attachment 14562 [details]
Now with the right patch...

r=me
Comment 8 Rob Buis 2007-05-15 02:55:03 PDT
Landed in r21482.
Comment 9 Andreas Kling 2013-03-07 14:10:44 PST
I'm removing -webkit-text-size-adjust in bug 56543, and this patch to svg.css is effectively reverted. However, I don't see any difference in SVG text behavior (with text-only zoom) before/after, so I'm not sure it was even needed anymore.

@Rob, do we need to do anything with this?
Comment 10 Rob Buis 2013-03-07 14:24:29 PST
Hi Andreas,

(In reply to comment #9)
> I'm removing -webkit-text-size-adjust in bug 56543, and this patch to svg.css is effectively reverted. However, I don't see any difference in SVG text behavior (with text-only zoom) before/after, so I'm not sure it was even needed anymore.
> 
> @Rob, do we need to do anything with this?

If the behavior is the same after your patch, I am fine with the "revert". I guess a lot changed since 2007 :)
Comment 11 Darin Adler 2013-05-08 09:05:40 PDT
Comment on attachment 14562 [details]
Now with the right patch...

Clearing the review flag so this does not show up as a “patch reviewed but not landed” any more.
Comment 12 Ahmad Saleem 2023-01-07 09:48:21 PST
Comment 08 mention that this landed in 2007 and then got reverted in 2013 as per Comment 09 and the behavior was pre and post revert was same, do we need to track this anymore? Thanks!
Comment 13 Ahmad Saleem 2023-07-31 16:11:39 PDT

*** This bug has been marked as a duplicate of bug 59435 ***