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
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: