First Time Skin Look And Feel

There are two different ways to use Skin Look And Feel: the classic LookAndFeel way and the Skinit way. In both cases, you need to know which skins or themepacks you are going to use. Let say we are going to use the default themepack which comes with SkinLF, it is named "themepack.zip" and is located in the "lib" directory of the SkinLF distribution.

Classic LookAndFeel way

Enabling SkinLF in your application is more or less like enabling other look and feels, it is just telling SkinLF which themepacks to use and calling UIManager.setLookAndFeel.

Here is an example from the demo class:

        // first tell SkinLF which theme to use
        Skin theSkinToUse = SkinLookAndFeel.loadThemePack("themepack.zip");
        SkinLookAndFeel.setSkin(theSkinToUse);

        // finally set the Skin Look And Feel
        UIManager.setLookAndFeel(new SkinLookAndFeel());

Skinit

Skinit is a small java class which ships with Skin Look And Feel and provides a non intrusive solution to skin any applications. You only need to know how to start from the command line the application you want to skin.

Suppose you start your application with:

java -cp myapp.jar com.mypackage.MyApp arg1 arg2
then with SkinLF, it will look like:
java -cp skinlf.jar;myapp.jar Skinit -pack themepack.zip com.mypackage.MyApp arg1 arg2
That's it. Your application will start skinned with the themepack. This is the fastest way to get your app skinned.