From 3b7275d9e2be7f73890eb48fff9cfadf963ebf8b Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 4 May 2017 12:45:17 +0530 Subject: [PATCH] Use empty text instead of having empty inline anchor point to start of block --- src/calibre/ebooks/docx/writer/from_html.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/ebooks/docx/writer/from_html.py b/src/calibre/ebooks/docx/writer/from_html.py index e12d3fa39c..135d64afde 100644 --- a/src/calibre/ebooks/docx/writer/from_html.py +++ b/src/calibre/ebooks/docx/writer/from_html.py @@ -570,7 +570,7 @@ class Convert(object): block.add_text(html_tag.text, tag_style, is_parent_style=False, bookmark=bmark, link=self.current_link, lang=self.current_lang) elif bmark: block = self.create_block_from_parent(html_tag, stylizer) - block.bookmarks.add(bmark) + block.add_text('', tag_style, is_parent_style=False, bookmark=bmark, link=self.current_link, lang=self.current_lang) def bookmark_for_anchor(self, anchor, html_tag): return self.links_manager.bookmark_for_anchor(anchor, self.current_item, html_tag)