struct Athena::Console::Formatter::OutputStyle
- Athena::Console::Formatter::OutputStyle
- Struct
- Value
- Object
Overview
Default implementation of ACON::Formatter::OutputStyleInterface
.
Included Modules
Defined in:
formatter/output_style.crConstructors
Instance Method Summary
-
#add_option(option : Colorize::Mode) : Nil
Adds a text mode to
self
. -
#add_option(option : String) : Nil
:inherit:
-
#apply(text : String) : String
Applies
self
to the provided text. -
#background=(background : Colorize::Color)
Sets the background color of
self
. -
#background=(color : String)
:inherit:
-
#foreground=(foreground : Colorize::Color)
Sets the foreground color of
self
. -
#foreground=(foreground : String)
:inherit:
-
#href=(href : String | Nil)
Sets the
href
thatself
should link to. -
#options=(options : Colorize::Mode)
:inherit:
-
#remove_option(option : Colorize::Mode) : Nil
Removes a text mode to
self
. -
#remove_option(option : String) : Nil
:inherit:
Instance methods inherited from module Athena::Console::Formatter::OutputStyleInterface
add_option(option : Colorize::Mode) : Nil
add_option,
apply(text : String) : String
apply,
background=(background : Colorize::Color)
background=,
foreground=(foreground : Colorize::Color)
foreground=,
remove_option(option : Colorize::Mode) : Nil
remove_option
Constructor Detail
def self.new(foreground : Colorize::Color | String = :default, background : Colorize::Color | String = :default, options : Colorize::Mode = :none)
#