Class CMYKColor

  • All Implemented Interfaces:
    java.awt.Paint, java.awt.Transparency, java.io.Serializable

    public class CMYKColor
    extends ExtendedColor
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      CMYKColor​(float floatCyan, float floatMagenta, float floatYellow, float floatBlack)
      Construct a CMYK Color.
      CMYKColor​(float floatCyan, float floatMagenta, float floatYellow, float floatBlack, float floatAlpha)
      Construct a CMYK Color.
      CMYKColor​(int intCyan, int intMagenta, int intYellow, int intBlack)
      Constructs a CMYK Color based on 4 color values (values are integers from 0 to 255).
      CMYKColor​(int intCyan, int intMagenta, int intYellow, int intBlack, int intAlpha)
      Constructs a CMYK Color based on 4 color values (values are integers from 0 to 255).
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)  
      float getBlack()  
      float getCyan()  
      float getMagenta()  
      float getYellow()  
      int hashCode()  
      • Methods inherited from class java.awt.Color

        brighter, createContext, darker, decode, getAlpha, getBlue, getColor, getColor, getColor, getColorComponents, getColorComponents, getColorSpace, getComponents, getComponents, getGreen, getHSBColor, getRed, getRGB, getRGBColorComponents, getRGBComponents, getTransparency, HSBtoRGB, RGBtoHSB, toString
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • cyan

        float cyan
      • magenta

        float magenta
      • yellow

        float yellow
      • black

        float black
    • Constructor Detail

      • CMYKColor

        public CMYKColor​(int intCyan,
                         int intMagenta,
                         int intYellow,
                         int intBlack)
        Constructs a CMYK Color based on 4 color values (values are integers from 0 to 255).
        Parameters:
        intCyan - cyan value
        intMagenta - magenta value
        intYellow - yellow value
        intBlack - black value
      • CMYKColor

        public CMYKColor​(int intCyan,
                         int intMagenta,
                         int intYellow,
                         int intBlack,
                         int intAlpha)
        Constructs a CMYK Color based on 4 color values (values are integers from 0 to 255).
        Parameters:
        intCyan - cyan value
        intMagenta - magenta value
        intYellow - yellow value
        intBlack - black value
        intAlpha - alpha value
      • CMYKColor

        public CMYKColor​(float floatCyan,
                         float floatMagenta,
                         float floatYellow,
                         float floatBlack)
        Construct a CMYK Color.
        Parameters:
        floatCyan - cyan value
        floatMagenta - magenta value
        floatYellow - yellow value
        floatBlack - black value
      • CMYKColor

        public CMYKColor​(float floatCyan,
                         float floatMagenta,
                         float floatYellow,
                         float floatBlack,
                         float floatAlpha)
        Construct a CMYK Color.
        Parameters:
        floatCyan - cyan value
        floatMagenta - magenta value
        floatYellow - yellow value
        floatBlack - black value
        floatAlpha - alpha value
    • Method Detail

      • getCyan

        public float getCyan()
        Returns:
        the cyan value
      • getMagenta

        public float getMagenta()
        Returns:
        the magenta value
      • getYellow

        public float getYellow()
        Returns:
        the yellow value
      • getBlack

        public float getBlack()
        Returns:
        the black value
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.awt.Color
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.awt.Color