[Webkit-unassigned] [Bug 37515] getPathSegAtLength() gives incorrect value

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri May 7 19:51:23 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=37515


Robin Qiu <robin.qiu at torchmobile.com.cn> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #55096|0                           |1
        is obsolete|                            |




--- Comment #5 from Robin Qiu <robin.qiu at torchmobile.com.cn>  2010-05-07 19:51:23 PST ---
Created an attachment (id=55450)
 --> (https://bugs.webkit.org/attachment.cgi?id=55450)
Modified according to Niko's comment.

This bug is just a misktake: almost all of the code is OK, but the parameter is
not used at all, therefore, this function always returns "1".

Another tiny problem is that the SVG spec says the index of the first path
segment is number 0, but we start from number 1.
(By the way, Firefox starts from 1 as well), So I added this code to let it
start from 0. 

+        if (!segmentLength)
+            continue

Here is a question, does "M0 0 L5 5 L5 5 L10 10" equal to "M0 0 L5 5 L10 10" ? 
If not, those two line code I added is incorrect, I will put it right.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list