/**
* set the look and feel for a Swing App.
* Use Nimbus if available, failing that cross platform metal, failing that the default.
*/
public static void setLaf()
{
boolean success = false;
try
{
UIManager.setLookAndFeel( "com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel" );
success = true;
}
catch ( UnsupportedLookAndFeelException e )
{
}
catch ( IllegalAccessException e )
{
}
catch ( InstantiationException e )
{
}
catch ( ClassNotFoundException e )
{
}
if ( !success )
{
try
{
UIManager.setLookAndFeel( UIManager.getCrossPlatformLookAndFeelClassName() );
}
catch ( UnsupportedLookAndFeelException e )
{
}
catch ( IllegalAccessException e )
{
}
catch ( InstantiationException e )
{
}
catch ( ClassNotFoundException e )
{
}
}
}