@@ -279,7 +279,17 @@ blockListToConTeXt lst = liftM vcat $ mapM blockToConTeXt lst
279279-- | Convert list of inline elements to ConTeXt.
280280inlineListToConTeXt :: [Inline] -- ^ Inlines to convert
281281 -> State WriterState Doc
282−inlineListToConTeXt lst = liftM hcat $ mapM inlineToConTeXt lst
282+inlineListToConTeXt lst = liftM hcat $ mapM inlineToConTeXt $ addStruts lst
283+ -- We add a \strut after a line break that precedes a space,
284+ -- or the space gets swallowed
285+ where addStruts (LineBreak : s : xs) | isSpacey s =
286+ LineBreak : RawInline (Format "context") "\\strut " : s :
287+ addStruts xs
288+ addStruts (x:xs) = x : addStruts xs
289+ addStruts [] = []
290+ isSpacey Space = True
291+ isSpacey (Str ('\160':_)) = True
292+ isSpacey _ = False
283293
284294-- | Convert inline element to ConTeXt
285295inlineToConTeXt :: Inline -- ^ Inline to convert