This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
According to CSS2, <number> could be an <integer>[1]. So the following style sheet is valid CSS2: E { line-height:1; } Reproducable: Always Steps to reproduce: 1. http://jigsaw.w3.org/css-validator/validator?text=E+%7B+line-height%3A1%3B+%7D&usermedium=all Actual results: "Invalid number : line-height Parse Error - [empty string]" Expected results: "No error or warning found" [1] http://www.w3.org/TR/REC-CSS2/syndata.html#value-def-number
*** Bug 2285 has been marked as a duplicate of this bug. ***
moving priority up (this should be fixed ASAP), severity down (probably easy to fix). Yves, if you have time for this... thanks.
*** Bug 2307 has been marked as a duplicate of this bug. ***
Created attachment 406 [details] Patch to allow 'line-height: 1;' CssNumber.get() returns either a Float or an Integer. CssLineHeight* were assuming it was always a Float. I changed it so that getValue() is called instead for instances of CssValueFloat (ie. CssNumber). getValue() always returns Float. Note: this only fixes line-height. It's not clear if this bug (or a similar bug) exists elsewhere, though I couldn't find another occurance.
Created attachment 408 [details] Fixes line-height: <number> I simplified the code. Now it just changes a Float cast to a Number cast.
(In reply to comment #5) Jesse, thanks for your patch. We're reviewing it now.
Jesse, Your patch is now in the CVS codebase, and tested successfully. We'll update the production service soon with it and a bunch of other bugfixes. Thanks!
Is the online validator updated with this patch already? Cause {line-height:0;} still returns "Invalid number : line-height Parse Error - [empty string]".
(In reply to comment #8) > Is the online validator updated with this patch already? Not yet.