Sha256: 4ef4da37961e310b9cd32001a5e9dacd50149d77ed69d6f07950dceb8ee706f2
Contents?: true
Size: 753 Bytes
Versions: 3
Compression:
Stored size: 753 Bytes
Contents
require 'whirled_peas/utils/ansi' require_relative 'color' require_relative 'text_color' module WhirledPeas module Settings class BgColor < Color BG_OFFSET = 10 BLACK = new(Utils::Ansi::BLACK + BG_OFFSET) RED = new(Utils::Ansi::RED + BG_OFFSET) GREEN = new(Utils::Ansi::GREEN + BG_OFFSET) YELLOW = new(Utils::Ansi::YELLOW + BG_OFFSET) BLUE = new(Utils::Ansi::BLUE + BG_OFFSET) MAGENTA = new(Utils::Ansi::MAGENTA + BG_OFFSET) CYAN = new(Utils::Ansi::CYAN + BG_OFFSET) WHITE = new(Utils::Ansi::WHITE + BG_OFFSET) GRAY = BLACK.bright DEFAULT = nil # Use system defined default def as_text_color TextColor.new(code - BG_OFFSET, bright?) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
whirled_peas-0.13.0 | lib/whirled_peas/settings/bg_color.rb |
whirled_peas-0.12.0 | lib/whirled_peas/settings/bg_color.rb |
whirled_peas-0.11.1 | lib/whirled_peas/settings/bg_color.rb |