swing 风格 LookAndFeel

UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());//当前系统风格

UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");//windows风格

UIManager.setLookAndFeel("javax.swing.plaf.windows.WindowsLookAndFeel");//windows风格

UIManager.setLookAndFeel("com.apple.mrj.swing.MacLookAndFeel");//现在在我的机器上没有特殊显示,有待有兴趣的朋友考察,并多谢告知

UIManager.setLookAndFeel(UIManager.getCrossPlatformLookAndFeelClassName());//跨平台的Java界面风格,不太明白这种说法

UIManager.setLookAndFeel("javax.swing.plaf.metal.MetalLookAndFeel");//java风格


UIManager.setLookAndFeel("com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel");//Nimbus风格,新出来的外观,jdk6 update10版本以后的才会出现

UIManager.setLookAndFeel("com.sun.java.swing.plaf.motif.MotifLookAndFeel");//Motif风格,外观接近windows经典,但宽宽大大,而且不是黑灰主色,而是蓝黑

猜你喜欢

转载自wenzongliang.iteye.com/blog/2145815