18 const HTML =
"html4strict";
34 self::VISUAL_BASIC =>
"Visual Basic",
35 self::DELPHI =>
"Delphi" 44 "html" =>
"html4strict" 60 $this->lang = $a_lang;
71 return new self($a_lang);
93 return isset(self::$langs[$a_lang]);
104 if (isset(self::$v51_map[$a_old_lang_id]))
106 return self::$v51_map[$a_old_lang_id];
108 return $a_old_lang_id;
121 $map = array_flip(self::$v51_map);
122 foreach (self::$langs as $k => $v)
141 include_once(
"./libs/composer/vendor/geshi/geshi/src/geshi.php");
142 $geshi =
new Geshi(html_entity_decode($a_code), $this->lang);
147 $a_code =
$geshi->parse_code();
150 $a_code = substr($a_code, strpos($a_code,
">") + 1);
151 $a_code = substr($a_code, 0, strrpos($a_code,
"<"));
static getNewLanguageId($a_old_lang_id)
Get new language id (for an old one)
if(strncmp($real_path, SOURCE_ROOT, $base_path_len)) if(!file_exists($path)) $geshi
Syntax highlighter wrapper class.
highlight($a_code)
Highlight code.
static getSupportedLanguages()
Get supported languages (keys are internal values, values are for representation) ...
Create styles array
The data for the language used.
static getSupportedLanguagesV51()
Get supported languages (keys are ILIAS <= 5.1 internal values, values are for representation) ...
static isSupported($a_lang)
Is language supported?
static getInstance($a_lang)
Get instance.
__construct($a_lang)
Constructor.