Getting and Setting a Look and Feel : Look Feel « Swing JFC « Java






Getting and Setting a Look and Feel

 


import javax.swing.LookAndFeel;
import javax.swing.UIManager;

public class Main {
  public static void main(String[] argv)throws Exception {
    // Get the currently installed look and feel
    LookAndFeel lf = UIManager.getLookAndFeel();

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

  }
}

   
  








Related examples in the same category

1.Getting and Setting a Native Look and Feel
2.Retrieve the cross-platform look and feel
3.Default look and feel can be set in a file called 'swing.properties' located in the '/lib' directory.
4.Set the look and feel using a system property on the command line
5.Look and feel string
6.Selecting different looks and feels
7.Change the look and feelChange the look and feel
8.A Look-and-feel switcherA Look-and-feel switcher
9.Simple look and feel Example
10.Change Look and feelChange Look and feel
11.Get Installed Look And FeelsGet Installed Look And Feels
12.Get Swing Properties
13.awt.font.desktophints
14.Highlighted ButtonHighlighted Button