[Webkit-unassigned] [Bug 84040] New: Rounding Error with %

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 16 09:26:28 PDT 2012


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

           Summary: Rounding Error with %
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Unspecified
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: CSS
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: j.leshel at synergetic.ag
                CC: j.leshel at synergetic.ag


I have Html like this:
<div class="someBodyClass">
<div class="someWrap" data-role="navbar" role="navigation">

    <ul class="ui-grid-c">
        <li class="logout_btn ui-block-a"><spandata-theme="b" class="ui-btn ui-btn-corner-all ui-shadow ui-btn-up-b" aria-disabled="false"><span class="ui-btn-inner ui-btn-corner-all"><span class="ui-btn-text">Logout</span></span><input type="submit" value="Logout" id="uc_header_btnLogout" title="Abmelden" data-theme="b" class="ui-btn-hidden" aria-disabled="false"></span></li>
        <li class="home_btn ui-block-b"><a  title="Home" data-theme="b" data-role="button" href="" class="ui-btn ui-btn-up-b"><span class="ui-btn-inner"><span class="ui-btn-text">Home</span></span></a></li>
        <li class="search_btn ui-block-c"><a  title="text" data-theme="b" data-role="button" class="ui-btn ui-btn-up-b"><span class="ui-btn-inner"><span class="ui-btn-text">Text</span></span></a></li>
        <li class="back_btn ui-block-d"><a title="text" class="hlBack ui-btn ui-btn-up-b" data-theme="b" data-role="button" data-rel="back"><span class="ui-btn-inner"><span class="ui-btn-text">Text</span></span></a></li>
    </ul>

</div>
</div>

Width of outer Div is 795px;
Width of inner Div is nothing - hence 100%;
Width of ul is 100%;
Width of the four li's is 25%;


Webkit is calculating width of li's wrongly.
each li is 198px (calculated metrics) and should be 198.75px.
So I have a gap between the last li and the ul.

When I give the outer div a width of 800px everthing is fine.
It's also fine when i only put in two li elements.

tested on chrome - latest version 18.0.1025.162
also tested on several mobile devices.

No margins, no paddings, actually spent a while debugging it. There is no mistake in my markup and css.
Here is my doctype:
!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"

This is a Login proteced page, so can't send link

-- 
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