Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!usc!brutus.cs.uiuc.edu!apple!tecot From: tecot@Apple.COM (Ed Tecot) Newsgroups: comp.sys.mac.programmer Subject: Re: page up and friends Message-ID: <38830@apple.Apple.COM> Date: 21 Feb 90 08:44:18 GMT References: <1990Feb6.205957.27722@ux1.cso.uiuc.edu> <1990Feb9.163118.5726@intercon.com> Organization: Apple Computer Inc, Cupertino, CA Lines: 22 In article <1990Feb9.163118.5726@intercon.com> amanda@mermaid.intercon.com (Amanda Walker) writes: >In article <1990Feb6.205957.27722@ux1.cso.uiuc.edu>, dorner@pequod.cso.uiuc.edu >(Steve Dorner) writes: >> It would be nice to hear that there are magic character codes for these keys, > >What you have to do is look at the "keyCode" part of the event message >instead of the "charCode" part. The function & editing cluster keys >don't have unique ASCII codes, but they do have unique (and standardized) >virtual key codes. IM V has a chart of (for example) the ADB Extended >keyboard that shows all of the virtual key codes for the function keys >etc. Actually, this is half right... The function keys all share the same charCode, but the six keys above the arrows all have their own "magic" charCodes. They were chosen to make sense in the ASCII realm of things (delete is $7F). I'm actually surprised to see that it is not documented in Inside Macintosh, but the codes can be determined empirically (they won't change). Of course, some of these charCodes can also be generated with the control key pressed, so using the virtual key codes might not be so bad after all. _emt