您的位置:首页 > 产品设计 > UI/UE

Swing用UIManager.setLookAndFee怎么选择界面风格的

2018-01-28 12:51 501 查看
获取系统的lookandfeel
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
获取其它lookandfeel
javax.swing.UIManager.setLookAndFeel("javax.swing.plaf.metal.MetalLookAndFeel");
javax.swing.UIManager.setLookAndFeel("com.sun.java.swing.plaf.motif.MotifLookAndFeel");
javax.swing.UIManager.setLookAndFeel("com.sun.java.swing.plaf.mac.MacLookAndFeel");



设置成系统风格
javax.swing.UIManager.setLookAndFeel(javax.swing.UIManager.getSystemLookAndFeelClassName());

各种第三方风格(需要引jar)
javax.swing.UIManager.setLookAndFeel("com.birosoft.liquid.LiquidLookAndFeel");
javax.swing.UIManager.setLookAndFeel("com.pagosoft.plaf.PgsLookAndFeel");
javax.swing.UIManager.setLookAndFeel(new TonicLookAndFeel());
javax.swing.UIManager.setLookAndFeel("com.nilo.plaf.nimrod.NimRODLookAndFeel");
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: