Bug 11979

Summary: SVG text does not respect font-size scaling in bbox calculation
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: SVGAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: zimmermann
Priority: P2 Keywords: SVGHitList
Version: 420+   
Hardware: Mac   
OS: OS X 10.4   
Attachments:
Description Flags
test demonstrating the incorrect behavior
none
Another test showing how bad our current behavior is none

Description Eric Seidel (no email) 2006-12-26 07:48:16 PST
SVG text does not respect font-size scaling in bbox calculation

See attached testcase.  After fixing bug 11973 our behavior is slightly better than before, but GREEN is still not entirely green.
Comment 1 Eric Seidel (no email) 2006-12-26 07:48:51 PST
Created attachment 12028 [details]
test demonstrating the incorrect behavior
Comment 2 Eric Seidel (no email) 2006-12-26 08:40:03 PST
Created attachment 12032 [details]
Another test showing how bad our current behavior is
Comment 3 Eric Seidel (no email) 2006-12-26 11:17:04 PST
Ok, so this is going to be harder to fix than I originally thought.

This should be split into two bugs.  One to cover the text gradient painting issue, and another to cover text having broken bounding box code.

The problem with gradients is not related to how text calculates bounding boxes, but rather due to the SVG text painting system.  SVG Text makes manual calls into SVGPaintServer::setup() and SVGPaintServer::teardown() instead of calling paint().  SVGPaintServerGradientCG isn't exactly designed for this code path.  The whole SVG text/paintserver interaction looks to be kinda a hack (certainly I am not w/o blame here :), and likely needs to be redesigned.  One example would be passing some sort of "painting text" bool to setup/teardown instead of setting a bool on the paintserver.  Another would be fixing the whole fill/stroke at once problem which we've talked about for so long.
Comment 4 Eric Seidel (no email) 2006-12-26 11:23:54 PST
Comment on attachment 12032 [details]
Another test showing how bad our current behavior is

obsoleting this test as it does not apply to this bug.  I've filed http://bugs.webkit.org/show_bug.cgi?id=11984 to track fixing this test case.
Comment 5 Eric Seidel (no email) 2007-01-07 01:54:51 PST
Wildfox has done some investigation here.
Comment 6 Eric Seidel (no email) 2007-01-08 16:41:10 PST
Fixed by bug 11984.

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