From 14f2668c26edee3c9ae85e412f31f2c1eca6b8b9 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 1 May 2014 21:14:38 +0530 Subject: [PATCH] ... --- src/calibre/gui2/tweak_book/editor/syntax/html.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/calibre/gui2/tweak_book/editor/syntax/html.py b/src/calibre/gui2/tweak_book/editor/syntax/html.py index 2419e59721..ac058f131e 100644 --- a/src/calibre/gui2/tweak_book/editor/syntax/html.py +++ b/src/calibre/gui2/tweak_book/editor/syntax/html.py @@ -441,7 +441,9 @@ class XMLHighlighter(HTMLHighlighter): state_map = xml_state_map spell_attributes = ('opf:file-as',) - create_formats_func = partial(create_formats, add_css=False) + + def create_formats_func(self): + return create_formats(self, add_css=False) def tag_ok_for_spell(self, name): return name in xml_spell_tags