On Wed, 23 Mar 2022 18:24:05 GMT, Alisen Chung <ach...@openjdk.org> wrote:

>> Changed the drawing area to be increased by 0.5 on the left side to prevent 
>> clipping
>
> Alisen Chung has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   scale stroke width at higher scalings

I think the only way to fix such an issue is to use a raster-based API which 
will work as "usually expected" when the UI is scaled unlike vectors like 
drawLine/etc, an example of a similar bug 
https://mail.openjdk.java.net/pipermail/swing-dev/2014-April/003352.html
As far as I remember the best solution(used by the javafx) is to draw layers by 
the fillArea(shadow area->then border area->then component area), I am not sure 
it will be much slower.
Another solution is to draw the "lines" using the fillRect, but it might cause 
some issues in the corners if the line color is transparent

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

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

Reply via email to