output .= ESC.'[24;0f'.$msg.HOME; } protected function parser(int $startline): Parser { return new AnsiParser($this->fo->content,self::$frame_width,$startline); } public static function strlenv($text):int { return strlen($text ? preg_replace('/'.ESC.'\[[0-9;?]+[a-zA-Z]/','',$text) : $text); } // @todo make abstract /** * This function returns the frame content, raw * * @return string */ public function raw(): string { // We need to convert any ESC's, not next to [ into a character, otherwise we are off by one return preg_replace('/'.ESC.'([^\[])/',"|$1",$this->fo->content); } }