earleh@dartvax.UUCP (05/15/87)
I am working on a new port of microemacs 3.8 to the Mac. This is a combination of routines from Dave Burnard's 3.7i port and my previously posted 3.8 port. I believe I have things worked out so the program is worthy of posting, except for one small detail, which some kind soul might send me a note on. By adding Dave's routines and mine together, plus some extra coding, I now have a Mac microemacs which supports scroll bars, resized windows, mouse cursor positioning, and enough Mac-like gravy to allow it to masquerade as a Macintosh application (in addition to being a serious text editor). I had occasion to test the program out at my dealer today on an SE and a Mac II. Everything worked out just fine. Thanks to a USENET article I read before, I correctly guessed at the method to detect the new control key (why didn't they put a control key on the Mac in the first place?) Now for the problem: The new Macs have a real escape key (same comment applies) and also, apparently, real cursor keys, unlike the broken ones the Mac+ comes with. This is my question: What is the recommended manner of detecting the escape key and the cursor keys on the new machines? I am not a registered Mac developer, but rather a hobbyist, and do not have the same access to information that I assume others might have. WILL SOMEONE PLEASE MAIL ME THE KEYCODES FOR THESE KEYS SO THAT I CAN POST THIS PROGRAM? I am using GetNextEvent and a keymap so that I can use the option key as a META key, so I need keycodes, not ASCII values! I do not have one of the new machines myself, and so cannot experiment to determine the correct values. By the way, there is a serious bug in display.c, at least in the version that I have. In the vtinit() routine, where space is malloced for the virtual and physical screens, only enough space is malloced for the CURRENT number of rows and columns! On a machine like the Mac, where the "terminal" size can change at any moment, this is a serious oversight. On the Mac, I can make the window twice as wide as the screen if I need to, and this results in the display routines writing to space they do not own. A fix is to change most of the occurences of "term.t_ncol" and "term.t_nrow" in vtinit() to "term.t_mcol" and "term.t_mrow". Thanks in advance. Earle Horton earleh@dartvax -- **************************************************************************** * Dot seegnachur? I don' got to show you no steenkeen dot seegnachur!! * ****************************************************************************
dgold@apple.UUCP (05/17/87)
In article <6219@dartvax.UUCP> earleh@dartvax.UUCP (Earle R. Horton) writes: >...I am not a registered Mac developer, but rather a hobbyist, >and do not have the same access to information that I assume others >might have. I'd like to state once again that you don't have to be a registered developer, or even a certified developer, in order to have complete information on programming the Macintosh. First, join the Apple Programmer's and Developer's Association (APDA). It only costs $20 a year, and you get catalogs which describe all the Mac and Apple // technical info which you can order, including Inside Mac volume V which has information on the new ADB keyboards. Second, get ahold of Macintosh Tech Notes, which can be ordered from APDA or downloaded from various online services (I don't know if they're available here on the net, but they could be if someone wanted to provide them -- there are no restrictions on copying Tech Notes). This will keep you up to date on new developments for the Mac. APDA can be reached at: Apple Programmer's and Developer's Association 290 SW 43rd Street Renton, WA 98055 (206) 251-6548 -- David Goldsmith Apple Computer, Inc. MacApp Group AppleLink: GOLDSMITH1 UUCP: {nsc,dual,sun,voder,ucbvax!mtxinu}!apple!dgold CSNET: dgold@apple.CSNET, dgold%apple@CSNET-RELAY BIX: dgoldsmith
earleh@dartvax.UUCP (Earle R. Horton) (05/17/87)
In article <779@apple.UUCP>, dgold@apple.UUCP (David Goldsmith) writes: > In article <6219@dartvax.UUCP> earleh@dartvax.UUCP (Earle R. Horton) writes: > >...I am not a registered Mac developer, but rather a hobbyist, > >and do not have the same access to information that I assume others > >might have. > > I'd like to state once again that you don't have to be a registered > developer, or even a certified developer, in order to have complete > information on programming the Macintosh. > > First, join the Apple Programmer's and Developer's Association (APDA). > It only costs $20 a year, and you get catalogs which describe all the > Mac and Apple // technical info which you can order, including Inside > Mac volume V which has information on the new ADB keyboards. > First, let me apologize to readers of comp.emacs for the cross posting. I'm sorry. Second, I don't want to join ADPA, and I really don't want to buy IM volume V. I have IM volume IV, and it's poorly written. It lacks the detail found in the Promotional Edition, which I also have. The File Manager chapter, which is supposed to be a complete rewrite, is more like a Reader's Digest Abstract of what a proper manual would be. Apple should hire some real writers, or, if they have some, they should put them to work. I mean this, it is an objective criticism, and not a flame, and should be taken as such. The keycodes for the cursor keys would not be different on the mew machines if Apple had taken the trouble to design the Mac+ keyboard properly in the first place. When the shift key is held down, it is IMPOSSIBLE to determine whether a cursor key or a key on the numeric keypad is being pressed. This is not acceptable, since the same problem also affects the caps lock key, making it next to impossible to type in an ANSI 77 FORTRAN program with a terminal emulator (remember, no lower case?) and move the cursor around at the same time. Morally, Apple owes everyone who purchased a Mac+ or the separate keyboard a new, properly designed, keyboard. Since I do not expect a new keyboard to arrive at any time in the near future, I would settle for someone who has this information at least telling me what the new keycodes are. If I had an SE myself, I could determine in about 15 minutes what the keycodes are. I do not, and I cannot justify spending hard-earned funds to buy poorly-written documentation that describes a piece of hardware which I do not have. So, again, will someone who knows please send me the keycode for the escape key and the four cursor keys on the new keyboard, as returned in the event message by GetNextEvent? In view of the shoddy treatment I have received regarding the purchase of this damaged keyboard, it is the least you could do. Thank you. Earle Horton -- **************************************************************************** * Dot seegnachur? I don' got to show you no steenkeen dot seegnachur!! * ****************************************************************************