@@ -108,7 +108,7 @@ plainToPara :: Block -> Block
108108plainToPara (Plain x) = Para x
109109plainToPara x = x
110110
111−-- | Convert a list of pairs of terms and definitions into a TEI
111+-- | Convert a list of pairs of terms and definitions into a TEI
112112-- list with labels and items.
113113deflistItemsToTEI :: WriterOptions -> [([Inline],[[Block]])] -> Doc
114114deflistItemsToTEI opts items =
@@ -167,6 +167,8 @@ blockToTEI opts (Plain lst) = blockToTEI opts $ Para lst
167167-- inTagsSimple "textobject" (inTagsSimple "phrase" alt))
168168blockToTEI opts (Para lst) =
169169 inTags False "p" [] $ inlinesToTEI opts lst
170+blockToTEI opts (LineBlock lns) =
171+ blockToTEI opts $ linesToPara lns
170172blockToTEI opts (BlockQuote blocks) =
171173 inTagsIndented "quote" $ blocksToTEI opts blocks
172174blockToTEI _ (CodeBlock (_,classes,_) str) =
@@ -174,7 +176,7 @@ blockToTEI _ (CodeBlock (_,classes,_) str) =
174176 flush (text (escapeStringForXML str) <> cr <> text "</ab>")
175177 where lang = if null langs
176178 then ""
177− else escapeStringForXML (head langs)
179+ else escapeStringForXML (head langs)
178180 isLang l = map toLower l `elem` map (map toLower) languages
179181 langsFrom s = if isLang s
180182 then [s]
@@ -210,7 +212,7 @@ blockToTEI _ HorizontalRule =
210212 selfClosingTag "milestone" [("unit","undefined"), ("type","separator"),("rendition","line")]
211213
212214-- | TEI Tables
213−-- TEI Simple's tables are composed of cells and rows; other
215+-- TEI Simple's tables are composed of cells and rows; other
214216-- table info in the AST is here lossily discard.
215217blockToTEI opts (Table _ _ _ headers rows) =
216218 let
@@ -219,8 +221,8 @@ blockToTEI opts (Table _ _ _ headers rows) =
219221-- then return empty
220222-- else tableRowToTEI opts headers
221223 in
222− inTags True "table" [] $
223− vcat $ [headers'] <> map (tableRowToTEI opts) rows
224+ inTags True "table" [] $
225+ vcat $ [headers'] <> map (tableRowToTEI opts) rows
224226
225227tableRowToTEI :: WriterOptions
226228 -> [[Block]]
@@ -276,7 +278,7 @@ inlineToTEI _ (Math t str) =
276278 text (str)
277279 DisplayMath -> inTags True "figure" [("type","math")] $
278280 inTags False "formula" [("notation","TeX")] $ text (str)
279−
281+
280282inlineToTEI _ (RawInline f x) | f == "tei" = text x
281283 | otherwise = empty
282284inlineToTEI _ LineBreak = selfClosingTag "lb" []
@@ -317,4 +319,3 @@ idAndRole (id',cls,_) = ident ++ role
317319 role = if null cls
318320 then []
319321 else [("role", unwords cls)]
320−