mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-30 07:04:53 +01:00
Fix completion on a word with a trailing space causing the first letter to be duplicated
This commit is contained in:
parent
05cf89a1f0
commit
5cc32e394d
1 changed files with 1 additions and 1 deletions
|
|
@ -503,7 +503,7 @@ def complete_text(self, text):
|
|||
cursor_pos = self.cursorPosition()
|
||||
before_text = unicode(self.text())[:cursor_pos]
|
||||
after_text = unicode(self.text())[cursor_pos:]
|
||||
prefix_len = len(before_text.split(self.separator)[-1].strip())
|
||||
prefix_len = len(before_text.split(self.separator)[-1].lstrip())
|
||||
if self.space_before_sep:
|
||||
complete_text_pat = '%s%s %s %s'
|
||||
len_extra = 3
|
||||
|
|
|
|||
Loading…
Reference in a new issue