Class: Vedeu::Foreground
- Inherits:
-
Translator
- Object
- Translator
- Vedeu::Foreground
- Defined in:
- lib/vedeu/output/foreground.rb
Overview
The class represents one half (the other, can be found at Background) of a terminal colour escape sequence.
Instance Method Summary collapse
- #named_codes ⇒ String private
- #numbered_prefix ⇒ String private
- #repository ⇒ Vedeu::ForegroundColours private
- #rgb_prefix ⇒ String private
Constructor Details
This class inherits a constructor from Vedeu::Translator
Instance Method Details
#named_codes ⇒ String (private)
10 11 12 |
# File 'lib/vedeu/output/foreground.rb', line 10 def named_codes Vedeu::Esc.foreground_codes[colour] end |
#numbered_prefix ⇒ String (private)
15 16 17 |
# File 'lib/vedeu/output/foreground.rb', line 15 def numbered_prefix "\e[38;5;" end |
#repository ⇒ Vedeu::ForegroundColours (private)
20 21 22 |
# File 'lib/vedeu/output/foreground.rb', line 20 def repository Vedeu.foreground_colours end |
#rgb_prefix ⇒ String (private)
25 26 27 |
# File 'lib/vedeu/output/foreground.rb', line 25 def rgb_prefix "\e[38;2;%s;%s;%sm" end |