RFR: 8295078: TextField blurry when inside an TitledPane -> AnchorPane [v3]

Andy Goryachev angorya at openjdk.org
Thu Nov 10 19:39:34 UTC 2022


On Thu, 10 Nov 2022 19:14:12 GMT, Michael Strauß <mstrauss at openjdk.org> wrote:

>> Changes requested by angorya (Author).
>
> @andy-goryachev-oracle
> Snapping doesn't necessarily imply integer coordinates or sizes. The reason is that we're snapping to _pixels_, not integers. For example, with 200% scale, every other pixel will have a .5 coordinate. It's also important to not confuse snapping with rounding to integers because integer coordinates might not even fall on pixel boundaries for some scaling factors.

@mstr2 : 
You are right, I wasn't aware of scale.  Snapping code looks like `Math.round(value * scale) / scale;`, so I take the 'whole integer' words back.  Sorry for the confusion.

Having said that, my earlier comment is still valid - if snapToPixel==true, the final location and sizes must go through snap*() methods.  And the earlier example is also valid, assuming scale=1.0.

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

PR: https://git.openjdk.org/jfx/pull/910


More information about the openjfx-dev mailing list