swing下 改变窗口样式为windows风格(swing控件样式不美观解决方案)
2011-03-02 15:53
369 查看
在windows环境下可以用下面两种方法使窗口显示windows风格窗口!
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
public static void main(String[] args) {
try
{
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
//UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
}catch(Exception e)
{}
new MyFrame();
}
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
public static void main(String[] args) {
try
{
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
//UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
}catch(Exception e)
{}
new MyFrame();
}
相关文章推荐
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格(转载)
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- Windows窗口样式速查参考,Delphi窗口控件的风格都有它们来决定(附Delphi何时用到它们,并举例说明)good
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- Windows常见窗口样式和控件风格
- 让Windows窗口控件支持Windows XP风格
- C# WinForm (笨方法)根据不同的样式配置 设置窗体相关控件的背景 以改变窗体风格
- 在DELPHI中让WindowsMediaPlayer控件随窗口改变大小。
- C# WinForm (笨方法)根据不同的样式配置 设置窗体相关控件的背景 以改变窗体风格
- 在DELPHI中让WindowsMediaPlayer控件随窗口改变大小
- windows窗口多线程 其中遇跨线程的使用控件
- 窗口和控件闪烁解决方案
- WS_CLIPCHILDREN风格窗体控件透明的解决方案