为什么在JAVA中使用QuaQua美化程序界面,打包成jar文件后界面反而变得很难看? 5
main方法中的代码:System.setProperty("Quaqua.tabLayoutPolicy","wrap");if(!System.getProperty...
main方法中的代码:
System.setProperty("Quaqua.tabLayoutPolicy", "wrap");
if (!System.getProperty("os.name").toLowerCase().startsWith("mac")) {
try {
Methods.invokeStatic(JFrame.class,
"setDefaultLookAndFeelDecorated", Boolean.TYPE,
Boolean.TRUE);
Methods.invokeStatic(JDialog.class,
"setDefaultLookAndFeelDecorated", Boolean.TYPE,
Boolean.TRUE);
} catch (NoSuchMethodException e) {
e.printStackTrace();
}
}
try {
UIManager.setLookAndFeel("ch.randelshofer.quaqua.QuaquaLookAndFeel");
} catch (Exception e) {
} 展开
System.setProperty("Quaqua.tabLayoutPolicy", "wrap");
if (!System.getProperty("os.name").toLowerCase().startsWith("mac")) {
try {
Methods.invokeStatic(JFrame.class,
"setDefaultLookAndFeelDecorated", Boolean.TYPE,
Boolean.TRUE);
Methods.invokeStatic(JDialog.class,
"setDefaultLookAndFeelDecorated", Boolean.TYPE,
Boolean.TRUE);
} catch (NoSuchMethodException e) {
e.printStackTrace();
}
}
try {
UIManager.setLookAndFeel("ch.randelshofer.quaqua.QuaquaLookAndFeel");
} catch (Exception e) {
} 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询