ILIAS
release_8 Revision v8.19
|
Global Mathjax configuration. More...
Public Member Functions | |
__construct (bool $client_enabled, string $client_polyfill_url, string $client_script_url, int $client_limiter, bool $server_enabled, string $server_address, int $server_timeout, bool $server_for_browser, bool $server_for_export, bool $server_for_pdf) | |
Constructor. More... | |
getMathJax2DefaultUrl () | |
Get the default URL for including MathJax 2. More... | |
getMathJax3DefaultUrl () | |
Get the default URL for including MathJax 3. More... | |
isClientEnabled () | |
Should latex code be rendered in the browser. More... | |
getClintPolyfillUrl () | |
Url of a javascript polyfill (needed by MathJax 3) More... | |
getClientScriptUrl () | |
Url of Mathjax script to be embedded with script tag on the page. More... | |
getClientLimiter () | |
Type of enclosing limiters for wich the embedded client-side Mathjax is configured. More... | |
getClientLimiterOptions () | |
Get the avaliable options for the client limiters. More... | |
getClientLimiterStart () | |
Start limiter of Latex code which the client-side Mathjax searches for. More... | |
getClientLimiterEnd () | |
End limiter of Latex code which the client-side Mathjax searches for. More... | |
isServerEnabled () | |
Is a server side rendering engine configured and enabled. More... | |
getServerAddress () | |
Url of Mathjax server. More... | |
getServerTimeout () | |
timeout (s) to wait for the result of the rendering server More... | |
isServerForBrowser () | |
Should the server-side rendingeing be used for browser output. More... | |
isServerForExport () | |
Should the server-side rendingeing be used for HTML exports. More... | |
isServerForPdf () | |
Should the server-side rendingeing be used for PDF generation. More... | |
withClientEnabled (bool $client_enabled) | |
Enable latex code bing rendered in the browser. More... | |
withClientPolyfillUrl (string $client_js_url) | |
Set the url of a polyfill script neededby MathJax 3. More... | |
withClientScriptUrl (string $client_async_url) | |
Set the url of Mathjax script to be embedded on the page (for MathJax 3) More... | |
withClientLimiter (int $client_limiter) | |
Set the type of enclosing limiters for wich the embedded client-side Mathjax is configured. More... | |
withServerEnabled (bool $server_enabled) | |
Enable a server side rendering engine configured and enabled. More... | |
withServerAddress (string $server_address) | |
Set the url of the Mathjax server. More... | |
withServerTimeout (int $server_timeout) | |
Set the timeout (s) to wait for the result of the rendering server. More... | |
withServerForBrowser (bool $server_for_browser) | |
Enable the server-side rendingeing for browser output. More... | |
withServerForExport (bool $server_for_export) | |
Enable the server-side rendingeing for HTML exports. More... | |
withServerForPdf (bool $server_for_pdf) | |
Enable the server-side rendingeing for PDF generation. More... | |
Protected Attributes | |
bool | $client_enabled |
string | $client_polyfill_url |
string | $client_script_url |
int | $client_limiter |
bool | $server_enabled |
string | $server_address |
int | $server_timeout |
bool | $server_for_browser |
bool | $server_for_export |
bool | $server_for_pdf |
Private Attributes | |
const | MATHJAX2_DEFAULT_URL = 'https://cdn.jsdelivr.net/npm/mathjax@2.7.9/MathJax.js?config=TeX-AMS-MML_HTMLorMML,Safe' |
const | MATHJAX3_RELATIVE_URL = 'Services/MathJax/js/cdn-mathjax3-es5-tex-mml-chtml-safe.js' |
const | LIMITER_MATHJAX = 0 |
const | LIMITER_TEX = 1 |
const | LIMITER_SPAN = 2 |
Global Mathjax configuration.
Definition at line 24 of file class.ilMathJaxConfig.php.
ilMathJaxConfig::__construct | ( | bool | $client_enabled, |
string | $client_polyfill_url, | ||
string | $client_script_url, | ||
int | $client_limiter, | ||
bool | $server_enabled, | ||
string | $server_address, | ||
int | $server_timeout, | ||
bool | $server_for_browser, | ||
bool | $server_for_export, | ||
bool | $server_for_pdf | ||
) |
Constructor.
Definition at line 47 of file class.ilMathJaxConfig.php.
References $client_enabled, $client_limiter, $server_enabled, $server_for_browser, $server_for_export, $server_for_pdf, and $server_timeout.
ilMathJaxConfig::getClientLimiter | ( | ) |
Type of enclosing limiters for wich the embedded client-side Mathjax is configured.
Definition at line 118 of file class.ilMathJaxConfig.php.
References $client_limiter.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::getClientLimiterEnd | ( | ) |
End limiter of Latex code which the client-side Mathjax searches for.
Definition at line 155 of file class.ilMathJaxConfig.php.
ilMathJaxConfig::getClientLimiterOptions | ( | ) |
Get the avaliable options for the client limiters.
Definition at line 127 of file class.ilMathJaxConfig.php.
ilMathJaxConfig::getClientLimiterStart | ( | ) |
Start limiter of Latex code which the client-side Mathjax searches for.
Definition at line 139 of file class.ilMathJaxConfig.php.
ilMathJaxConfig::getClientScriptUrl | ( | ) |
Url of Mathjax script to be embedded with script tag on the page.
Definition at line 110 of file class.ilMathJaxConfig.php.
References $client_script_url.
Referenced by ilMathJaxConfigCheckedObjective\checkClientScriptUrl(), ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::getClintPolyfillUrl | ( | ) |
Url of a javascript polyfill (needed by MathJax 3)
Definition at line 102 of file class.ilMathJaxConfig.php.
References $client_polyfill_url.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::getMathJax2DefaultUrl | ( | ) |
Get the default URL for including MathJax 2.
Definition at line 77 of file class.ilMathJaxConfig.php.
ilMathJaxConfig::getMathJax3DefaultUrl | ( | ) |
Get the default URL for including MathJax 3.
Definition at line 85 of file class.ilMathJaxConfig.php.
ilMathJaxConfig::getServerAddress | ( | ) |
Url of Mathjax server.
Definition at line 179 of file class.ilMathJaxConfig.php.
References $server_address.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::getServerTimeout | ( | ) |
timeout (s) to wait for the result of the rendering server
Definition at line 187 of file class.ilMathJaxConfig.php.
References $server_timeout.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::isClientEnabled | ( | ) |
Should latex code be rendered in the browser.
Definition at line 94 of file class.ilMathJaxConfig.php.
References $client_enabled.
Referenced by ilMathJaxConfigCheckedObjective\checkClientScriptUrl(), ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::isServerEnabled | ( | ) |
Is a server side rendering engine configured and enabled.
Definition at line 171 of file class.ilMathJaxConfig.php.
References $server_enabled.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::isServerForBrowser | ( | ) |
Should the server-side rendingeing be used for browser output.
Definition at line 195 of file class.ilMathJaxConfig.php.
References $server_for_browser.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::isServerForExport | ( | ) |
Should the server-side rendingeing be used for HTML exports.
Definition at line 203 of file class.ilMathJaxConfig.php.
References $server_for_export.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::isServerForPdf | ( | ) |
Should the server-side rendingeing be used for PDF generation.
Definition at line 211 of file class.ilMathJaxConfig.php.
References $server_for_pdf.
Referenced by ilMathJaxSetupConfig\getDataFromConfig(), ilMathJaxSetupConfig\isApplicableTo(), and ilMathJaxConfigSettingsRepository\updateConfig().
ilMathJaxConfig::withClientEnabled | ( | bool | $client_enabled | ) |
Enable latex code bing rendered in the browser.
Definition at line 219 of file class.ilMathJaxConfig.php.
References $client_enabled.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withClientLimiter | ( | int | $client_limiter | ) |
Set the type of enclosing limiters for wich the embedded client-side Mathjax is configured.
Definition at line 249 of file class.ilMathJaxConfig.php.
References $client_limiter.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withClientPolyfillUrl | ( | string | $client_js_url | ) |
Set the url of a polyfill script neededby MathJax 3.
Definition at line 229 of file class.ilMathJaxConfig.php.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withClientScriptUrl | ( | string | $client_async_url | ) |
Set the url of Mathjax script to be embedded on the page (for MathJax 3)
Definition at line 239 of file class.ilMathJaxConfig.php.
Referenced by ilMathJaxSetupConfig\applyTo(), and ilMathJaxConfigCheckedObjective\checkClientScriptUrl().
ilMathJaxConfig::withServerAddress | ( | string | $server_address | ) |
Set the url of the Mathjax server.
Definition at line 269 of file class.ilMathJaxConfig.php.
References $server_address.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withServerEnabled | ( | bool | $server_enabled | ) |
Enable a server side rendering engine configured and enabled.
Definition at line 259 of file class.ilMathJaxConfig.php.
References $server_enabled.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withServerForBrowser | ( | bool | $server_for_browser | ) |
Enable the server-side rendingeing for browser output.
Definition at line 289 of file class.ilMathJaxConfig.php.
References $server_for_browser.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withServerForExport | ( | bool | $server_for_export | ) |
Enable the server-side rendingeing for HTML exports.
Definition at line 299 of file class.ilMathJaxConfig.php.
References $server_for_export.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withServerForPdf | ( | bool | $server_for_pdf | ) |
Enable the server-side rendingeing for PDF generation.
Definition at line 309 of file class.ilMathJaxConfig.php.
References $server_for_pdf.
Referenced by ilMathJaxSetupConfig\applyTo().
ilMathJaxConfig::withServerTimeout | ( | int | $server_timeout | ) |
Set the timeout (s) to wait for the result of the rendering server.
Definition at line 279 of file class.ilMathJaxConfig.php.
References $server_timeout.
Referenced by ilMathJaxSetupConfig\applyTo().
|
protected |
Definition at line 33 of file class.ilMathJaxConfig.php.
Referenced by __construct(), isClientEnabled(), and withClientEnabled().
|
protected |
Definition at line 36 of file class.ilMathJaxConfig.php.
Referenced by __construct(), getClientLimiter(), and withClientLimiter().
|
protected |
Definition at line 34 of file class.ilMathJaxConfig.php.
Referenced by getClintPolyfillUrl().
|
protected |
Definition at line 35 of file class.ilMathJaxConfig.php.
Referenced by getClientScriptUrl().
|
protected |
Definition at line 38 of file class.ilMathJaxConfig.php.
Referenced by getServerAddress(), and withServerAddress().
|
protected |
Definition at line 37 of file class.ilMathJaxConfig.php.
Referenced by __construct(), isServerEnabled(), and withServerEnabled().
|
protected |
Definition at line 40 of file class.ilMathJaxConfig.php.
Referenced by __construct(), isServerForBrowser(), and withServerForBrowser().
|
protected |
Definition at line 41 of file class.ilMathJaxConfig.php.
Referenced by __construct(), isServerForExport(), and withServerForExport().
|
protected |
Definition at line 42 of file class.ilMathJaxConfig.php.
Referenced by __construct(), isServerForPdf(), and withServerForPdf().
|
protected |
Definition at line 39 of file class.ilMathJaxConfig.php.
Referenced by __construct(), getServerTimeout(), and withServerTimeout().
|
private |
Definition at line 29 of file class.ilMathJaxConfig.php.
|
private |
Definition at line 31 of file class.ilMathJaxConfig.php.
|
private |
Definition at line 30 of file class.ilMathJaxConfig.php.
|
private |
Definition at line 26 of file class.ilMathJaxConfig.php.
|
private |
Definition at line 27 of file class.ilMathJaxConfig.php.