Interface ComponentColor


@Immutable public interface ComponentColor
An immutable representation of a color for components.
  • Field Details

  • Method Details

    • rgb

      static ComponentColor rgb(int rgb)
      Creates a new color from the given RGB value.
      Parameters:
      rgb - the RGB value
      Returns:
      the component color
    • rgb

      static ComponentColor rgb(int r, int g, int b)
      Creates a new color from the given RGB values.
      Parameters:
      r - the red value
      g - the green value
      b - the blue value
      Returns:
      the component color
    • from

      static ComponentColor from(Color color)
      Creates a new color from the given AWT color.
      Parameters:
      color - the AWT color
      Returns:
      the component color
    • from

      static ComponentColor from(arc.graphics.Color color)
      Creates a new color from the given Arc color.
      Parameters:
      color - the Arc color
      Returns:
      the component color
    • getRGB

      int getRGB()
      Returns the RGB value of this color.
    • getR

      default int getR()
      Returns the red value of this color.
    • getG

      default int getG()
      Returns the green value of this color.
    • getB

      default int getB()
      Returns the blue value of this color.