[Pharo-project] Unicode support problems
For now, some unicode symbols is impossible input from keyboard (at least, russian letters 'Ð', 'Ð', 'Ð' on Windows platform). I found some solution of this problem: in method ParagraphEditor>>dispatchOnKeyEvent:with: replace line: keyValue := keyValue ifNil: [keyEvent keyValue]. with line: keyValue := keyValue ifNil: [keyEvent keyCharacter asInteger]. Then save method and that's all. Cause of the problem: expressoin "keyEvent keyValue" return small number for all symbols, unclude unicode and give activation of shortcut events, defined in methods ParagraphEditor class>>initializeCmdKeyShortcuts, ParagraphEditor class>>initializeShiftCmdKeyShortcuts. I also notice other strange things: method KeyboardEvent>>keyCharacter sends up to 14 times for one keyboard pressing. Is this normal? Regards, Alexander Batalshikov.
Alexandr Batalshikov wrote:
For now, some unicode symbols is impossible input from keyboard (at least, russian letters 'Ð', 'Ð', 'Ð' on Windows platform). I found some solution of this problem: in method ParagraphEditor>>dispatchOnKeyEvent:with: replace line: keyValue := keyValue ifNil: [keyEvent keyValue]. with line: keyValue := keyValue ifNil: [keyEvent keyCharacter asInteger].
In general it looks like most (all?) senders of keyValue should rather use keyCharacter.
I also notice other strange things: method KeyboardEvent>>keyCharacter sends up to 14 times for one keyboard pressing. Is this normal?
I'm afraid yes, but it would still be interesting to trace who all these senders are. Key handling in Morphic is a mess, so there should be lots of room for improvement. Michael
On Tue, Nov 3, 2009 at 4:00 PM, Michael Rueger <m.rueger@acm.org> wrote:
Alexandr Batalshikov wrote:
For now, some unicode symbols is impossible input from keyboard (at least, russian letters 'Ð', 'Ð', 'Ð' on Windows platform). I found some solution of this problem: in method ParagraphEditor>>dispatchOnKeyEvent:with: replace line: keyValue := keyValue ifNil: [keyEvent keyValue]. with line: keyValue := keyValue ifNil: [keyEvent keyCharacter asInteger].
In general it looks like most (all?) senders of keyValue should rather use keyCharacter.
Apparently, yes. At least, this is not seems to be simple typo error in Unicode tables.
participants (2)
-
Alexandr Batalshikov -
Michael Rueger