On Tue, 13 Oct 2026 21:57:20 GMT, Andy Goryachev <[email protected]> wrote:

>> Florian Kirmaier has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   JDK-8392158
>>   Small test cleanup
>
> modules/javafx.graphics/src/main/java/javafx/scene/layout/GridPane.java line 
> 2078:
> 
>> 2076:              } else {
>> 2077:                 // Handle the remainder
>> 2078:                 portion = (int)(isSnapToPixel() ? Math.rint(available 
>> / pixelSize) : available) % adjusting.size();
> 
> with snapping off, two rows constrained at 100px and a 0.5px gap should 
> shrink to 47.75px each.  instead, it sizes both to 100.5 px due to rounding

Fixed by not flooring the portion when snapToPixel. Added 2 more tests.

-------------

PR Review Comment: https://git.openjdk.org/jfx/pull/2312#discussion_r4282976003

Reply via email to