Lines Matching +full:dokuwiki +full:- +full:env

3  * DokuWiki Plugin KaTeX (Syntax Component: protect)
5 * protect TeX expressions before DokuWiki trying to parse them.
7 * @license GPLv3 https://www.gnu.org/licenses/gpl-3.0.html
8 * @author H.-H. PENG (Hsins) <hsinspeng@gmail.com>
12 // must be run within Dokuwiki
22 # We need to grab any math before dokuwiki tries to parse it.
25 # Set of environments that this plugin will protect from Dokuwiki parsing
69 * regexp patterns adapted from jsMath plugin: https://www.dokuwiki.org/plugin:jsmath
75 … $this->Lexer->addEntryPattern( '(?<!\\\\)\$(?=[^\$][^\r\n]*?\$)', $mode, 'plugin_katex_protect' );
76 $this->Lexer->addEntryPattern( '\$\$(?=.*?\$\$)', $mode, 'plugin_katex_protect' );
77 $this->Lexer->addEntryPattern( '\\\\\((?=.*?\\\\\))', $mode, 'plugin_katex_protect' );
78 $this->Lexer->addEntryPattern( '\\\\\[(?=.*?\\\\])', $mode, 'plugin_katex_protect' );
79 foreach ( self::$ENVIRONMENTS as $env ) {
80 …$this->Lexer->addEntryPattern( '\\\\begin{' . $env . '}(?=.*?\\\\end{' . $env . '})', $mode, 'plug…
83 if ( $this->getConf( 'asciimath' ) ) {
85 $this->Lexer->addEntryPattern( '`(?=.*?`)', $mode, 'plugin_katex_protect' );
89 $conf_mathtags = $this->getConf( 'mathtags' );
94 …$this->Lexer->addEntryPattern( '<' . $tag . '.*?>(?=.*?</' . $tag . '>)', $mode, 'plugin_katex_pro…
100 $this->Lexer->addExitPattern( '\$(?!\$)', 'plugin_katex_protect' );
101 $this->Lexer->addExitPattern( '\\\\\)', 'plugin_katex_protect' );
102 $this->Lexer->addExitPattern( '\\\\\]', 'plugin_katex_protect' );
103 foreach ( self::$ENVIRONMENTS as $env ) {
104 $this->Lexer->addExitPattern( '\\\\end{' . $env . '}', 'plugin_katex_protect' );
107 if ( $this->getConf( 'asciimath' ) ) {
109 $this->Lexer->addExitPattern( '`', 'plugin_katex_protect' );
113 $conf_mathtags = $this->getConf( 'mathtags' );
118 $this->Lexer->addExitPattern( '</' . $tag . '>', 'plugin_katex_protect' );
125 * This function can only pass data to render() via its return value - render()
156 $renderer->doc .= $renderer->_xmlEntities( $data );
161 $renderer->mathjax_content( $data );
166 $renderer->doc .= $data;