aboutsummaryrefslogtreecommitdiff
path: root/src/Text
diff options
context:
space:
mode:
Diffstat (limited to 'src/Text')
-rw-r--r--src/Text/Pandoc/Writers/Muse.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/Muse.hs b/src/Text/Pandoc/Writers/Muse.hs
index 55d70c170..3c9c03be4 100644
--- a/src/Text/Pandoc/Writers/Muse.hs
+++ b/src/Text/Pandoc/Writers/Muse.hs
@@ -230,8 +230,9 @@ blockToMuse (DefinitionList items) = do
definitionListItemToMuse (label, defs) = do
modify $ \st -> st { stUseTags = False }
label' <- local (\env -> env { envOneLine = True, envAfterSpace = True }) $ inlineListToMuse' label
- let ind = offset label'
+ let ind = offset' label' -- using Text.Pandoc.Pretty.offset results in round trip failures
hang ind (nowrap label') . vcat <$> mapM descriptionToMuse defs
+ where offset' d = maximum (0: map length (lines $ render Nothing d))
descriptionToMuse :: PandocMonad m
=> [Block]
-> Muse m Doc