aboutsummaryrefslogtreecommitdiff
path: root/doc/markup.rst
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2017-03-23 09:25:33 -0400
committerBen Gamari <ben@smart-cactus.org>2017-03-23 09:25:33 -0400
commit606da884355527051afe0058c2f8b0ac2005e01b (patch)
tree9388f16cb30761dd3f37c0bd3b6e251f9ebc2f87 /doc/markup.rst
parent4eb765ca4205c79539d60b7afa9b7e261a4a49fe (diff)
parent240bc38b94ed2d0af27333b23392d03eeb615e82 (diff)
Merge commit '240bc38b94ed2d0af27333b23392d03eeb615e82' into HEAD
Diffstat (limited to 'doc/markup.rst')
-rw-r--r--doc/markup.rst17
1 files changed, 16 insertions, 1 deletions
diff --git a/doc/markup.rst b/doc/markup.rst
index a2274ad6..b0ebc738 100644
--- a/doc/markup.rst
+++ b/doc/markup.rst
@@ -501,7 +501,7 @@ Special characters
~~~~~~~~~~~~~~~~~~
The following characters have special meanings in documentation
-comments: ``\\``, ``/``, ``'``, ``\```, ``"``, ``@``, ``<``. To insert a
+comments: ``\\``, ``/``, ``'``, ``\```, ``"``, ``@``, ``<``, ``$``. To insert a
literal occurrence of one of these special characters, precede it with a
backslash (``\\``).
@@ -799,6 +799,21 @@ If the output format supports it, the image will be rendered inside the
documentation. The image description is used as relpacement text and/or
image title.
+Mathematics / LaTeX
+~~~~~~~~~~~~~~~~~~~
+
+Haddock supports LaTeX syntax for rendering mathematical notation. The
+delimiters are ``\[...\]`` for displayed mathematics and ``\(...\)``
+for in-line mathematics. An example looks like this: ::
+
+ \[
+ f(a) = \frac{1}{2\pi i}\oint_\gamma \frac{f(z)}{z-a}\,\mathrm{d}z
+ \]
+
+If the output format supports it, the mathematics will be rendered
+inside the documentation. For example, the HTML backend will display
+the mathematics via `MathJax <https://www.mathjax.org>`__.
+
Anchors
~~~~~~~