Bug 19814

Summary: getComputedTextLength always returns 0 with tspan elements
Product: WebKit Reporter: John Moe <john>
Component: SVGAssignee: Nikolas Zimmermann <zimmermann>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, w.tscheschner
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
Attachments:
Description Flags
Example
none
Testcase none

Description John Moe 2008-06-29 11:16:47 PDT
getComputedTextLength always returns 0 with tspan elements.  FF3 does not.
Comment 1 John Moe 2008-06-29 11:18:24 PDT
Created attachment 21997 [details]
Example

Should alert the same number twice.  Instead will be 42 (or so) and then 0.
Comment 2 Eric Seidel (no email) 2008-07-03 21:50:13 PDT
Yup.  Looks like a real bug.  Thanks for the simple example.
Comment 3 Willi Tscheschner 2009-06-09 08:32:57 PDT
Can confirm this bug.

We use the tspan.getComputedTextLength() function for a manual word wrap of a label. Due to the returned 0 our word wrap does not work at all in Webkit. This is a major issue for us and we'd appreciate it to be fixed somewhere in the near future...
Comment 4 Nikolas Zimmermann 2011-04-06 00:42:46 PDT
Created attachment 88380 [details]
Testcase

Bug is resolved in trunk since a while, we forgot to close this bug report.
Nevertheless, I've modified the attached testcase to be a real layout test, and I'd like to land it.
Dirk, can you check?
Comment 5 Dirk Schulze 2011-04-06 01:59:57 PDT
Comment on attachment 88380 [details]
Testcase

r=me
Comment 6 WebKit Commit Bot 2011-04-06 02:24:41 PDT
Comment on attachment 88380 [details]
Testcase

Clearing flags on attachment: 88380

Committed r83035: <http://trac.webkit.org/changeset/83035>
Comment 7 WebKit Commit Bot 2011-04-06 02:24:47 PDT
All reviewed patches have been landed.  Closing bug.