开发者

is there a way to change jcheckbox to use a cross instead of a tick? JAVA

开发者 https://www.devze.com 2023-01-28 08:33 出处:网络
I have a Jcheckbox but it only has the tick to show its checked, is there a way i can change it to a cross, or circle?

I have a Jcheckbox but it only has the tick to show its checked, is there a way i can change it to a cross, or circle? and is there a way to change the grey background to white the 开发者_运维技巧setBackground doesn't seem to make a difference?


User setPressedIcon, setIcon and setDisabledIcon

    JCheckBox b = new JCheckBox();
    b.setPressedIcon(pressedIcon)
    b.setIcon(defaultIcon);
    b.setDisabledIcon(disabledIcon)
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号