Re: RFR: 6734168: BasicButtonUI uses wrong FontMetrics to Layout JButtons text

2025-04-05 Thread Alexey Ivanov
On Fri, 21 Mar 2025 11:26:34 GMT, Prasanta Sadhukhan wrote: > javax.swing.plaf.basic.BasicButtonUI uses wrong FontMetrics object to layout > the text on a JButton. > The paint(Graphics, JComponent) method of BasicButtonUI calculates the > [FontMetrics](https://github.com/openjdk/jdk/blob/6656

Re: RFR: 6734168: BasicButtonUI uses wrong FontMetrics to Layout JButtons text

2025-03-21 Thread Alexey Ivanov
On Fri, 21 Mar 2025 16:22:40 GMT, Alexey Ivanov wrote: > If there were a way to re-enable the button again, it would render with > `Font.DIALOG` instead of the custom font that I set when the button was > created. Indeed, the button font is changed permanently. If I modify the test code: