#REFACTORING by cg
authorClaus Gittinger <cg@exept.de>
Wed, 05 Jun 2019 17:09:27 +0200
changeset 6594 c347f9e598d7
parent 6593 6ed15ff79b07
child 6595 8f1681b6d822
#REFACTORING by cg class: EditTextViewCompletionSupport changed: #handleKeyPress:x:y: use isLetterOrUnderline/isLetterrDigitOrUnderline
EditTextViewCompletionSupport.st
--- a/EditTextViewCompletionSupport.st	Wed Jun 05 13:55:43 2019 +0200
+++ b/EditTextViewCompletionSupport.st	Wed Jun 05 17:09:27 2019 +0200
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "{ Package: 'stx:libwidg' }"
 
 "{ NameSpace: Smalltalk }"
@@ -88,7 +86,7 @@
     (completionView notNil and:[completionView realized]) ifFalse:[
         editView hasSelection ifFalse:[
             ((ch := editView characterBeforeCursor) notNil "/ i.e. not at begin of line
-            and:[ ch isLetterOrDigit or:[ ch == $_ ] ]) ifTrue:[
+            and:[ ch isLetterOrDigitOrUnderline ]) ifTrue:[
                 (key == #Control_L or:[ key == #Ctrl or:[ key == #Control_R or:[ key == #Control]]]) ifTrue:[
                     UserPreferences current codeCompletionOnControlKey ifTrue:[
                         autoSelect := true.
@@ -165,6 +163,7 @@
 
     "Modified: / 24-08-2017 / 21:32:52 / cg"
     "Modified: / 03-07-2018 / 13:41:45 / sr"
+    "Modified: / 05-06-2019 / 17:06:15 / Claus Gittinger"
 !
 
 postKeyPress:key