From 6509ff62043b6445098cc9c94628fab464638f62 Mon Sep 17 00:00:00 2001 From: Tristan Stenner Date: Tue, 26 Oct 2021 15:03:12 +0200 Subject: Docx writer: move ": " out of the caption bookmark. This is needed so that native references to the figure are included as "As seen in Figure X, it is..." instead of "As seen in [Figure: , it is..." --- src/Text/Pandoc/Writers/Docx/Table.hs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/Text/Pandoc/Writers/Docx') diff --git a/src/Text/Pandoc/Writers/Docx/Table.hs b/src/Text/Pandoc/Writers/Docx/Table.hs index e23856f28..4dc4ad6a2 100644 --- a/src/Text/Pandoc/Writers/Docx/Table.hs +++ b/src/Text/Pandoc/Writers/Docx/Table.hs @@ -98,8 +98,8 @@ tableToOpenXML opts blocksToOpenXML gridTable = do addLabel :: Text -> Text -> Int -> [Block] -> [Block] addLabel tableid tablename tablenum bs = case bs of - (Para ils : rest) -> Para (label : Space : ils) : rest - (Plain ils : rest) -> Plain (label : Space : ils) : rest + (Para ils : rest) -> Para (label : Str ": " : ils) : rest + (Plain ils : rest) -> Plain (label : Str ": " : ils) : rest _ -> Para [label] : bs where label = Span (tableid,[],[]) @@ -108,8 +108,7 @@ addLabel tableid tablename tablenum bs = (" " \\* ARABIC \">" <> tshow tablenum - <> ""), - Str ":"] + <> "")] -- | Parts of a table data RowType = HeadRow | BodyRow | FootRow -- cgit v1.2.3