summaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>2007-08-25 18:17:01 +0000
committerfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>2007-08-25 18:17:01 +0000
commitf609755cb6eed6e0f42f90f1c6814f7578b2000a (patch)
treea83794affc8f719a7829630d9be842c708e85120 /src/Text/Pandoc
parentab23086b1b9d39d3d1466d9799f59ce4e13e6e8b (diff)
Fixed bug in LaTeX writer. When a footnote ends with a Verbatim
environment, the close } of the footnote needs to occur on the same line or an error occurs. Fixed by adding a newline before the close } in every footnote. git-svn-id: https://pandoc.googlecode.com/svn/trunk@897 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Writers/LaTeX.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/LaTeX.hs b/src/Text/Pandoc/Writers/LaTeX.hs
index ad1f3e45f..530bd26e1 100644
--- a/src/Text/Pandoc/Writers/LaTeX.hs
+++ b/src/Text/Pandoc/Writers/LaTeX.hs
@@ -278,4 +278,6 @@ inlineToLaTeX (Note contents) = do
contents' <- blockListToLaTeX contents
st <- get
put (st {stInNote = False})
- return $ "\\footnote{" ++ stripTrailingNewlines contents' ++ "}"
+ return $ "\\footnote{" ++ stripTrailingNewlines contents' ++ "\n}"
+ -- note: the \n before } is important; removing it causes problems
+ -- if a Verbatim environment occurs at the end of the footnote.