Browse Source

Properly clip icon.

pull/187/head
weisj 4 years ago
parent
commit
87a5295f06
  1. 2
      core/src/main/java/com/github/weisj/darklaf/ui/button/DarkButtonUI.java

2
core/src/main/java/com/github/weisj/darklaf/ui/button/DarkButtonUI.java

@ -269,7 +269,7 @@ public class DarkButtonUI extends BasicButtonUI implements ButtonConstants {
protected void paintIcon(final Graphics g, final AbstractButton b, final JComponent c) {
if (b.getIcon() != null) {
g.setClip(iconRect);
g.clipRect(iconRect.x, iconRect.y, iconRect.width, iconRect.height);
paintIcon(g, c, iconRect);
}
}

Loading…
Cancel
Save