Re: looking for Unicode testers

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Michael Rueger-6
Igor Stasenko wrote:

> what is not very convenient is that copy/paste (as well as the rest of
> keyboard shortcuts ) is not working when keyboard layout not english.

If you could be so kind to tell me what comes back in slot 3 of the
input event on your Russian keyboard if you simply type the equivalent
of 'xcv' (without alt or ctrl)?

I'm interested in what comes back on the keyDown and the keystroke event.

Thanks

Michael

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Igor Stasenko
2009/2/24 Michael Rueger <[hidden email]>:

> Igor Stasenko wrote:
>
>> what is not very convenient is that copy/paste (as well as the rest of
>> keyboard shortcuts ) is not working when keyboard layout not english.
>
> If you could be so kind to tell me what comes back in slot 3 of the
> input event on your Russian keyboard if you simply type the equivalent
> of 'xcv' (without alt or ctrl)?
>
> I'm interested in what comes back on the keyDown and the keystroke event.
>

I tried something like this

[ | event |
  event := Sensor peekEvent.
  event ifNotNil: [
       ((event first = 2) and: [event fourth = 1] ) ifTrue: [
        Transcript show: (event third printStringRadix: 16); cr.
        ] ] ] repeat

but it not shows anything :(
Have a snippet which i can run to show key codes?



> Thanks
>
> Michael
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>



--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Adrian Lienhard
Sensor kbdTest

HTH,
Adrian

On Feb 24, 2009, at 09:48 , Igor Stasenko wrote:

> 2009/2/24 Michael Rueger <[hidden email]>:
>> Igor Stasenko wrote:
>>
>>> what is not very convenient is that copy/paste (as well as the  
>>> rest of
>>> keyboard shortcuts ) is not working when keyboard layout not  
>>> english.
>>
>> If you could be so kind to tell me what comes back in slot 3 of the
>> input event on your Russian keyboard if you simply type the  
>> equivalent
>> of 'xcv' (without alt or ctrl)?
>>
>> I'm interested in what comes back on the keyDown and the keystroke  
>> event.
>>
>
> I tried something like this
>
> [ | event |
>  event := Sensor peekEvent.
>  event ifNotNil: [
>       ((event first = 2) and: [event fourth = 1] ) ifTrue: [
> Transcript show: (event third printStringRadix: 16); cr.
> ] ] ] repeat
>
> but it not shows anything :(
> Have a snippet which i can run to show key codes?
>
>
>
>> Thanks
>>
>> Michael
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
>
>
> --
> Best regards,
> Igor Stasenko AKA sig.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Igor Stasenko
2009/2/24 Adrian Lienhard <[hidden email]>:
> Sensor kbdTest
>
"There is no implementors of kbdTest"

:(

What image might contain this method?

> HTH,
> Adrian
>
> On Feb 24, 2009, at 09:48 , Igor Stasenko wrote:
>
>> 2009/2/24 Michael Rueger <[hidden email]>:
>>> Igor Stasenko wrote:
>>>
>>>> what is not very convenient is that copy/paste (as well as the
>>>> rest of
>>>> keyboard shortcuts ) is not working when keyboard layout not
>>>> english.
>>>
>>> If you could be so kind to tell me what comes back in slot 3 of the
>>> input event on your Russian keyboard if you simply type the
>>> equivalent
>>> of 'xcv' (without alt or ctrl)?
>>>
>>> I'm interested in what comes back on the keyDown and the keystroke
>>> event.
>>>
>>
>> I tried something like this
>>
>> [ | event |
>>  event := Sensor peekEvent.
>>  event ifNotNil: [
>>       ((event first = 2) and: [event fourth = 1] ) ifTrue: [
>>       Transcript show: (event third printStringRadix: 16); cr.
>>       ] ] ] repeat
>>
>> but it not shows anything :(
>> Have a snippet which i can run to show key codes?
>>
>>
>>
>>> Thanks
>>>
>>> Michael
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>>
>>
>>
>> --
>> Best regards,
>> Igor Stasenko AKA sig.
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>



--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Adrian Lienhard
I'm looking at a Pharo core #10241 image.

Adrian

On Feb 24, 2009, at 10:48 , Igor Stasenko wrote:

> 2009/2/24 Adrian Lienhard <[hidden email]>:
>> Sensor kbdTest
>>
> "There is no implementors of kbdTest"
>
> :(
>
> What image might contain this method?
>
>> HTH,
>> Adrian
>>
>> On Feb 24, 2009, at 09:48 , Igor Stasenko wrote:
>>
>>> 2009/2/24 Michael Rueger <[hidden email]>:
>>>> Igor Stasenko wrote:
>>>>
>>>>> what is not very convenient is that copy/paste (as well as the
>>>>> rest of
>>>>> keyboard shortcuts ) is not working when keyboard layout not
>>>>> english.
>>>>
>>>> If you could be so kind to tell me what comes back in slot 3 of the
>>>> input event on your Russian keyboard if you simply type the
>>>> equivalent
>>>> of 'xcv' (without alt or ctrl)?
>>>>
>>>> I'm interested in what comes back on the keyDown and the keystroke
>>>> event.
>>>>
>>>
>>> I tried something like this
>>>
>>> [ | event |
>>>  event := Sensor peekEvent.
>>>  event ifNotNil: [
>>>       ((event first = 2) and: [event fourth = 1] ) ifTrue: [
>>>       Transcript show: (event third printStringRadix: 16); cr.
>>>       ] ] ] repeat
>>>
>>> but it not shows anything :(
>>> Have a snippet which i can run to show key codes?
>>>
>>>
>>>
>>>> Thanks
>>>>
>>>> Michael
>>>>
>>>> _______________________________________________
>>>> Pharo-project mailing list
>>>> [hidden email]
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>>
>>>
>>>
>>> --
>>> Best regards,
>>> Igor Stasenko AKA sig.
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
>
>
> --
> Best regards,
> Igor Stasenko AKA sig.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Igor Stasenko
okay
Here what prints #kbdTest

c - '99 0'
z - '122 0'
x - '120 0'

in russian layout

я (z key) -  '79 0'
ч (x key) -  '71 0'
с (c key) - '65 0'

Now i wrote own test method:

testKbd
        "This test routine will print the unmodified character, its keycode,
        and the OR of all its modifier bits, until the character x is typed"
        | char event |
        char := nil.
        [true] whileTrue: [
                event := self peekEvent.
                (event notNil and: [ (event at: 1) = EventTypeKeyboard  and: [
(event at: 4) = EventKeyDown] ]) ifTrue: [
                        (String streamContents: [:s |
                                        event do: [:each | s nextPutAll: each printString; space].
                                s nextPutAll: '     ']) displayAt: 10@10
                ].
         (Delay forMilliseconds: 10) wait.
        ]
----
And it works if you do:

[Sensor testKbd] fork

And! Wonderfull!
Regardless of active keyboard layout (en/ru)
it always prints same events for these keys, as following:

z - 2 <timestamp> 90 1 0 90 0 1
x - 2 <timestamp> 88 1 0 88 0 1
c - 2 <timestamp> 67 1 0 67 0 1

so, if we use these events for shortcuts, everything will work similar
regardless of keys layout.


2009/2/24 Adrian Lienhard <[hidden email]>:

> I'm looking at a Pharo core #10241 image.
>
> Adrian
>
> On Feb 24, 2009, at 10:48 , Igor Stasenko wrote:
>
>> 2009/2/24 Adrian Lienhard <[hidden email]>:
>>> Sensor kbdTest
>>>
>> "There is no implementors of kbdTest"
>>
>> :(
>>
>> What image might contain this method?
>>
>>> HTH,
>>> Adrian
>>>
>>> On Feb 24, 2009, at 09:48 , Igor Stasenko wrote:
>>>
>>>> 2009/2/24 Michael Rueger <[hidden email]>:
>>>>> Igor Stasenko wrote:
>>>>>
>>>>>> what is not very convenient is that copy/paste (as well as the
>>>>>> rest of
>>>>>> keyboard shortcuts ) is not working when keyboard layout not
>>>>>> english.
>>>>>
>>>>> If you could be so kind to tell me what comes back in slot 3 of the
>>>>> input event on your Russian keyboard if you simply type the
>>>>> equivalent
>>>>> of 'xcv' (without alt or ctrl)?
>>>>>
>>>>> I'm interested in what comes back on the keyDown and the keystroke
>>>>> event.
>>>>>
>>>>
>>>> I tried something like this
>>>>
>>>> [ | event |
>>>>  event := Sensor peekEvent.
>>>>  event ifNotNil: [
>>>>       ((event first = 2) and: [event fourth = 1] ) ifTrue: [
>>>>       Transcript show: (event third printStringRadix: 16); cr.
>>>>       ] ] ] repeat
>>>>
>>>> but it not shows anything :(
>>>> Have a snippet which i can run to show key codes?
>>>>
>>>>
>>>>
>>>>> Thanks
>>>>>
>>>>> Michael
>>>>>
>>>>> _______________________________________________
>>>>> Pharo-project mailing list
>>>>> [hidden email]
>>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Best regards,
>>>> Igor Stasenko AKA sig.
>>>>
>>>> _______________________________________________
>>>> Pharo-project mailing list
>>>> [hidden email]
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>>
>>
>>
>> --
>> Best regards,
>> Igor Stasenko AKA sig.
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>



--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Michael Rueger-6
Igor Stasenko wrote:

> Regardless of active keyboard layout (en/ru)
> it always prints same events for these keys, as following:
>
> z - 2 <timestamp> 90 1 0 90 0 1
> x - 2 <timestamp> 88 1 0 88 0 1
> c - 2 <timestamp> 67 1 0 67 0 1
>
> so, if we use these events for shortcuts, everything will work similar
> regardless of keys layout.

Great, thanks!

For which shortcuts does that usually work?
cut x
copy c
paste v
undo z
open o
print p
all a
save s

anything else?

Michael

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: looking for Unicode testers

Igor Stasenko
2009/2/26 Michael Rueger <[hidden email]>:

> Igor Stasenko wrote:
>
>> Regardless of active keyboard layout (en/ru)
>> it always prints same events for these keys, as following:
>>
>> z - 2 <timestamp> 90 1 0 90 0 1
>> x - 2 <timestamp> 88 1 0 88 0 1
>> c - 2 <timestamp> 67 1 0 67 0 1
>>
>> so, if we use these events for shortcuts, everything will work similar
>> regardless of keys layout.
>
> Great, thanks!
>
> For which shortcuts does that usually work?
> cut x
> copy c
> paste v
> undo z
> open o
> print p
> all a
> save s
>
> anything else?
>
browse-it, senders-of-it, implementors-of-it, references-of-it ,
do-it, inspect-it

> Michael
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>



--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project