Merge pull request #3490 from laloch/abbrevs-whole-words

abbrevs: only trigger completion if the word is preceded by space
This commit is contained in:
Morten Enemark Lund 2020-03-28 17:52:14 +01:00 committed by GitHub
commit 3d795b85ca
Failed to generate hash of commit

View file

@ -23,7 +23,7 @@ def expand_abbrev(buffer):
if abbrevs is None:
return
document = buffer.document
word = document.get_word_before_cursor()
word = document.get_word_before_cursor(WORD=True)
if word in abbrevs.keys():
partial = document.text[: document.cursor_position]
startix, endix, quote = check_for_partial_string(partial)