vigra icon indicating copy to clipboard operation
vigra copied to clipboard

Change doxygen LaTeX rendering to USE_MATHJAX

Open ukoethe opened this issue 13 years ago • 1 comments

See http://www.stack.nl/~dimitri/doxygen/formulas.html for details.

ukoethe avatar Aug 17 '11 19:08 ukoethe

This functionality is available as of doxygen 1.7.2. (Somewhat related: as of version 1.6.0, doxygen also includes a search engine. However, it may not be visible when a customized html header is used - a have to check this.)

One could include the MathJax sources in the VIGRA documentation, but it needs 33 MB of font files. However, most of this space is used for pre-rendered PNG fonts, which don't seem to be needed when SVG fonts are available.

Alternatively, one can use server-side rendering via an encrypted connection to the MathJax server. To activate this, include the following in each page header (before the </head> tag):

<script type="text/x-mathjax-config">
  MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});
</script>
<script type="text/javascript"
  src="https://d3eoax9i5htok0.cloudfront.net/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script>

The path can, of course, be replaced with the path to the local installation. Possibly, doxygen automatically inserts the appropriate header information when MATHJAX_RELPATH is set properly. Internet Explorer asked for permission to execute active page content, which may be annoying if asked too often.

ukoethe avatar Aug 19 '11 13:08 ukoethe