diff options
author | John MacFarlane <jgm@berkeley.edu> | 2017-04-03 16:15:27 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-03 16:15:27 +0200 |
commit | 13cee8c32fb941383e62ab1309904736e25c1b06 (patch) | |
tree | f433c66a6b156e9d041e0f2ec52abff916755649 /src | |
parent | e3e52aa4c17aee452658e9252210d3621255964c (diff) | |
parent | 6e2019d58812df59d1cb74723c71305c9b233bae (diff) | |
download | pandoc-13cee8c32fb941383e62ab1309904736e25c1b06.tar.gz |
Merge pull request #3553 from nunull/master
Include \VerbatimFootnotes for highlighted code blocks
Diffstat (limited to 'src')
-rw-r--r-- | src/Text/Pandoc/Writers/LaTeX.hs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Text/Pandoc/Writers/LaTeX.hs b/src/Text/Pandoc/Writers/LaTeX.hs index eb38485de..70539a4a6 100644 --- a/src/Text/Pandoc/Writers/LaTeX.hs +++ b/src/Text/Pandoc/Writers/LaTeX.hs @@ -554,8 +554,11 @@ blockToLaTeX (CodeBlock (identifier,classes,keyvalAttr) str) = do unless (null msg) $ report $ CouldNotHighlight msg rawCodeBlock - Right h -> modify (\st -> st{ stHighlighting = True }) >> - return (flush $ linkAnchor $$ text (T.unpack h)) + Right h -> do + st <- get + when (stInNote st) $ modify (\s -> s{ stVerbInNote = True }) + modify (\s -> s{ stHighlighting = True }) + return (flush $ linkAnchor $$ text (T.unpack h)) case () of _ | isEnabled Ext_literate_haskell opts && "haskell" `elem` classes && "literate" `elem` classes -> lhsCodeBlock |