[Webkit-unassigned] [Bug 7430] New: Unitless numbers (floats) incorrectly treated as strings in CSS DOM

bugzilla-daemon at opendarwin.org bugzilla-daemon at opendarwin.org
Thu Feb 23 10:51:18 PST 2006


http://bugzilla.opendarwin.org/show_bug.cgi?id=7430

           Summary: Unitless numbers (floats) incorrectly treated as strings
                    in CSS DOM
           Product: WebKit
           Version: 420+ (nightly)
          Platform: Macintosh
        OS/Version: Mac OS X 10.4
            Status: UNCONFIRMED
          Severity: minor
          Priority: P2
         Component: CSS
        AssignedTo: webkit-unassigned at opendarwin.org
        ReportedBy: bfults at gmail.com


CSS styles exposed through the DOM should be treated as numbers (floats
specifically) when the style takes a unitless float value.

A simple example of this is opacity:

el.style.opacity = 0.3; //works fine
el.style.opacity = 1.3877787807814457e-16; // fails -- Webkit invalidates the
style altogether (yielding opacity == 1.0)

This will also fail for values specified in octal or hexadecimal, as they are
treated as strings.

This does work as expected in Firefox 1.5 (converting the numbers), however.


-- 
Configure bugmail: http://bugzilla.opendarwin.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list