[commit: haddock] alexbiehl-patch-1, ghc-8.0, ghc-head, ghc-head1, headdock-library-1.4.5, ie_avails, master, pr-filter-maps, pr/cabal-desc, travis, v2.17, v2.18, wip/T14529, wip/new-tree-one-param, wip/rae, wip/remove-frames, wip/remove-frames1, wip/revert-ttg-2017-11-20, wip/ttg-2017-10-13, wip/ttg-2017-10-31, wip/ttg-2017-11-06, wip/ttg2-2017-11-10, wip/ttg3-2017-11-12, wip/ttg4-constraints-2017-11-13, wip/ttg6-unrevert-2017-11-22: Documentation for LaTeX markup. (ccd952f)

git at git.haskell.org git at git.haskell.org
Tue Nov 28 11:47:16 UTC 2017


Repository : ssh://git@git.haskell.org/haddock

On branches: alexbiehl-patch-1,ghc-8.0,ghc-head,ghc-head1,headdock-library-1.4.5,ie_avails,master,pr-filter-maps,pr/cabal-desc,travis,v2.17,v2.18,wip/T14529,wip/new-tree-one-param,wip/rae,wip/remove-frames,wip/remove-frames1,wip/revert-ttg-2017-11-20,wip/ttg-2017-10-13,wip/ttg-2017-10-31,wip/ttg-2017-11-06,wip/ttg2-2017-11-10,wip/ttg3-2017-11-12,wip/ttg4-constraints-2017-11-13,wip/ttg6-unrevert-2017-11-22
Link       : http://git.haskell.org/haddock.git/commitdiff/ccd952f8741a1818afac6ee50a54c0a7f4dee4b3

>---------------------------------------------------------------

commit ccd952f8741a1818afac6ee50a54c0a7f4dee4b3
Author: Dominic Steinitz <dominic at steinitz.org>
Date:   Thu Jun 9 09:27:28 2016 +0100

    Documentation for LaTeX markup.


>---------------------------------------------------------------

ccd952f8741a1818afac6ee50a54c0a7f4dee4b3
 doc/markup.rst | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/doc/markup.rst b/doc/markup.rst
index a2274ad..733b810 100644
--- a/doc/markup.rst
+++ b/doc/markup.rst
@@ -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 mathemetics 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.
+
 Anchors
 ~~~~~~~
 



More information about the ghc-commits mailing list