MediaWiki  1.30.0
AnsiTermColorer Class Reference

Terminal that supports ANSI escape sequences. More...

Public Member Functions

 __construct ()
 
 color ( $color)
 Return ANSI terminal escape code for changing text attribs/color. More...
 
 reset ()
 Return ANSI terminal escape code for restoring default text attributes. More...
 

Detailed Description

Terminal that supports ANSI escape sequences.

Definition at line 31 of file MWTerm.php.

Constructor & Destructor Documentation

◆ __construct()

AnsiTermColorer::__construct ( )

Definition at line 32 of file MWTerm.php.

Member Function Documentation

◆ color()

AnsiTermColorer::color (   $color)

Return ANSI terminal escape code for changing text attribs/color.

Parameters
string$colorSemicolon-separated list of attribute/color codes
Returns
string

Definition at line 41 of file MWTerm.php.

References $wgCommandLineDarkBg, and global.

Referenced by reset().

◆ reset()

AnsiTermColorer::reset ( )

Return ANSI terminal escape code for restoring default text attributes.

Returns
string

Definition at line 54 of file MWTerm.php.

References color().


The documentation for this class was generated from the following file: