[Erledigt] Color values

Hi,

I was looking at the class FlatTab. Line 160

borderSelectedOut = new FlatTabColor( “stack.tab.border.out.selected”, dockable );

Does the value of the color come from a properties file, which maps
stack.tab.border.out.selected to an actual color?

If so, do we have to change the properties file values to customize the settings, or can we give the application another properties file whose values will override values from the original properties file?


Regards
Parag

It is not a properties file, it is directly written in code (otherwise it would not be possible to respect the settings of a LookAndFeel).

There are multiple ways to change the color:

  • write a new ColorScheme and use “BasicTheme.setColorScheme” (since all DockThemes extend BasicTheme, that works with all themes).
  • Call “DockController.getColors” to get the ColorManager. You can “put” a new color there, ensure to use Priority “CLIENT”, otherwise your setting might get overridden. Personally I think that is the best solution.
  • Or you can “publish” a new ColorProvider for “TabColor.class”. With a ColorProvider you would be able to influence the colors of individual tabs, but it is a complex procedure…