aboutsummaryrefslogtreecommitdiff
path: root/src/Text
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2021-01-02 08:19:00 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2021-01-02 08:19:00 -0800
commit260aaaacc640cc458259e292c42e15c3d2f34b3f (patch)
tree1d2967a60ddfe73de7b3f29e7a1ccaf5ec39dc46 /src/Text
parent9a18cf4b591364e7f0dc9b976628e91f8b31a6cf (diff)
downloadpandoc-260aaaacc640cc458259e292c42e15c3d2f34b3f.tar.gz
LaTeX reader: put contents of unknown environments in a Div...
when `raw_tex` is not enabled. (When `raw_tex` is enabled, the whole environment is parsed as a raw block.) The class name is the name of the environment. Previously, we just included the contents without the surrounding Div, but having a record of the environment's boundaries and name can be useful. Closes #6997.
Diffstat (limited to 'src/Text')
-rw-r--r--src/Text/Pandoc/Readers/LaTeX.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs
index afe960454..d9fe0f502 100644
--- a/src/Text/Pandoc/Readers/LaTeX.hs
+++ b/src/Text/Pandoc/Readers/LaTeX.hs
@@ -1835,7 +1835,7 @@ rawEnv name = do
report $ SkippedContent beginCommand pos1
pos2 <- getPosition
report $ SkippedContent ("\\end{" <> name <> "}") pos2
- return bs
+ return $ divWith ("",[name],[]) bs
rawVerbEnv :: PandocMonad m => Text -> LP m Blocks
rawVerbEnv name = do