Java/Swing: low-profile button height?

后端 未结 3 1362
遇见更好的自我
遇见更好的自我 2020-11-27 23:30

I would like to reduce the vertical size of a JButton. The following code works fine for K > 1 but I can\'t seem to reduce the size. Any suggestions?

JButton         


        
3条回答
  •  一生所求
    2020-11-27 23:40

    As an alternative, some L&Fs (e.g. Nimbus, Aqua) support a JComponent.sizeVariant, as discussed in Resizing a Component and Using Client Properties. Several variations are illustrated here.

提交回复
热议问题