Module | Pry::Helpers::Text |
In: |
lib/pry/helpers/text.rb
|
The methods defined on {Text} are available to custom commands via {Pry::Command#text}.
COLORS | = | { "black" => 0, "red" => 1, "green" => 2, "yellow" => 3, "blue" => 4, "purple" => 5, "magenta" => 5, "cyan" => 6, "white" => 7 |
bold | -> | bright_default |
Returns text as bold text for use on a terminal. _Pry.color_ must be true for this method to perform any transformations.
@param [String, to_s] text @return [String] text
Returns `text` in the default foreground colour. Use this instead of "black" or "white" when you mean absence of colour.
@param [String, to_s] text @return [String]
Remove any color codes from text.
@param [String, to_s] text @return [String] text stripped of any color codes.