diff --git a/Text/LaTeX/Base/Render.hs b/Text/LaTeX/Base/Render.hs index e3fae51..f1f9591 100644 --- a/Text/LaTeX/Base/Render.hs +++ b/Text/LaTeX/Base/Render.hs @@ -136,6 +136,11 @@ instance Render LaTeX where in if null xs then "%\n" else Data.Text.unlines $ fmap ("%" <>) xs + render (TeXSeq l1@(TeXCommS _) l2) = let r2 = render l2 in + render l1 <> (case uncons r2 of + Just (c,_) | isIdentChar c -> " " + _ -> "") <> r2 + where isIdentChar = isAlpha render (TeXSeq l1 l2) = render l1 <> render l2 render TeXEmpty = mempty