mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
ba1e8510fa
commit
05a90f1bcb
@ -30,8 +30,6 @@ class GetCharMap:
|
||||
|
||||
'char_file'--the file with the mappings
|
||||
|
||||
|
||||
|
||||
Returns:
|
||||
|
||||
nothing
|
||||
@ -62,7 +60,6 @@ class GetCharMap:
|
||||
fields[1].replace('\\colon', ':')
|
||||
map_dict[fields[1]] = fields[3]
|
||||
|
||||
|
||||
if not found_map:
|
||||
msg = 'no map found\nmap is "%s"\n'%(map,)
|
||||
raise self.__bug_handler, msg
|
||||
|
@ -155,7 +155,6 @@ class Hex2Utf8:
|
||||
char_file = self.__char_file,
|
||||
bug_handler = self.__bug_handler,
|
||||
)
|
||||
print self.__default_char_map
|
||||
up_128_dict = char_map_obj.get_char_map(map=self.__default_char_map)
|
||||
bt_128_dict = char_map_obj.get_char_map(map = 'bottom_128')
|
||||
ms_standard_dict = char_map_obj.get_char_map(map = 'ms_standard')
|
||||
|
@ -757,7 +757,7 @@ class ProcessTokens:
|
||||
def process_cw(self, token):
|
||||
"""Change the value of the control word by determining what dictionary
|
||||
it belongs to"""
|
||||
special = [ '*', ':', '}', '{', '~', '_', '-', ';' ]
|
||||
special = [ '*', ':', '}', '{', '~', '_', '-', ';' ]
|
||||
##if token != "{" or token != "}":
|
||||
token = token[1:] # strip off leading \
|
||||
token = token.replace(" ", "")
|
||||
@ -793,7 +793,7 @@ class ProcessTokens:
|
||||
raise self.__exception_handler, msg
|
||||
|
||||
the_index = token.find('\\ ')
|
||||
if token is not None and the_index > -1:
|
||||
if token is not None and the_index > -1:
|
||||
msg = 'Invalid RTF: token "\\ " not valid.\n'
|
||||
raise self.__exception_handler, msg
|
||||
elif token[:1] == "\\":
|
||||
|
Loading…
x
Reference in New Issue
Block a user