summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJesse Rosenthal <jrosenthal@jhu.edu>2017-12-21 11:09:05 -0500
committerJesse Rosenthal <jrosenthal@jhu.edu>2017-12-21 11:09:05 -0500
commit4d0cb0b2fca905dd4d5f0655af1a68a8a7074588 (patch)
tree34e0c5251e35bd01fc3914205fcb0b6e93772efb /src
parent4e53c7bf55354189a20423c2156963b779f0aa04 (diff)
Implement basic definition list functionality to PowerPoint writer.
These are currently implemented in terms of a Bold para for the terms, and then blockquotes for the definitions. THis can be refined a bit in the future.
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Writers/Powerpoint.hs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Writers/Powerpoint.hs b/src/Text/Pandoc/Writers/Powerpoint.hs
index b5f06c581..eb695b2be 100644
--- a/src/Text/Pandoc/Writers/Powerpoint.hs
+++ b/src/Text/Pandoc/Writers/Powerpoint.hs
@@ -411,6 +411,15 @@ blockToParagraphs (OrderedList listAttr blksLst) = do
, pPropMarginLeft = Nothing
}}) $
concatMapM multiParBullet blksLst
+blockToParagraphs (DefinitionList entries) = do
+ let go :: PandocMonad m => ([Inline], [[Block]]) -> P m [Paragraph]
+ go (ils, blksLst) = do
+ term <-blockToParagraphs $ Para [Strong ils]
+ -- For now, we'll treat each definition term as a
+ -- blockquote. We can extend this further later.
+ definition <- concatMapM (blockToParagraphs . BlockQuote) blksLst
+ return $ term ++ definition
+ concatMapM go entries
blockToParagraphs (Div _ blks) = concatMapM blockToParagraphs blks
-- TODO
blockToParagraphs blk = do