在main()中加入:
Font f = new Font("Dialog",Font.PLAIN,12);//或者用其他字体
UIManager.put("Label.font",f);
UIManager.put("ComboBox.font",f);
UIManager.put("Button.font",f);
UIManager.put("Menu.font",f);
Font f = new Font("Dialog",Font.PLAIN,12);//或者用其他字体
UIManager.put("Label.font",f);
UIManager.put("ComboBox.font",f);
UIManager.put("Button.font",f);
UIManager.put("Menu.font",f);
在windows的LookAndFell中出现乱码,
在metal和motiv的LookAndFell中却没有
-----------
上面的哥们说的方法,我回去试验一下。
另外,能不能一下子改变所有组件的字体,
比如:
UIManager.put("Component.font",f);
我试验了,这条语句不行的,大家有没有好的方法,可以:
一下子改变所有组件的字体?