Org Writer: Write anchor elements

The Org Writer now writes empty span elements which have an id as an anchor.

For example `Span ("uid", [], []) []` becomes `<<uid>>`
This commit is contained in:
Matthew Pickering
2014-08-08 00:20:18 +01:00
parent 482f7f8e15
commit 07bb41d6da
+2
View File
@@ -238,6 +238,8 @@ inlineListToOrg lst = mapM inlineToOrg lst >>= return . hcat
-- | Convert Pandoc inline element to Org.
inlineToOrg :: Inline -> State WriterState Doc
inlineToOrg (Span (uid, [], []) []) =
return $ "<<" <> text uid <> ">>"
inlineToOrg (Span _ lst) =
inlineListToOrg lst
inlineToOrg (Emph lst) = do