rawKeyDown cooking my brain.

Sarah Reichelt sarah.reichelt at gmail.com
Sun Nov 2 16:07:27 EST 2008


On Mon, Nov 3, 2008 at 5:53 AM, Richmond Mathewson <geradamas at yahoo.com> wrote:
> 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).
>

How about:

on rawKeyDown KDWN
   if the shiftKey is down then
     .....
   else if the commandKey is down then
     ....
   else
    .....
   end if
end rawKeyDown

Cheers,
Sarah



More information about the use-livecode mailing list