MediaWiki  1.23.13
MWTerm.php
Go to the documentation of this file.
1 <?php
32  function __construct() {
33  }
34 
41  public function color( $color ) {
42  global $wgCommandLineDarkBg;
43 
44  $light = $wgCommandLineDarkBg ? "1;" : "0;";
45 
46  return "\x1b[{$light}{$color}m";
47  }
48 
54  public function reset() {
55  return $this->color( 0 );
56  }
57 }
58 
65  public function color( $color ) {
66  return '';
67  }
68 
69  public function reset() {
70  return '';
71  }
72 }
DummyTermColorer
A colour-less terminal.
Definition: MWTerm.php:64
php
skin txt MediaWiki includes four core it has been set as the default in MediaWiki since the replacing Monobook it had been been the default skin since before being replaced by Vector largely rewritten in while keeping its appearance Several legacy skins were removed in the as the burden of supporting them became too heavy to bear Those in etc for skin dependent CSS etc for skin dependent JavaScript These can also be customised on a per user by etc This feature has led to a wide variety of user styles becoming that gallery is a good place to ending in php
Definition: skin.txt:62
AnsiTermColorer\reset
reset()
Return ANSI terminal escape code for restoring default text attributes.
Definition: MWTerm.php:54
DummyTermColorer\reset
reset()
Definition: MWTerm.php:69
DummyTermColorer\color
color( $color)
Definition: MWTerm.php:65
global
when a variable name is used in a it is silently declared as a new masking the global
Definition: design.txt:93
AnsiTermColorer
Terminal that supports ANSI escape sequences.
Definition: MWTerm.php:31
AnsiTermColorer\color
color( $color)
Return ANSI terminal escape code for changing text attribs/color.
Definition: MWTerm.php:41
AnsiTermColorer\__construct
__construct()
Definition: MWTerm.php:32