Improved editor to handle autocomplete of dictionary keys.

Sat, 18 Apr 2020 16:07:05 +0200

author
T.Rzepka <Tobias.Rzepka@gmail.com>
date
Sat, 18 Apr 2020 16:07:05 +0200
changeset 7543
a737e240f27b
parent 7542
162527b48aac
child 7544
366c7c6582d8

Improved editor to handle autocomplete of dictionary keys.

eric6/QScintilla/Editor.py file | annotate | diff | comparison | revisions
--- a/eric6/QScintilla/Editor.py	Fri Apr 17 19:31:38 2020 +0200
+++ b/eric6/QScintilla/Editor.py	Sat Apr 18 16:07:05 2020 +0200
@@ -5143,6 +5143,9 @@
                     line, col = self.getCursorPosition()
                 elif wLeft:
                     txt = txt[len(wLeft):]
+                
+                if txt[0] in "'\"":  # New in jedi 0.16: AC of dict keys
+                    txt = txt[1:]
             self.insert(txt)
             self.endUndoAction()
             self.setCursorPosition(line, col + len(txt))

eric ide

mercurial