Make raw content marked beamer
work in beamer
output.
See pandoc/lua-filters#40.
This commit is contained in:
parent
dfd1796cf2
commit
24a0d613a8
1 changed files with 18 additions and 14 deletions
|
@ -693,10 +693,12 @@ blockToLaTeX (CodeBlock (identifier,classes,keyvalAttr) str) = do
|
||||||
| not (null classes) && isJust (writerHighlightStyle opts)
|
| not (null classes) && isJust (writerHighlightStyle opts)
|
||||||
-> highlightedCodeBlock
|
-> highlightedCodeBlock
|
||||||
| otherwise -> rawCodeBlock
|
| otherwise -> rawCodeBlock
|
||||||
blockToLaTeX b@(RawBlock f x)
|
blockToLaTeX b@(RawBlock f x) = do
|
||||||
| f == Format "latex" || f == Format "tex"
|
beamer <- gets stBeamer
|
||||||
= return $ text x
|
if (f == Format "latex" || f == Format "tex" ||
|
||||||
| otherwise = do
|
(f == Format "beamer" && beamer))
|
||||||
|
then return $ text x
|
||||||
|
else do
|
||||||
report $ BlockNotRendered b
|
report $ BlockNotRendered b
|
||||||
return empty
|
return empty
|
||||||
blockToLaTeX (BulletList []) = return empty -- otherwise latex error
|
blockToLaTeX (BulletList []) = return empty -- otherwise latex error
|
||||||
|
@ -1189,12 +1191,14 @@ inlineToLaTeX (Math InlineMath str) = do
|
||||||
inlineToLaTeX (Math DisplayMath str) = do
|
inlineToLaTeX (Math DisplayMath str) = do
|
||||||
setEmptyLine False
|
setEmptyLine False
|
||||||
return $ "\\[" <> text (handleMathComment str) <> "\\]"
|
return $ "\\[" <> text (handleMathComment str) <> "\\]"
|
||||||
inlineToLaTeX il@(RawInline f str)
|
inlineToLaTeX il@(RawInline f str) = do
|
||||||
| f == Format "latex" || f == Format "tex"
|
beamer <- gets stBeamer
|
||||||
= do
|
if (f == Format "latex" || f == Format "tex" ||
|
||||||
|
(f == Format "beamer" && beamer))
|
||||||
|
then do
|
||||||
setEmptyLine False
|
setEmptyLine False
|
||||||
return $ text str
|
return $ text str
|
||||||
| otherwise = do
|
else do
|
||||||
report $ InlineNotRendered il
|
report $ InlineNotRendered il
|
||||||
return empty
|
return empty
|
||||||
inlineToLaTeX LineBreak = do
|
inlineToLaTeX LineBreak = do
|
||||||
|
|
Loading…
Add table
Reference in a new issue