class Blahaj::Color

Defined in:

blahaj/color.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(r : UInt8, g : UInt8, b : UInt8) #

Initialize Blahaj::Color using UInt8 RGB values


[View source]
def self.new(r : Int32, g : Int32, b : Int32) #

Initialize Blahaj::Color using Int32 RGB values


[View source]
def self.new(hex : String) #

Initialize Blahaj::Color using hex string


[View source]

Instance Method Detail

def b : UInt8 #

[View source]
def color : Colorize::ColorRGB #

[View source]
def foreground : Colorize::ColorRGB #

Returns the foreground color based on whether the color is dark or light


[View source]
def g : UInt8 #

[View source]
def hex : String #

Hex string


[View source]
def r : UInt8 #

[View source]