Solo una sombra
NimROD Look And Feel espaņol
NimROD L&F Themes
Home
Screenshots
Download
FAQ
Applets
Themes
Licence
Links
About

RSS
Valid HTML 4.01 Transitional
Introduction

You can change the colours you want to use with NimROD Look & Feel passing parameters to the JVM. This is the list of allowed paramenters:

ParameterTargetFormat
nimrodlf.p1sets the primary 1#RRGGBB
nimrodlf.p2sets the primary 2 #RRGGBB
nimrodlf.p3sets the primary 3#RRGGBB
nimrodlf.s1sets the secondary 1#RRGGBB
nimrodlf.s2sets the secondary 2#RRGGBB
nimrodlf.s3sets the secondary 3#RRGGBB
nimrodlf.wsets white#RRGGBB
nimrodlf.bsets black#RRGGBB
nimrodlf.selectionsets all primary colours#RRGGBB
nimrodlf.backgroundsets all secondary colours#RRGGBB

Now, there is a new parameter, nimrodlf.opacity, to set the new menu and JInternalFrames opacity features.

This method is very powerfull, but you must write several parameters in the command line. To make easier NimROD Look & Feel, now you can put all those parameters in a file and reuse it in all your Java applications. So, there is another new parameter, nimrodlf.themeFile, which substitutes previous parameters. The final parameter list is:

ParameterTargetFormat
nimrodlf.p1sets the primary 1#RRGGBB
nimrodlf.p2sets the primary 2 #RRGGBB
nimrodlf.p3sets the primary 3#RRGGBB
nimrodlf.s1sets the secondary 1#RRGGBB
nimrodlf.s2sets the secondary 2#RRGGBB
nimrodlf.s3sets the secondary 3#RRGGBB
nimrodlf.wsets white#RRGGBB
nimrodlf.bsets black#RRGGBB
nimrodlf.selectionsets all primary colours#RRGGBB
nimrodlf.backgroundsets all secondary colours#RRGGBB
nimrodlf.menuOpacitysets menu opacity0-255
nimrodlf.frameOpacitysets JInternalFrame opacity0-255
nimrodlf.themeFilesubstitutes previous parametersfile name
nimrodlf.themeURLlike nimrodlf.themeFile but with URLs.URL to the theme file.

Must I write the theme files AND write a parameter in the command line? No. In fact, is possible to choose colours without write anything and the process is quite simple, because there is a theme editor and, if the file is named NimRODThemeFile.theme, is not necessary to write anything in the command line because the file is automaticaly loaded.

Theme editor

The nimrodlf.jar file has a theme editor. In most systems, double clicking nimrodlf.jar is enough to use it, but if this doesn't work, you can write:

java -jar nimrodlf.jar

You should get this:

Editor de temas

The application has then colored squares to set the themes colours, an slider to set the menus opacity and another one to set the JInternalFrames opcacity, and a huge "Test" button to test the colours we have chosen. There are two buttons to open and save theme files and some tabs with example panels showing the NimROD Look & Feel with the chosen colours.

You can set the menus transparency level moving the slider, and clicking in the colored squares will show a dialog where you can choose the colour for that square.

Editor de temas

A Swing theme is defined by eight colours, although only four are used in the wild:

  • Black, for texts
  • White, for texts fields background
  • Background, the background colour of almost everything.
  • Selection, the colour for focused controls

"Selection" and "Background" groups have four squares, and one is slightly separated, because although Swing uses three colours for each category, those three colours must be coordinated, so they must by the same colour, but more dark. For example, if we want a grey background, the first square will be "our" grey, the second will be lighter and the third will be even lighter.

You can define the squares one by one, but if you define the separated square, the three colours will be automaticaly set.

When you have chosen your favorite colours, click "Test" button and see the results in the tabs.

Editor de temas

In this example, I've chose dark gray for "Background", blue for "Selections" and, for contrast, I've chose white for "Black" and a dark gray for "White". Then clicked on "Test" and...

Editor de temas
Theme files

When the theme is completed, clicking on "Save" button will open a dialog to choose the directory and the name for the theme file.

Editor de temas

The editor has chose the default name for the theme: NimRODThemeFile.theme.

When NimROD Look & Feel is loaded, it looks in the command line for nimrodlf.themeFile paramater to get the theme file to use. If there isn't paramater, it looks for a file named NimRODThemeFile.theme in working directory. So if you name your theme file NimRODThemeFile.theme and put it in the working directory you won't need to pass anything to the JVM in the command line.

Of course, you can change the filename and invoke the application using the nimrodlf.themeFile option. You can have a directory with theme files an use them in all your java applications.

Summary
  • NimROD Look & Feel lets you to change the colours of your application using the command line or theme files.

  • The nimrodlf.jar file includes a theme editor which can be executed double-clicking the jar or writing:
    java -jar nimrodlf.jar.

  • Theme files can be loaded using the command line option nimrodlf.themeFile with the path and name of the file.
    For example, to execute JEdit using a theme named "burdeos.theme" you should write:
    java -Dnimrodlf.themeFile=c:/aplicaciones/JARS/burdeos.theme -jar jedit.jar

  • Theme files can be loaded using the command line option nimrodlf.themeURL with the URL to the file.
    For example, to execute JEdit using a theme named "burdeos.theme" placed in this site, you should write:
    java -Dnimrodlf.themeURL="http://personales.ya.com/nimrod/data/Burdeos.theme" -jar jedit.jar

  • If the theme file is named NimRODThemeFile.theme and is in the working directory, is automaticaly loaded.