<?php str_pad( string $string, int $length, string $pad_string = " ", int $pad_type = STR_PAD_RIGHT): string
<?php private function padColumn(string $text, int $width) { $ansiCharacterPadding = strlen($text) - strlen($this->stripAnsi($text)); return str_pad($text, $width + $ansiCharacterPadding); } private function stripAnsi(string $text): string
<?php function ansi(int $code) { $code = str_pad($code, 3, 0, STR_PAD_LEFT); return "\x1b[{$code}m"; }