class HexaPDF::Content::ColorSpace::DeviceGray
The DeviceGray color space.
def self.new(_definition = nil)
def self.new(_definition = nil) DEFAULT end
def color(gray)
between 0.0 and 1.0. The integer color values are automatically normalized to the
Color values can either be integers in the range from 0 to 255 or floating point numbers
Returns the color object for the given gray component.
def color(gray) Color.new(ColorUtils.normalize_value(gray, 255)) end
def default_color
def default_color Color.new(0.0) end
def family
def family :DeviceGray end
def prenormalized_color(gray)
Returns the color object for the gray component without applying value normalization.
def prenormalized_color(gray) Color.new(gray) end