class HexaPDF::Content::ColorSpace::DeviceCMYK::Color
A color in the DeviceCMYK
color space.
See: PDF1.7 s8.6.4.4
Public Class Methods
new(c, m, y, k)
click to toggle source
Initializes the color with the c
(cyan), m
(magenta), y
(yellow) and k
(black) components.
Each argument has to be a float between 0.0 and 1.0.
# File lib/hexapdf/content/color_space.rb, line 350 def initialize(c, m, y, k) @c = c @m = m @y = y @k = k end
Public Instance Methods
color_space()
click to toggle source
Returns the DeviceCMYK
color space module.
# File lib/hexapdf/content/color_space.rb, line 358 def color_space DeviceCMYK::DEFAULT end
components()
click to toggle source
Returns the CMYK color as an array of normalized color values.
# File lib/hexapdf/content/color_space.rb, line 363 def components [@c, @m, @y, @k] end