Path: utzoo!dptcdc!jarvis.csri.toronto.edu!mailrus!wasatch!cs.utexas.edu!uunet!gwusun!gwusun.gwu.edu!raju From: raju@gwusun.gwu.edu (D. Murali Raju) Newsgroups: comp.mail.elm Subject: Emacs motion keys for Elm 2.2 (^P and ^N) Keywords: emacs cursor motion thanks Message-ID: <1350@gwusun.gwu.edu> Date: 17 Apr 89 16:24:10 GMT Sender: raju@gwusun.gwu.edu Reply-To: raju@gwusun.gwu.edu (D. Murali Raju) Organization: The George Washington University, Washington, D.C. Lines: 61 Greetings! Fellow Elmers! I just installed the new Elm 2.2 release. Works real nice so far. Many heartfelt thanks to the Elm development group and the original author for making this great software available. My co-worker John Kelso and I are both GNU emacs users, and had a small patch to add ^P and ^N commands to scroll up and down the messages. These commands work like the J and K (capitals) commands. It is a relatively benign patch (2 extra lines in one file). So, for all those Gnumacs lovers out there, the patch is at the end if this message. I don't know if there is any demand out there for putting it on the wish list for Elm 2.3, but count 2 votes over here. If there is enough demand, I have no idea how this would integrate with the other features. (One way would be translate the environment variable EDITOR used by many other unix programs and provide the same sort of cursor movement, depending on whether it's a vi or emacs like editor. Another way to figure this out would be to look at the "editor" variable in .elm/elmrc) For now, there is no conflict with any other elm commands, and the ^N and ^P keys integrate very simply and nicely. I don't know the official patch policy, so if I made a boo-boo by posting this here, please let me know by mail. In any case, count this as a "convenience" patch, not as anything even remotely "official!" Once again, our thanks to the Elm development group! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ D. Murali Raju (raju@gwusun.gwu.edu || ..!uunet!gwusun!raju || 202-994-6853) System Programmer (SEAS-CF), GWU, 725 23rd Street N.W., Washington, DC 20052 #include ... keeping my fingers in the pies ... ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Here's the patch: *** src/elm.c.orig Thu Apr 13 08:56:22 1989 --- src/elm.c Mon Apr 17 10:56:02 1989 *************** *** 355,360 **** --- 355,361 ---- } else error("No mail to read!"); break; + case ctrl('N'): case 'J' : if(current > 0) { if((i=next_message(current-1, FALSE)) != -1) { current = i+1; *************** *** 378,383 **** --- 379,385 ---- } else error("No mail in folder!"); break; + case ctrl('P'): case 'K' : if(current > 0) { if((i=prev_message(current-1, FALSE)) != -1) { current = i+1;