ColorStyle
Class ColorStyle
final deprecated
| since |
1.0 |
|---|---|
| deprecated |
2.0 Use the |
| package |
Joomla Framework |
Methods
__construct
Constructor
__construct(string fg = '', string bg = '', array options = array()) : mixed
| since |
1.0 |
|---|---|
| throws |
|
Arguments
- fg
stringForeground color.- bg
stringBackground color.- options
arrayStyle options.
Response
mixed
__toString
Convert to a string.
__toString() : string
| since |
1.0 |
|---|
Response
string
fromString
Create a color style from a parameter string.
fromString(string string) : \Joomla\Application\Cli\ColorStyle
static
Example: fg=red;bg=blue;options=bold,blink
| since |
1.0 |
|---|---|
| throws |
|
Arguments
- string
stringThe parameter string.
Response
\Joomla\Application\Cli\ColorStyleInstance of $this to allow chaining.
getKnownColors
Get the known colors.
getKnownColors() : string
| since |
1.0 |
|---|
Response
string
getKnownOptions
Get the known options.
getKnownOptions() : array
| since |
1.0 |
|---|
Response
array
getStyle
Get the translated color code.
getStyle() : string
| since |
1.0 |
|---|
Response
string
Properties
knownColors
Known colors
static
| since |
1.0 |
|---|
Type(s)
array
knownOptions
Known styles
static
| since |
1.0 |
|---|
Type(s)
array
fgBase
Foreground base value
static
| since |
1.0 |
|---|
Type(s)
int
bgBase
Background base value
static
| since |
1.0 |
|---|
Type(s)
int
fgColor
Foreground color
| since |
1.0 |
|---|
Type(s)
int
bgColor
Background color
| since |
1.0 |
|---|
Type(s)
int
options
Array of style options
| since |
1.0 |
|---|
Type(s)
array