Status: Unconfirmed Owner: ---- Labels: Type-Bug Pri-2 OS-All Area-Misc New issue 23545 by nicolas.roumiantzeff: Incorrect rounding when size is specified in percentage http://code.google.com/p/chromium/issues/detail?id=23545
Chrome Version : 3.0.195.21 URLs (if applicable) : testPercent2.htm Other browsers tested: Safari 4: FAIL Firefox 3.x: OK IE 7: OK IE 6: OK What steps will reproduce the problem? 1. browse to attached page 2. wait for completion of the onload event handler 3. check the report generated at the bottom of the page What is the expected result? All computations should be marked as "correct" in the report. In the first container, the red DIV elements (width specified as percentage) should be squares of exactly the same width as the green DIV element (width specified in pixels) above it. In the second container, the black DIV elements (width specified as percentage) should have the same width as the green DIV element (width specified in pixels) above them. For items with a width specified as a percentage, the actual pixel width should correspond exactly to the actual pixel width of its container multiplied by the percentage divided by 100 and rounded to the nearest integer. What happens instead? There are plenty of "INCORRECT" computations in the report. In the first container, the red DIV elements (width specified as percentage) are one pixel less than the the green DIV element (width specified in pixels) above it. In the second container, some black DIV elements (width specified as percentage) does not have the same width as the green DIV element (width specified in pixels) above them. The actual pixel width of element specified as a percentage corresponds to an inconsistent rounding. Please provide any additional information below. Attach a screenshot if possible. I suspect the same issue with height specified as a percentage. The issue arose in a real case application using splitbars to manage windows with width and height expressed as a percentage of the browser window (which is handy to deal with the user resizing the browser window). Attachments: testPercent2.htm 7.9 KB -- You received this message because you are listed in the owner or CC fields of this issue, or because you starred this issue. You may adjust your issue notification preferences at: http://code.google.com/hosting/settings --~--~---------~--~----~------------~-------~--~----~ Automated mail from issue updates at http://crbug.com/ Subscription options: http://groups.google.com/group/chromium-bugs -~----------~----~----~----~------~----~------~--~---