Class ColorSchemeAssociationKind

java.lang.Object
org.pushingpixels.substance.api.ColorSchemeAssociationKind

public class ColorSchemeAssociationKind extends Object
Allows associating different color schemes to different visual parts of UI components. For example, the JCheckBox has three different visual areas:
  • Border - assciated with BORDER
  • Fill - associated with FILL
  • Check mark - associated with MARK
Applications can create custom instances of this class to further refine the control over the painting. In this case, the custom UI delegates must be created to use these new association kinds.
Since:
version 5.1
  • Field Details

  • Constructor Details

    • ColorSchemeAssociationKind

      public ColorSchemeAssociationKind(String name, ColorSchemeAssociationKind fallback)
      Creates a new association kind.
      Parameters:
      name - Association kind name.
      fallback - Fallback association kind. This is used when no color scheme is associated with this kind. For example, TAB_BORDER specifies that its fallback is BORDER. When the JTabbedPane UI delegate is painting the tabs, it will try to use the color scheme associated with TAB_BORDER. If none was registered, it will fall back to use the color scheme associated with BORDER, and if that is not registered as well, will use the color scheme associated with FILL.
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • values

      public static Set<ColorSchemeAssociationKind> values()
      Returns all available association kinds.
      Returns:
      All available association kinds.
    • getFallback

      public ColorSchemeAssociationKind getFallback()
      Returns the fallback for this association kind.
      Returns:
      The fallback for this association kind.