rawKeyDown cooking my brain.
Richmond Mathewson
geradamas at yahoo.com
Sun Nov 2 14:53:02 EST 2008
Was just mucking around with a stack called "KEY NAMER" which I uploaded to
revOnline a couple of years ago. It is a crude little stack that has this
script in its single card:
on rawkeydown KDWN
put KDWN into fld "KNAME"
end rawkeydown
and, when you press a key down, surprise, surprise, you get a jolly numeric
output in field "KNAME": not rocket science, but useful nevertheless.
BUT . . .
On my Macintosh, at least, this stack does not do its stuff when I press
any of the modifier keys (Ctrl, Alt, Command).
Therefore when I, for instance, press Command-A, the numeric output is
exactly the same as pressing the A key by itself.
This is not good, as the likes of myself and Marcus Lindley might find it
useful to simulate Command/Ctrl-A, or other combinations which do not respond to rawKeyDown.
Now, I am aware there are:
controlKeyDown
commandKeyDown
messages
and
shiftKey
altKey
functions
[why no 'altKeyDown' and 'shiftKeyDown' ???]
so, I suppose, one would have to trap both command/controlKey and rawKeyDown simultaneously to fake command/control-A . . .
Err, I think I have just answered my own question; what a monkey!
sincerely, Richmond Mathewson.
____________________________________________________________
A Thorn in the flesh is better than a failed Systems Development Life Cycle.
____________________________________________________________
More information about the use-livecode
mailing list