On Tue, 15 Mar 2022 16:51:56 GMT, lukeu <d...@openjdk.java.net> wrote:

> I believe the only way to get pixel-perfect (& balanced weight) rendering of 
> 2 lines next to each other at non-integer scale factors, when using integer 
> based APIs like `drawLine`, will be to undo the affine transformation upon 
> the pre-scaled `Graphics2D` object, and render it at 1x scaling. Then you'd 
> need to decide how to compute the desired line thickness (like: should it 
> jump 1px > 2px at 150% scaling or 175% scaling?)

I've been thinking about it. It could be the approach to use for drawing 
borders. Windows controls render 1-pixel borders when the scale is 200%.

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

PR: https://git.openjdk.java.net/jdk/pull/7449

Reply via email to