aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
authorJohn MacFarlane <fiddlosopher@gmail.com>2012-04-14 22:16:20 -0700
committerJohn MacFarlane <fiddlosopher@gmail.com>2012-04-14 22:16:20 -0700
commite2c3a7b896b076a218d94b9b0840599d399b0618 (patch)
tree0c60f96c084cc22683376a504236f2fef902edc0 /src/Text/Pandoc
parentc77e0c5d774cc0413c647e93c5f03e352a646a57 (diff)
downloadpandoc-e2c3a7b896b076a218d94b9b0840599d399b0618.tar.gz
Implemented abstract, constant, type, etc. in docbook reader.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Readers/DocBook.hs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Readers/DocBook.hs b/src/Text/Pandoc/Readers/DocBook.hs
index cfd7a6e58..8da933a2f 100644
--- a/src/Text/Pandoc/Readers/DocBook.hs
+++ b/src/Text/Pandoc/Readers/DocBook.hs
@@ -47,6 +47,7 @@ parseBlock (Elem e) =
"sect5" -> sect 5
"sect6" -> sect 6
"section" -> gets dbSectionLevel >>= sect . (+1)
+ "abstract" -> blockQuote <$> getBlocks e
"itemizedlist" -> bulletList <$> listitems
"orderedlist" -> orderedList <$> listitems -- TODO list attributes
"articleinfo" -> getTitle >> getAuthors >> getDate >> return mempty
@@ -107,6 +108,13 @@ parseInline (Elem e) =
then singleQuoted contents
else doubleQuoted contents
"literal" -> return $ code $ strContent e -- TODO attrs
+ "varname" -> return $ codeWith ("",["varname"],[]) $ strContent e
+ "function" -> return $ codeWith ("",["function"],[]) $ strContent e
+ "type" -> return $ codeWith ("",["type"],[]) $ strContent e
+ "symbol" -> return $ codeWith ("",["symbol"],[]) $ strContent e
+ "constant" -> return $ codeWith ("",["constant"],[]) $ strContent e
+ "userinput" -> return $ codeWith ("",["userinput"],[]) $ strContent e
+ "varargs" -> return $ str "(…)"
"ulink" -> link
(fromMaybe "" (lookupAttrBy (\attr -> qName attr == "url")
(elAttribs e))) "" <$> innerInlines