Skip to content

About

Java library generating a great number of color combinations for theming Swing applications

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

73 Commits

Folders and files

Repository files navigation

LookAndFeelMetalizer

LookAndFeelMetalizer allows to quickly modify the theme of the Metal look-and-feel alt text

Features

  • lot of generated themes
  • consistent color schemes
  • theme selection dialog

Requirements

Java >= 1.6

Download

  • Use Maven

    <dependency>
          <groupId>com.github.dotxyteam</groupId>
          <artifactId>metalizer</artifactId>
          <version>1.0.3</version>
      </dependency>
  • Or Download The JAR

Usage

The jar file is runnable.

To test:

  • either double-click on the jar file (OS-dependant)
  • or run this command: java -jar

By default it will:

  • open the theme selection dialog
  • try to download and open a test application

A Metalizer theme is an 'EqualizedTheme' object. It is defined by 3 values: hue, saturation and brightness. Each value is an integer between 0 and 255. Open the theme selection dialog to find out your preferred values. Example:

int hue = 0;
int saturation = 0;
int brightness = 0;
EqualizedTheme myTheme = new EqualizedTheme(hue, saturation,
        brightness);

To enable the theme, include the following code in your application before creating any controls:

try {
    myTheme.activate();
} catch (Exception e1) {
    e1.printStackTrace();
}

If the controls are already created, then use:

SwingUtilities.updateComponentTreeUI(applicationWindow);

Use the following code to open the theme selection window:

EqualizedTheme selectedTheme = ThemeEqualizerDialog
        .open(applicationWindow, myTheme);
System.out.println("Selected theme values: hue="
        + selectedTheme.getHueOffset() + ", saturation="
        + selectedTheme.getSaturationOffset() + ", brightness="
    + selectedTheme.getBrightnessOffset());

Used by

Feedback

Feel free to post any found bugs or send me a message: [email protected]

Thanks!

About

Java library generating a great number of color combinations for theming Swing applications

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages