From 420c86b69a5491dfa1c775d8274685efc49a17e3 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Sat, 14 Nov 2015 17:19:25 -0800 Subject: Allow more customization of opendocument styles. Automatic styles can now be inserted in the template, since the template, not the writer, now provides the enclosing `` tags. Closes #2520. --- src/Text/Pandoc/Writers/OpenDocument.hs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/Text/Pandoc') diff --git a/src/Text/Pandoc/Writers/OpenDocument.hs b/src/Text/Pandoc/Writers/OpenDocument.hs index ebe678dc0..7ee87f4af 100644 --- a/src/Text/Pandoc/Writers/OpenDocument.hs +++ b/src/Text/Pandoc/Writers/OpenDocument.hs @@ -191,8 +191,7 @@ writeOpenDocument opts (Pandoc meta blocks) = listStyle (n,l) = inTags True "text:list-style" [("style:name", "L" ++ show n)] (vcat l) listStyles = map listStyle (stListStyles s) - automaticStyles = inTagsIndented "office:automatic-styles" $ vcat $ - reverse $ styles ++ listStyles + automaticStyles = vcat $ reverse $ styles ++ listStyles context = defField "body" body $ defField "automatic-styles" (render' automaticStyles) $ metadata -- cgit v1.2.3