aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Writers/LaTeX.hs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Writers/LaTeX.hs b/src/Text/Pandoc/Writers/LaTeX.hs
index 3d25e0fc9..f93c168b7 100644
--- a/src/Text/Pandoc/Writers/LaTeX.hs
+++ b/src/Text/Pandoc/Writers/LaTeX.hs
@@ -131,6 +131,10 @@ pandocToLaTeX options (Pandoc (Meta title authors date) blocks) = do
_ -> []
context = writerVariables options ++
[ ("toc", if writerTableOfContents options then "yes" else "")
+ , ("toc-level", show (writerTOCLevel options -
+ if writerChapters options
+ then 1
+ else 0))
, ("body", main)
, ("title", titletext)
, ("title-meta", stringify title)