FlatLaf
FlatLaf copied to clipboard
JLabel with rounded border corners and background
Karl, congratulations on Flatlaf, and thanks for giving the swing a new life.
This personalization
label.setOpaque(true);
label.putClientProperty(FlatClientProperties.STYLE,
"background: #00498C; foreground: #A9D1FF; border: 5,10,5,10, #E1FF68, 1.0f, 30;");
Results in
In the FlatLabelUI class could also have its update() method implementing it as it did in FlatPanelUI, and thus ensure that the color of the background would be rounded, as we see in a JPanel with that same personalization.
I can currently resolve through Jlabel's paintComponent(), but if there was a native feature on FlatLaf, it would be pretty cool, because JLabel with rounded corners allows us to create very stylish and modern titles.
What do you think of the idea?
Thank you, and see you soon.