Class: Benedictus::Color

Inherits:
Object
  • Object
show all
Defined in:
lib/benedictus/color.rb

Defined Under Namespace

Classes: Decorator

Constant Summary collapse

CODES =
{
  bold: 1,
  dim: 2,
  italic: 3,
  red: 31,
  green: 32,
  yellow: 33,
  blue: 34,
  cyan: 36
}.freeze

Instance Method Summary collapse

Constructor Details

#initialize(enabled: true) ⇒ Color

Returns a new instance of Color.



16
17
18
# File 'lib/benedictus/color.rb', line 16

def initialize(enabled: true)
  @enabled = enabled
end