1058 Transcript show:'seq ->' ; showCR:seq storeString. |
1056 Transcript show:'seq ->' ; showCR:seq storeString. |
1059 ]. |
1057 ]. |
1060 self send:(seq withoutCEscapes). |
1058 self send:(seq withoutCEscapes). |
1061 ^ self |
1059 ^ self |
1062 ]. |
1060 ]. |
1063 |
1061 rawKey notNil ifTrue:[ |
1064 (rawKey startsWith:'Ctrl') ifTrue:[ |
1062 (rawKey startsWith:'Ctrl') ifTrue:[ |
1065 rest := rawKey copyFrom:5. |
1063 rest := rawKey copyFrom:5. |
1066 rest size == 1 ifTrue:[ |
1064 rest size == 1 ifTrue:[ |
1067 rest := rest at:1. |
1065 rest := rest at:1. |
1068 (rest asLowercase between:$a and:$z) ifTrue:[ |
1066 (rest asLowercase between:$a and:$z) ifTrue:[ |
1069 DebugKeyboard ifTrue:[ |
1067 DebugKeyboard ifTrue:[ |
1070 Transcript show:'ctrl ->' ; showCR:(Character controlCharacter:rest) storeString. |
1068 Transcript show:'ctrl ->' ; showCR:(Character controlCharacter:rest) storeString. |
|
1069 ]. |
|
1070 (signalControlKeys and:[rawKey == #Ctrlc]) ifTrue:[ |
|
1071 self doSendInterrupt. |
|
1072 ^ self. |
|
1073 ]. |
|
1074 self sendCharacter:(Character controlCharacter:rest). |
|
1075 ^ self |
1071 ]. |
1076 ]. |
1072 (signalControlKeys and:[rawKey == #Ctrlc]) ifTrue:[ |
1077 ] |
1073 self doSendInterrupt. |
1078 ]. |
1074 ^ self. |
1079 |
1075 ]. |
1080 ((rawKey startsWith:'Control') |
1076 self sendCharacter:(Character controlCharacter:rest). |
1081 or:[ (rawKey startsWith:'Shift') |
1077 ^ self |
1082 or:[ (rawKey startsWith:'Alt') |
|
1083 or:[ (rawKey = 'Ctrl') |
|
1084 ]]]) ifTrue:[ |
|
1085 DebugKeyboard ifTrue:[ |
|
1086 Transcript showCR:'modifier ignored'. |
1078 ]. |
1087 ]. |
1079 ] |
1088 ^ self |
1080 ]. |
1089 ]. |
1081 |
1090 (rawKey startsWith:'Cmd') ifTrue:[ |
1082 ((rawKey startsWith:'Control') |
1091 DebugKeyboard ifTrue:[ |
1083 or:[ (rawKey startsWith:'Shift') |
1092 Transcript showCR:'CMD handled internal'. |
1084 or:[ (rawKey startsWith:'Alt') |
1093 ]. |
1085 or:[ (rawKey = 'Ctrl') |
1094 ^ super keyPress:aKey x:x y:y |
1086 ]]]) ifTrue:[ |
1095 ]. |
1087 DebugKeyboard ifTrue:[ |
1096 ]. |
1088 Transcript showCR:'modifier ignored'. |
1097 |
1089 ]. |
|
1090 ^ self |
|
1091 ]. |
|
1092 (rawKey startsWith:'Cmd') ifTrue:[ |
|
1093 DebugKeyboard ifTrue:[ |
|
1094 Transcript showCR:'CMD handled internal'. |
|
1095 ]. |
|
1096 ^ super keyPress:aKey x:x y:y |
|
1097 ]. |
|
1098 |
|
1099 DebugKeyboard ifTrue:[ |
1098 DebugKeyboard ifTrue:[ |
1100 Transcript show:'unhandled: '; showCR:rawKey. |
1099 Transcript showCR:'unhandled: %1' with:(rawKey ? aKey). |
1101 ]. |
1100 ]. |
1102 |
1101 |
1103 " |
1102 " |
1104 DebugKeyboard := true |
1103 DebugKeyboard := true |
1105 " |
1104 " |
1106 |
1105 |
1107 "Modified: / 25-01-2012 / 10:43:06 / cg" |
1106 "Modified: / 25-01-2012 / 10:43:06 / cg" |
1108 "Modified: / 09-08-2018 / 10:32:07 / Claus Gittinger" |
1107 "Modified: / 26-04-2019 / 09:55:40 / Claus Gittinger" |
1109 ! |
1108 ! |
1110 |
1109 |
1111 keyPressInLineEditMode:aKey |
1110 keyPressInLineEditMode:aKey |
1112 "readline alike line editing. |
1111 "readline alike line editing. |
1113 cursorUp/down select a previous line from the history (unix shell bahevior). |
1112 cursorUp/down select a previous line from the history (unix shell bahevior). |