|
|
1.1 ! root 1: GNU Emacs FAQ: Introduction ! 2: ! 3: [To find what has changed, see the "diff" posting.] ! 4: ! 5: [Joe Wells plans to quit soon as FAQ coordinator. Steven Byrnes says he can ! 6: take over this portion of the FAQ responsibility. We still need more ! 7: volunteers to help by taking charge of a section of the FAQ list. Send e-mail ! 8: if you are interested.] ! 9: ! 10: This is the introduction to a list of frequently asked questions (FAQ) about ! 11: GNU Emacs with answers. This article contains a listing of the questions; ! 12: subsequent articles contain the questions and answers. ! 13: ! 14: The FAQ list is posted to reduce the noise level in the `gnu.emacs.help' ! 15: newsgroup (which is also the `help-gnu-emacs' mailing list) which results from ! 16: the repetition of frequently asked questions, wrong answers to these questions, ! 17: corrections to the wrong answers, corrections to the corrections, debate, name ! 18: calling, etc. Also, it serves as a repository of the canonical "best" answers ! 19: to these questions. However, if you know a better answer or even a slight ! 20: change that improves an answer, please tell us! ! 21: ! 22: If you know the answer of a question is in the FAQ list, please reply to the ! 23: question by e-mail instead of posting. Help reduce noise! ! 24: ! 25: The FAQ list is crossposted to `comp.emacs' because some sites do not receive ! 26: the `gnu.*' newsgroups. The FAQ list is also crossposted to `news.answers'. ! 27: ! 28: Please suggest new questions, answers, wording changes, deletions, etc. The ! 29: most helpful form for suggestions is a context diff (ie., the output of `diff ! 30: -c'). Include `FAQ' in the subject of messages sent to us about the FAQ list. ! 31: ! 32: Please do not send questions to us just because you do not want to disturb a ! 33: lot of people and you think we would know the answer. We do not have time to ! 34: answer questions individually. :-( ! 35: ! 36: Full instructions for getting the latest FAQ are in question 22. Also see the ! 37: `Introduction to news.answers' posting in the `news.answers' newsgroup, or send ! 38: e-mail to `[email protected]' with `help' on a body line, or use FTP, ! 39: WAIS, or Prospero to rtfm.mit.edu. ! 40: ! 41: These ideas have already been suggested, but we have not had time to ! 42: implement them: ! 43: ! 44: * A Texinfo version. ! 45: * Marking questions in the table of contents that have been changed ! 46: recently. ! 47: ! 48: -- ! 49: Joe Wells <[email protected]> and Steven Byrnes <[email protected]> ! 50: ! 51: E-mail [email protected] for details about the League for Programming Freedom. ! 52: ! 53: ---------------------------------------------------------------------- ! 54: ! 55: GNU Emacs FAQ: Table of Contents ! 56: ! 57: Notation Used in FAQ ! 58: ! 59: 1: What do these mean: C-h, M-C-a, RET, "ESC a", etc.? ! 60: 2: What does "M-x command" mean? ! 61: 3: How do I read topic XXX in the on-line manual? ! 62: 4: What do these mean: etc/SERVICE, src/config.h, lisp/default.el? ! 63: 5: What are FSF, LPF, OSF, GNU, RMS, FTP, and GPL? ! 64: ! 65: General Questions ! 66: ! 67: 6: What is the LPF and why should I join it? ! 68: 7: What is the real legal meaning of the GNU copyleft? ! 69: 8: What are appropriate messages for gnu.emacs.help, gnu.emacs.bug, ! 70: comp.emacs, etc.? ! 71: 9: Where can I get old postings to gnu.emacs.help and other GNU groups? ! 72: 10: Where should I report bugs and other problems with GNU Emacs? ! 73: 11: How do I unsubscribe to this mailing list? ! 74: 12: What is the current address of the FSF? ! 75: ! 76: On-line Help, Printed Manuals, Other Sources of Help ! 77: ! 78: 13: I'm just starting GNU Emacs; how do I do basic editing? ! 79: 14: How do I find out how to do something in GNU Emacs? ! 80: 15: How do I get a printed copy of the GNU Emacs manual? ! 81: 16: Where can I get documentation on GNU Emacs Lisp? ! 82: 17: How do I install a piece of Texinfo documentation? ! 83: 18: How do I print a Texinfo file? ! 84: 19: Can I view Info files without using GNU Emacs? ! 85: 20: What informational files are available for GNU Emacs? ! 86: 21: Where can I get help in installing GNU Emacs? ! 87: 22: Where can I get the latest version of this document (the FAQ list)? ! 88: ! 89: Status of Emacs ! 90: ! 91: 23: Where does the name "Emacs" come from? ! 92: 24: What is the latest version of GNU Emacs? ! 93: 25: When will GNU Emacs 19 be available? ! 94: 26: What is different about GNU Emacs 19? ! 95: 27: What variants of GNU Emacs exist? ! 96: ! 97: Common Things People Want To Do ! 98: ! 99: 28: How do I set up a .emacs file properly? ! 100: 29: How do I debug a .emacs file? ! 101: 30: How do I make Emacs display the current line (or column) number? ! 102: 31: How do I turn on Abbrevs by default just in mode XXX? ! 103: 32: How do I turn on Auto-Fill mode by default? ! 104: 33: How do I make Emacs use a certain major mode for certain files? ! 105: 34: How do I search for, delete, or replace unprintable (8-bit or control) ! 106: characters? ! 107: 35: How can I highlight a region of text in Emacs? ! 108: 36: How do I control Emacs's case-sensitivity when searching/replacing? ! 109: 37: How do I make Emacs wrap words for me? ! 110: 38: Where can I get a better spelling checker for Emacs? ! 111: 39: How can I spell-check TeX or *roff documents? ! 112: 40: How do I change load-path? ! 113: 41: How do I use an already running Emacs from another window? ! 114: 42: How do I make Emacs recognize my compiler's funny error messages? ! 115: 43: How do I indent switch statements like this? ! 116: 44: How can I make Emacs automatically scroll horizontally? ! 117: 45: How do I make Emacs "typeover" or "overwrite" instead of inserting? ! 118: 46: How do I stop Emacs from beeping on a terminal? ! 119: 47: How do I turn down the bell volume in Emacs running under X Windows? ! 120: 48: How do I tell Emacs to automatically indent a new line to the ! 121: indentation of the previous line? ! 122: 49: How do I show which parenthesis matches the one I'm looking at? ! 123: 50: In C mode, can I show just the lines that will be left after #ifdef ! 124: commands are handled by the compiler? ! 125: 51: Is there an equivalent to the `.' (dot) command of vi? ! 126: 52: What are the valid X resource settings (ie., stuff in .Xdefaults)? ! 127: 53: How do I execute a piece of Emacs Lisp code? ! 128: 54: How do I change Emacs's idea of the tab character's length? ! 129: 55: How do I insert `>' at the beginning of every line? ! 130: 56: How do I insert `_^H' before each character in a paragraph to get an ! 131: underlined paragraph? ! 132: 57: How do I repeat a command as many times as possible? ! 133: 58: How do I make Emacs behave like this: when I go up or down, the cursor ! 134: should stay in the same column even if the line is too short? ! 135: 59: How do I tell Emacs to iconify itself? ! 136: 60: How do I use regexps (regular expressions) in Emacs? ! 137: 61: How do I perform a replace operation across more than one file? ! 138: 62: Where is the documentation for `etags'? ! 139: ! 140: Bugs/Problems ! 141: ! 142: 63: Does Emacs have problems with files larger than 8 megabytes? ! 143: 64: Why can't Emacs find files in current directory on startup? ! 144: 65: How do I get rid of the ^M junk in my Shell buffer? ! 145: 66: Why do I get `Process shell exited abnormally with code 1'? ! 146: 67: Why can't I cut from Emacs and paste in other X programs? ! 147: 68: Where is the termcap/terminfo entry for terminal type `emacs'? ! 148: 69: Why does Emacs spontaneously start displaying `I-search:' and beeping? ! 149: 70: Why can't Emacs talk to certain hosts (or certain hostnames)? ! 150: 71: Why does Emacs say `Error in init file'? ! 151: 72: Why does Emacs ignore my X resources (my .Xdefaults file)? ! 152: 73: Why does Emacs take 20 seconds to visit a file? ! 153: 74: How do I edit a file with a `$' in its name? ! 154: 75: Why does Shell mode lose track of the shell's current directory? ! 155: 76: Why doesn't my change to load-path work? ! 156: 77: Why does the cursor always go to the wrong column when I move up or ! 157: down one line? ! 158: 78: Why does Emacs hang with message `Unknown XMenu error' with X11R4? ! 159: 79: Why doesn't display-time show the load average in the mode line ! 160: anymore? ! 161: 80: Why does ispell sometimes ignore the local dictionary? ! 162: 81: Why does Ispell treat each line as a single word? ! 163: 82: Are there any security risks in GNU Emacs? ! 164: ! 165: Difficulties Building/Installing/Porting Emacs ! 166: ! 167: 83: What should I do if I have trouble building Emacs? ! 168: 84: How do I stop Emacs from failing when the executable is stripped? ! 169: 85: Why does linking Emacs with -lX11 fail? ! 170: 86: Why does Emacs 18.55 say `Fatal error (6).Abort' under SunOS 4.1? ! 171: ! 172: Finding/Getting Emacs and Related Packages ! 173: ! 174: 87: Where can I get GNU Emacs on the net (or by snail mail)? ! 175: 88: How do I find a GNU Emacs Lisp package that does XXX? ! 176: 89: Where can I get GNU Emacs Lisp packages that don't come with Emacs? ! 177: 90: How do I submit code to the Emacs Lisp Archive? ! 178: 91: Where can I get other up-to-date GNU stuff? ! 179: 92: Where can I get an Emacs with better mouse and X window support? ! 180: 93: What is the difference between GNU Emacs and Epoch? ! 181: 94: What is the difference between GNU Emacs and Lucid GNU Emacs? ! 182: 95: Where can I get the "unofficial HP GNU Emacs"? ! 183: 96: Where can I get Emacs for my PC running MS-DOS? ! 184: 97: Where can I get Emacs for my PC running Windows? ! 185: 98: Where can I get Emacs for my PC running OS/2? ! 186: 99: Where can I get Emacs for my Atari ST? ! 187: 100: Where can I get Emacs for my Amiga? ! 188: 101: Where can I get Emacs for my Apple computer? ! 189: 102: Where can I get Emacs with NeWS support? ! 190: 103: Where do I get Emacs that runs on VMS under DECwindows? ! 191: 104: Where can I get modes for Lex, Yacc/Bison, Bourne Shell, Csh, C++, ! 192: Objective C, Pascal, Awk? ! 193: 105: What is the IP address of XXX.YYY.ZZZ? ! 194: ! 195: Major Emacs Lisp Packages, Emacs Extensions, and Related Programs ! 196: ! 197: 106: VM (View Mail) -- another mail reader within Emacs ! 198: 107: Supercite -- mail and news citation package within Emacs ! 199: 108: GNUS -- news reader within Emacs ! 200: 109: Calc -- poor man's Mathematica within Emacs ! 201: 110: Calendar/Diary -- calendar manager within Emacs ! 202: 111: Ange-FTP -- transparent FTP access for Emacs's file access routines ! 203: 112: VIP -- vi emulation for Emacs ! 204: 113: Dired -- better directory editor for Emacs ! 205: 114: AUC TeX -- enhanced LaTeX mode with debugging facilities ! 206: 115: Hyperbole -- extensible hypertext management system within Emacs ! 207: 116: Byte Compiler -- enhanced version of Emacs's byte compiler ! 208: 117: comint -- hugely enhanced shell mode and other derived modes ! 209: 118: BBDB -- personal info rolodex integrated with mail/news readers ! 210: 119: Ispell -- spell checker in C with interface for Emacs ! 211: 120: Epoch -- enhanced GNU Emacs with better X interface ! 212: 121: Lucid GNU Emacs -- alternative Emacs 19 with better X interface ! 213: 122: Demacs -- GNU Emacs altered to run on MS-DOS on 386/486 machines ! 214: 123: Freemacs -- a small Emacs for MS-DOS ! 215: 124: Patch -- program to apply "diffs" for updating files ! 216: ! 217: Changing Key Bindings and Handling Key Binding Problems ! 218: ! 219: 125: How do I bind keys (including function keys) to commands? ! 220: 126: Why does Emacs say `Key sequence XXX uses invalid prefix characters'? ! 221: 127: Why doesn't this [terminal or window-system setup] code work in my ! 222: .emacs file, but it works just fine after Emacs starts up? ! 223: 128: How do I use function keys under X Windows? ! 224: 129: How do I tell what characters my function or arrow keys emit? ! 225: 130: How do I set the X key "translations" for Emacs? ! 226: 131: How do I handle C-s and C-q being used for flow control? ! 227: 132: How do I use commands bound to C-s and C-q (or any key) if these keys ! 228: are filtered out? ! 229: 133: Why does the `BackSpace' key invoke help? ! 230: 134: Why doesn't Emacs look at the stty settings for Backspace vs. Delete? ! 231: 135: Why don't the arrow keys work? ! 232: 136: How do I "swap" two keys? ! 233: 137: How do I produce C-XXX with my keyboard? ! 234: 138: What if I don't have a Meta key? ! 235: 139: What if I don't have an Escape key? ! 236: 140: How do I type DEL on PC terminal emulators? ! 237: 141: Can I make my `Compose Character' key behave like a Meta key? ! 238: 142: How do I bind a combination of modifier key and function key? ! 239: 143: Why doesn't my Meta key work in an xterm window? ! 240: 144: Why doesn't my ExtendChar key work as a Meta key under HP-UX 8.0? ! 241: 145: Where can I get key bindings to make Emacs emulate WordStar? ! 242: 146: Where can I get an XEDIT emulator for Emacs? ! 243: ! 244: Using Emacs with Alternate Character Sets ! 245: ! 246: 147: How do I make Emacs display 8-bit characters? ! 247: 148: How do I input 8-bit characters? ! 248: 149: Where can I get an Emacs that can handle kanji characters? ! 249: 150: Where can I get an Emacs that can handle Chinese? ! 250: 151: Where is an Emacs that can handle Semitic (right-to-left) alphabets? ! 251: ! 252: Mail and News ! 253: ! 254: 152: How do I change the included text prefix in mail/news followups? ! 255: 153: How do I save a copy of outgoing mail? ! 256: 154: Why doesn't Emacs expand my aliases when sending mail? ! 257: 155: Why does RMAIL think all my saved messages are one big message? ! 258: 156: How can I sort the messages in my RMAIL folder? ! 259: 157: Why does RMAIL need to write to /usr/spool/mail? ! 260: 158: How do I recover my mail files after RMAIL munges their format? ! 261: 159: How do I make Emacs automatically start my mail/news reader? ! 262: 160: How do I read news under Emacs? ! 263: 161: Why does `rnews' say "No News is good news" when there is news? ! 264: 162: Why doesn't GNUS work anymore via NNTP? ! 265: 163: How do I view text with embedded underlining (eg., ClariNews)? ! 266: 164: When I try to post a long article in GNUS (about 10K or longer), I get ! 267: the error, "Writing to process: no more processes, nntpd" ! 268: 165: How do I save all the items of a multi-part posting in GNUS? ! 269: 166: Why does GNUS put the subjects in replies beyond the 80th column? ! 270: 167: Why is GNUS so slow to start up? ! 271: 168: How do I catch up all newsgroups in GNUS? ! 272: 169: Why can't I kill in GNUS on the Newsgroups/Keywords/Control line? ! 273: 170: How do I get rid of flashing messages in GNUS for slow connections? ! 274: 171: Why is catch up slow in Gnews/GNUS? ! 275: 172: Why does GNUS hang for a long time when posting? ! 276: 173: Why don't my news postings in GNUS get past the local machine? ! 277: 174: Why is the GNUS-generated `Date:' header invalid? ! 278: 175: Why doesn't GNUS generate the `Lines:' header? ! 279: 176: Why do I get "Cannot open load file" "nntp" when compiling GNUS? ! 280: 177: How do I kill all articles in GNUS but those matching a pattern? ! 281: ! 282: GNU Emacs FAQ: Notation/General/Help/Status ! 283: ! 284: If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to ! 285: get an overview of just the questions. Then, when you want to look at the text ! 286: of the answers, just type "C-x $". ! 287: ! 288: To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if ! 289: that doesn't work, then type ESC to end the search. ! 290: ! 291: A `+' in the 78th column means something was inserted on the line. A `-' means ! 292: something was deleted and a `!' means some combination of insertions and ! 293: deletions occurred. ! 294: ! 295: Full instructions for getting the latest FAQ are in question 22. Also see the ! 296: `Introduction to news.answers' posting in the `news.answers' newsgroup, or send ! 297: e-mail to `[email protected]' with `help' on a body line, or use FTP, ! 298: WAIS, or Prospero to rtfm.mit.edu. ! 299: ! 300: ! 301: ! 302: Notation Used in FAQ ! 303: ! 304: Skip this section and then come back if you don't understand some of the ! 305: later answers. ! 306: ! 307: 1: What do these mean: C-h, M-C-a, RET, "ESC a", etc.? ! 308: ! 309: C-x means press the `x' key while holding down the Control key. M-x means ! 310: press the `x' key while holding down the Meta key. M-C-x means press the ! 311: `x' key while holding down both the Control key and the Meta key. C-M-a ! 312: is a synonym for M-C-a. RET, LFD, DEL, ESC, and TAB respectively refer to ! 313: pressing the Return, Linefeed (aka Newline), Delete, Escape, and Tab keys ! 314: and are equivalent to C-m, C-j, C-?, C-[, and C-i. SPC means press the ! 315: Space bar. ! 316: ! 317: I put any key sequence that is longer than one key (and some single-key ! 318: sequences) inside double quotes or on a line by itself. Any real spaces ! 319: in such a key sequence should be ignored; only SPC really means press the ! 320: space key. ! 321: ! 322: The ASCII code sent by C-x (except for C-?) is the value that would be ! 323: sent by pressing just `x' minus 96 (or 64 for uppercase `X') and will be ! 324: from 0 to 31. The ASCII code sent by M-x is the sum of 128 and the ASCII ! 325: code that would be sent by pressing just the `x' key. Essentially, the ! 326: Control key turns off bits 5 and 6 and the Meta key turns on bit 7. ! 327: ! 328: For further information, see `Characters' and `Keys' in the online manual. ! 329: ! 330: NOTE: C-? (aka DEL) is ASCII code 127. It is a misnomer to call C-? a ! 331: "control" key, since 127 has both bits 5 and 6 turned ON. Also, on very ! 332: few keyboards does Control-? generate ASCII code 127. ! 333: ! 334: 2: What does "M-x command" mean? ! 335: ! 336: "M-x command" means type M-x, then type the name of the command, then ! 337: type RET. ! 338: ! 339: M-x (by default) invokes the command `execute-extended-command'. This ! 340: command allows you to run any Emacs command if you can remember the ! 341: command's name. If you can't remember the command's name, you can type ! 342: TAB and SPC for completion, and "?" for a list of possibilities. An Emacs ! 343: "command" is any "interactive" Emacs function. ! 344: ! 345: NOTE: Your system administrator may have bound other key sequences to ! 346: invoke execute-extended-command. A function key labeled `Do' is a good ! 347: candidate for this. ! 348: ! 349: To run non-interactive Emacs functions, see question 53. ! 350: ! 351: 3: How do I read topic XXX in the on-line manual? ! 352: ! 353: When I refer you to topic XXX in the on-line manual, you can read this ! 354: manual node inside Emacs (assuming nothing is broken) by typing this: ! 355: ! 356: C-h i m emacs RET m XXX RET ! 357: ! 358: This invokes the Info facility. If you don't already know how to use ! 359: Info, type "?" from within Info. ! 360: ! 361: If I refer you to topic XXX:YYY, you need to type this: ! 362: ! 363: C-h i m emacs RET m XXX RET m YYY RET ! 364: ! 365: WARNING: Your system administrator may not have installed the Info files, ! 366: or may have installed them properly. In this case you should complain. ! 367: ! 368: 4: What do these mean: etc/SERVICE, src/config.h, lisp/default.el? ! 369: ! 370: These are files that come with GNU Emacs. The GNU Emacs distribution is ! 371: divided into subdirectories; the important ones are `etc', `lisp', and ! 372: `src'. ! 373: ! 374: If you use GNU Emacs, but don't know where it is kept on your system, ! 375: start Emacs, then type "C-h v exec-directory RET". The directory name ! 376: displayed by this will be the full pathname of the installed `etc' ! 377: directory. ! 378: ! 379: Some of these files are available individually via FTP or e-mail, see ! 380: question 20. All are available in the source distribution. ! 381: ! 382: 5: What are FSF, LPF, OSF, GNU, RMS, FTP, and GPL? ! 383: ! 384: FSF == Free Software Foundation ! 385: LPF == League for Programming Freedom ! 386: OSF == Open Software Foundation ! 387: GNU == GNU's Not Unix ! 388: RMS == Richard Matthew Stallman ! 389: FTP == File Transfer Protocol ! 390: GPL == GNU General Public Licence ! 391: ! 392: NOTE: Avoid confusing the FSF, the LPF, and the OSF. The LPF opposes ! 393: look-and-feel copyrights and software patents. The FSF aims to make high ! 394: quality free software available for everyone. The OSF is a commercial ! 395: organization which wants to provide an alternative, standardized version ! 396: of Unix not controlled by AT&T. ! 397: ! 398: NOTE: The word "free" in the title of the Free Software Foundation refers ! 399: to "freedom", not "zero dollars". Anyone can charge any price for ! 400: GPL-covered software that they want to. However, in practice, the freedom ! 401: enforced by the GPL leads to low prices, because you can always get the ! 402: software for less money from someone else, because everyone has the right ! 403: to resell or give away GPL-covered software. ! 404: ! 405: ! 406: ! 407: General Questions ! 408: ! 409: 6: What is the LPF and why should I join it? ! 410: ! 411: The LPF opposes the expanding danger of software patents and look-and-feel ! 412: copyrights. To get more information, feel free to contact the LPF via ! 413: e-mail or otherwise. {You may also contact me, [email protected]; I will be ! 414: happy to talk with you about the LPF.} Here is the contact information: ! ! 415: ! 416: E-mail address: [email protected] ! 417: Phone number: (617) 243-4091 ! ! 418: Postal address: ! 419: League for Programming Freedom ! 420: 1 Kendall Square, Number 143 ! 421: Post Office Box 9171 ! 422: Cambridge, MA 02139, USA ! 423: ! 424: Papers describing the LPF's views are available on the internet and also ! ! 425: from the LPF: ! ! 426: ! 427: Anonymous FTP: ! 428: /prep.ai.mit.edu:/pub/lpf/ + ! 429: /archive.cis.ohio-state.edu:pub/lpf/ ! ! 430: Anonymous UUCP: ! 431: osu-cis!~/lpf/* - ! 432: ! 433: 7: What is the real legal meaning of the GNU copyleft? ! 434: ! 435: The real legal meaning of the GNU General Public Licence (copyleft) is ! 436: however it is interpreted by a judge. There has never been a copyright ! 437: infringment case involving the GPL to set any precedents. Please take any ! 438: discussion regarding this issue to the newsgroup gnu.misc.discuss, which ! 439: was created to hold the extensive flame wars on the subject. ! 440: ! 441: RMS writes: ! 442: ! 443: The legal meaning of the GNU copyleft is less important than the spirit, ! 444: which is that Emacs is a free software project and that work pertaining ! 445: to Emacs should also be free software. "Free" means that all users have ! 446: the freedom to study, share, change and improve Emacs. To make sure ! 447: everyone has this freedom, pass along source code when you distribute ! 448: any version of Emacs or a related program, and give the recipients the ! 449: same freedom that you enjoyed. ! 450: ! 451: 8: What are appropriate messages for gnu.emacs.help, gnu.emacs.bug, ! 452: comp.emacs, etc.? ! 453: ! 454: The file etc/MAILINGLISTS discusses the purpose of each GNU mailing-list. ! 455: (See question 20 on how to get a copy.) For those which are gatewayed ! 456: with newsgroups, it lists both the newsgroup name and the mailing list ! 457: address. ! 458: ! 459: comp.emacs is for discussion of Emacs programs in general. This ! 460: includes GNU Emacs along with various other implementations like JOVE, ! 461: MicroEmacs, Freemacs, MG, Unipress, CCA, Epsilon, etc. ! 462: ! 463: Many people post GNU Emacs questions to comp.emacs because they don't ! 464: receive any of the gnu.* newsgroups. Arguments have been made both for ! 465: and against posting GNU-Emacs-specific material to comp.emacs. You have ! 466: to decide for yourself. ! 467: ! 468: Messages advocating "non-free" software are considered unacceptable on any ! 469: of the gnu.* newsgroups except for gnu.misc.discuss, which was created to ! 470: hold the extensive flame-wars on the subject. "non-free" software ! 471: includes any software for which the end user can't freely modify the ! 472: source code and exchange enhancements. Be careful to remove the gnu.* ! 473: groups from the `Newsgroups:' line when posting a followup that recommends ! 474: such software. ! 475: ! 476: gnu.emacs.bug is a place where bug reports appear, but avoid posting bug ! 477: reports to this newsgroup, instead see question 10. ! 478: ! 479: 9: Where can I get old postings to gnu.emacs.help and other GNU groups? ! 480: ! 481: The FSF has maintained archives of all of the GNU mailing lists for many ! 482: years, although there may be some unintentional gaps in coverage. The ! 483: archive is not particularly well organized or easy to retrieve individual ! 484: postings from, but pretty much everything is there. ! 485: ! 486: Anonymous FTP: ! 487: /prep.ai.mit.edu:/pub/gnu/emacs/MailingListArchives/ ! ! 488: ! 489: {There was a WAIS database named `comp-emacs' on lambada.oit.unc.edu that ! 490: makes available the last 10 days of articles in comp.emacs. It appears to ! 491: have died. Anyone know if it moved?} ! 492: ! 493: 10: Where should I report bugs and other problems with GNU Emacs? ! 494: ! 495: The correct way to report GNU Emacs bugs is by e-mail to ! 496: [email protected]. Anything sent here also appears in the ! 497: newsgroup gnu.emacs.bug, but please use e-mail instead of news to submit ! 498: the bug report. This way a reliable return address is available so you ! 499: can be contacted for further details. ! 500: ! 501: RMS explains: ! 502: ! 503: Sending bug reports to help-gnu-emacs (which has the effect of posting ! 504: on gnu.emacs.help) is undesirable because it takes the time of an ! 505: unnecessarily large group of people, most of whom are just users and ! 506: have no idea how to fix these problem. bug-gnu-emacs reaches a much ! 507: smaller group of people who are more likely to know what to do and have ! 508: expressed a wish to receive more messages about Emacs than the others. ! 509: ! 510: However, RMS says there are circumstances when it is okay to post to ! 511: gnu.emacs.help: ! 512: ! 513: If you have reported a bug and you don't hear about a possible fix, then ! 514: after a suitable delay (such as a week) it is okay to post on ! 515: gnu.emacs.help asking if anyone can help you. ! 516: ! 517: If you are unsure whether you have a bug, RMS describes how to tell: ! 518: ! 519: ... if Emacs crashes, that is a bug. If Emacs gets compilation errors ! 520: while building, that is a bug. If Emacs crashes while building, that is ! 521: a bug. If Lisp code does not do what the documentation says it does, ! 522: that is a bug. ! 523: ! 524: 11: How do I unsubscribe to this mailing list? ! 525: ! 526: If you are receiving a GNU mailing list named `XXX', you might be able ! 527: to unsubscribe to it by sending a request to the address ! 528: `[email protected]'. However, this will not work if you are ! 529: not listed on the main mailing list, but instead recieve the mail from a ! 530: distribution point. In that case, you will have to track down at which ! 531: distribution point you are listed. Inspecting the `Received:' headers ! 532: on the mail messages may help, along with liberal use of the `EXPN' or ! 533: `VRFY' sendmail commands through `telnet <site-address> smtp'. Ask your ! 534: postmaster for help. ! 535: ! 536: 12: What is the current address of the FSF? ! 537: ! 538: E-mail address: [email protected] + ! 539: Phone number: (617) 876-3296 + ! 540: Postal address: ! 541: Free Software Foundation, Inc. ! 542: 675 Massachusetts Avenue ! 543: Cambridge, MA 02139, USA - ! 544: ! 545: ! 546: ! 547: On-line Help, Printed Manuals, Other Sources of Help ! 548: ! 549: 13: I'm just starting GNU Emacs; how do I do basic editing? ! 550: ! 551: Type "C-h t" to invoke the self-paced tutorial. Typing just C-h is ! 552: how to enter the help system. ! 553: ! 554: WARNING: Your system administrator may have changed C-h to act like DEL to ! 555: deal local keyboards. You can use M-x help-for-help instead to invoke ! 556: help. To discover what key (if any) invokes help on your system, type ! 557: "M-x where-is RET help-for-help RET". This will print a comma-separated ! 558: list of key sequences in the echo area. Ignore the last character in each ! 559: key sequence listed. Each of the resulting key sequences invokes help. ! 560: ! 561: NOTE: Emacs's help facility works best if help is invoked by a single key ! 562: whose value should be stored in the variable help-char. Andrew ! 563: Arensburger <[email protected]> wrote a patch that allows the help ! 564: facility to work properly when invoked by multiple character sequences. ! 565: ! 566: 14: How do I find out how to do something in GNU Emacs? ! 567: ! 568: There are several methods for finding out how to do things in Emacs. ! 569: ! 570: * The complete text of the Emacs manual is available online via the Info ! 571: hypertext reader. Type "C-h i" to invoke Info. ! 572: ! 573: * You can order a hardcopy of the manual from the FSF. See question 15. ! 574: ! 575: * You can get a printed reference card listing commands and keys to invoke ! 576: them. You can order one from the FSF for $1 (or 10 for $5), or you can ! 577: print your own from the etc/refcard.tex file in the Emacs distribution. ! 578: {Are PostScript versions of this available for FTP?} ! 579: ! 580: * You can list all of the commands whose names contain a certain word ! 581: (actually which match a regular expression) using "C-h a" ! 582: (M-x command-apropos). ! 583: ! 584: * You can list all of the functions and variables whose names contain a ! 585: certain word using M-x apropos. ! 586: ! 587: * There are many other commands in Emacs for getting help and information. ! 588: To get a list of these commands, type "C-h C-h C-h". ! 589: ! 590: NOTE: You may find that command-apropos and apropos are extremely slow ! 591: on your system. This will be fixed in Emacs 19. If you can't wait that ! 592: long, there is a fast-apropos.el file available in the Emacs Lisp ! 593: Archive (see question 89) that contains the fix. ! 594: ! 595: 15: How do I get a printed copy of the GNU Emacs manual? ! 596: ! 597: You can order a printed copy of the GNU Emacs manual from the FSF for ! 598: $20. For 6 or more manuals the price is $13 each. The price may be - ! 599: tax-deductible as a business expense. - ! 600: ! 601: The full TeX source for the manual also comes in the `man' directory of ! 602: the Emacs distribution, if you're daring enough to try to print out this ! 603: 300 page manual yourself (see question 18). ! 604: ! 605: If you absolutely have to print your own copy, and you don't have TeX, you ! 606: can get a PostScript version via anonymous FTP: ! ! 607: ! ! 608: /cs.ubc.ca:src/gnu/manuals_ps/emacs-18.57.ps.Z ! ! 609: ! 610: which site requests that you please CONFINE ANY MAJOR FTPING TO LATE ! 611: EVENINGS OR EARLY MORNINGS OUR TIME (pacific time zone, GMT-8)). A DVI ! 612: version is also available via FTP: ! ! 613: ! ! 614: /prep.ai.mit.edu:pub/gnu/emacs-manual-6.0.dvi.Z ! ! 615: ! 616: If you don't have TeX you can convert the Texinfo sources into ! 617: {t,n,ps}roff format with the `texi2roff' program, which is available via ! 618: anonymous FTP: ! ! 619: ! ! 620: /archive.cis.ohio-state.edu:pub/gnu/texi2roff/texi2roff.shar.Z ! ! 621: ! 622: See also question 14 for how to view the manual online. ! 623: ! 624: 16: Where can I get documentation on GNU Emacs Lisp? ! 625: ! 626: Within Emacs, you can type "C-h f" to get the documentation for a ! 627: function, "C-h v" for a variable. ! 628: ! 629: For more information, obtain the GNU Emacs Lisp Reference Manual for Emacs ! 630: 18 under Unix. It is available from the FSF for $50 (or 5 for $200). The ! 631: latest revision available for FTP is edition 1.03 dated 28 January 1991. ! 632: ! 633: For online use, a set of pregenerated Info files is available with the ! 634: Texinfo source for the Emacs Lisp manual via anonymous FTP: ! ! 635: ! ! 636: /archive.cis.ohio-state.edu:pub/gnu/emacs/ ! ! 637: /prep.ai.mit.edu:pub/gnu/elisp-manual-1.03.tar.Z ! ! 638: ! 639: (You can also create the Info files from the Texinfo source.) See ! 640: question 17 for details on how to install these files online. ! 641: ! 642: If you are daring enough to try to print this 550 page manual out ! 643: yourself, for instructions see question 18. ! 644: ! 645: Also, as a popular USENET saying goes, "Use the Force, Read the Source". ! 646: ! 647: 17: How do I install a piece of Texinfo documentation? ! 648: ! 649: First create Info files from the Texinfo files with the `makeinfo' ! 650: program. makeinfo is available as part of the latest Texinfo package: ! ! 651: ! ! 652: /prep.ai.mit.edu:pub/gnu/texinfo-2.14.tar.Z ! ! 653: ! 654: For information about the Texinfo format, read the Texinfo manual which ! 655: comes with Emacs. This manual also comes installed in Info format, so you ! 656: can read it online. ! 657: ! 658: Neither texinfo-format-buffer nor the makeinfo program install the ! 659: resulting Info files in Emacs's Info tree. To install Info files: ! 660: ! 661: 1. Move the files to the `info' directory in the installed Emacs ! 662: distribution. See question 4 if you don't know where that ! 663: is. ! 664: ! 665: 2. Edit the file info/dir in the installed Emacs distribution, and add a ! 666: line for the top level node in the Info package that you are ! 667: installing. Follow the examples are already in this file. The format ! 668: is: ! 669: ! 670: * Topic: (relative-pathname). Short description of topic. ! 671: ! 672: If you want to install Info files and you don't have the necessary ! 673: privileges, you have several options: ! 674: ! 675: * Info files don't actually need to be installed before being used. You ! 676: can feed a file name to the Info-goto-node command (invoked by pressing ! 677: "g" in Info mode) by typing the name of the file in parentheses. This ! 678: goes to the node named `Top' in that file. For example, to view a Info ! 679: file named `XXX' in your home directory, you can type this: ! 680: ! 681: C-h i g (~/XXX) RET ! 682: ! 683: * You can create your own Info directory. You can tell Emacs where the ! 684: Info directory is by setting the value of the variable Info-directory ! 685: to its pathname. For example, to use a private Info directory which ! 686: is a subdirectory of your home directory named `Info', you could do ! 687: this: ! 688: ! 689: (setq Info-directory (expand-file-name "~/Info")) ! 690: ! 691: You will need a top-level Info file named `dir' in this directory. ! 692: You can include the system-wide Info directory in your private Info ! 693: directory with symbolic links or by copying it. ! 694: ! 695: * You can use an enhanced version of lisp/info.el that handles multiple ! 696: Info directories. Then you can more easily use a mix of private and ! 697: shared Info files. Dave Gillespie <[email protected], ! 698: [email protected]> has written one such enhancement and I ! 699: believe there are others. Dave's info.el also handles compressed Info ! 700: files. ! 701: ! 702: Anonymous FTP: ! 703: /archive.cis.ohio-state.edu:modes/info.el.Z ! ! 704: /cs.umn.edu:pub/gnu/emacs/info.el.Z + ! 705: ! 706: According to Jay Bourland <[email protected]>, a version of Dave's ! 707: info.el comes with `xinfo' (see question 19). ! 708: ! 709: 18: How do I print a Texinfo file? ! 710: ! 711: NOTE: You can't get nice printed output from Info files; you must still ! 712: have the original Texinfo source file for the manual you want to print. ! 713: ! 714: 1. Make sure the first line of the Texinfo file looks like this: ! 715: ! 716: \input texinfo ! 717: ! 718: You may need to alter `texinfo' to the full pathname of the ! 719: texinfo.tex file, which comes with Emacs as man/texinfo.tex (or copy ! 720: or link it into the current directory). ! 721: ! 722: 2. tex XXX.texinfo ! 723: ! 724: 3. texindex XXX.?? ! 725: ! 726: The `texindex' program comes with Emacs as man/texindex.c. ! 727: ! 728: 4. tex XXX.texinfo ! 729: ! 730: 5. Print the DVI file XXX.dvi in the normal way for printing DVI files ! 731: at your site. ! 732: ! 733: To get more general instructions, retrieve the latest Texinfo package ! 734: mentioned in question 17. ! 735: ! 736: 19: Can I view Info files without using GNU Emacs? ! 737: ! 738: Yes, the `info', `xinfo', and `ivinfo' programs do this. info uses ! 739: curses, xinfo uses standard X11 libraries, and ivinfo uses InterViews. ! 740: You can get info as part of the latest Texinfo package (see question ! 741: 17). xinfo is available separately: ! ! 742: ! ! 743: /prep.ai.mit.edu:pub/gnu/xinfo-1.01.01.tar.Z ! ! 744: /export.lcs.mit.edu: ! ! 745: ! 746: ivinfo is available in a comp.sources.misc archive or from Tom Horsley ! 747: <[email protected]>. For ivinfo, you need Stanford's InterViews C++ ! 748: X library, available via anonymous FTP (interviews.stanford.edu). ! 749: ! 750: 20: What informational files are available for GNU Emacs? ! 751: ! 752: This isn't a frequently asked question, but it should be! A variety of ! 753: informational files about GNU Emacs and relevant aspects of the GNU ! 754: project are available for you to read. ! 755: ! 756: The following files are available in the `etc' directory of the GNU ! 757: Emacs distribution, and also the latest versions are available ! 758: individually via anonymous FTP (prep.ai.mit.edu:/pub/gnu/GNUinfo/): ! 759: ! 760: APPLE -- Why the FSF doen't support GNU Emacs on Apple computers ! 761: DISTRIB -- GNU Emacs Availability Information, ! 762: including the popular "Free Software Foundation Order Form" ! 763: FTP -- How to get GNU Software by Internet FTP or by UUCP ! 764: GNU -- The GNU Manifesto ! 765: INTERVIEW -- Richard Stallman discusses his public-domain ! 766: UNIX-compatible software system ! 767: with BYTE editors ! 768: MACHINES -- Status of GNU Emacs on Various Machines and Systems ! 769: MAILINGLISTS -- GNU Project Electronic Mailing Lists ! 770: SERVICE -- GNU Service Directory ! 771: SUN-SUPPORT -- including "Using Emacstool with GNU Emacs" ! 772: ! 773: These files are available in the `etc' directory of the GNU Emacs ! 774: distribution: ! 775: ! 776: DIFF -- Differences between GNU Emacs and Twenex Emacs ! 777: CCADIFF -- Differences between GNU Emacs and CCA Emacs ! 778: GOSDIFF -- Differences between GNU Emacs and Gosling (Unipress??) Emacs ! 779: COPYING -- GNU Emacs General Public License ! 780: NEWS -- GNU Emacs News, a history of user-visible changes ! 781: LPF -- Why you should join the League for Programming Freedom ! 782: FAQ -- GNU Emacs Frequently Asked Questions (You're reading it) ! 783: OPTIONS -- a complete explanation of startup option handling ! 784: ! 785: These files are available via anonymous FTP (prep.ai.mit.edu:/pub/gnu/): ! 786: ! 787: tasks -- GNU Task List ! 788: standards.text -- GNU Coding Standards ! 789: ! 790: In addition, all of the above files are available directly from the FSF ! 791: via e-mail. Of course, please try to get them from a local source ! 792: first. ! 793: ! 794: These additional files are available from the FSF via e-mail: ! 795: ! 796: * GNU's Bulletin, June, 1991 -- this file includes: ! 797: GNU'S Who ! 798: What Is the Free Software Foundation? ! 799: What Is Copyleft? ! 800: A Small Way to Help Free Software ! 801: GNUs Flashes (important recent developments for project GNU) ! 802: Free Software Support (and how to get it!) ! 803: Copyrighted Programming Languages ! 804: AT&T Threatens Users of X Windows (and other software patent threats) ! 805: Project Gutenberg ! 806: GNU Project Status Report ! 807: GNU in Japan ! 808: GNU Wish List ! 809: Help Keep Government Software Free ! 810: GNU Software Available Now ! 811: Contents of the Emacs Tape ! 812: Contents of the Compiler Tape ! 813: Contents of the X11 Tapes ! 814: VMS Emacs and Compiler Tapes ! 815: GNU Documentation ! 816: How to Get GNU Software ! 817: Free Software for Microcomputers ! 818: GNU Software on Apple computers ! 819: GNU Software on the Amiga ! 820: GNU Software on the Atari ! 821: GNUish MS-DOS project ! 822: Freemacs, an Extensible Editor for MS-DOS ! 823: GNU in Japan ! 824: FSF Order Form ! 825: Thank GNUs ! 826: * Legal issues about contributing code to GNU ! 827: * GNU Project Status Report ! 828: ! 829: A collection of past GNU's Bulletins is available via anonymous FTP: + ! 830: + ! 831: /ftp.funet.fi:pub/gnu/Bulletins/ + ! 832: ! 833: 21: Where can I get help in installing GNU Emacs? ! 834: ! 835: Look in etc/SERVICE for names of companies and individuals who will sell ! 836: you this type of service. An up-to-date version of the SERVICE file is ! 837: available on prep.ai.mit.edu (also see question 20). ! 838: ! 839: 22: Where can I get the latest version of this document (the FAQ list)? ! 840: ! 841: The GNU Emacs FAQ is available in several ways: ! 842: ! 843: * Via USENET. If you can read news, the FAQ should be available in your ! 844: news spool, in both the gnu.emacs.help and comp.emacs newsgroups. Every ! 845: news reader of which I know will allow you to read any news article that ! 846: is still in the news spool, even if you have read the article before. ! 847: You may need to read the instructions for your news reader to discover ! 848: how to do this. In `rn', this command will do this for you at the ! 849: article selection level: ! 850: ! 851: ?GNU Emacs FAQ?rc:m ! 852: ! 853: In GNUS, you should type "C-u G" from the *Subject* buffer or "C-u SPC" ! 854: from the *Newsgroup* buffer to view all articles in a newsgroup. ! 855: ! 856: The FAQ articles' message IDs are: ! 857: ! 858: <[email protected]> ! ! 859: <[email protected]> ! ! 860: <[email protected]> ! ! 861: <[email protected]> ! ! 862: <[email protected]> ! ! 863: <[email protected]> ! ! 864: ! 865: If you are viewing this in the GNUS *Article* buffer, you can move point ! 866: within one of the above message IDs and type "r" to fetch the referenced ! 867: article. Type "o" in the *Article* buffer to restore the previous ! 868: contents. If this text is not in the GNUS *Article* buffer, use M-r ! 869: from the *Subject* buffer instead. ! 870: ! 871: If the FAQ articles have expired and been deleted from your news spool, ! 872: it might (or might not) do some good to complain to your news ! 873: administrator, because the most recent FAQ should not expire before ! 874: November 21, 1992. ! ! 875: ! 876: * Via anonymous FTP. You can fetch the FAQ articles via anonymous FTP ! 877: ! 878: /rtfm.mit.edu:pub/usenet/news.answers/GNU-Emacs-FAQ/ part* ! ! 879: ! 880: * Via e-mail. You can send the following magical incantation in the body ! 881: of a message to [email protected]: ! 882: ! 883: send usenet/news.answers/GNU-Emacs-FAQ/part0 ! 884: send usenet/news.answers/GNU-Emacs-FAQ/part1 ! 885: send usenet/news.answers/GNU-Emacs-FAQ/part2 ! 886: send usenet/news.answers/GNU-Emacs-FAQ/part3 ! 887: send usenet/news.answers/GNU-Emacs-FAQ/part4 ! 888: send usenet/news.answers/GNU-Emacs-FAQ/part5 ! 889: ! 890: * Via WAIS. The GNU Emacs FAQ is available via WAIS indexed on a ! 891: per-question basis from the `faq' database on bigbird.bu.edu on the ! 892: non-standard IP port number of 2210. This is probably the best way to ! 893: find out if there is something in the FAQ related to your question. I ! 894: use this myself to answer questions I see posted on gnu.emacs.help. ! 895: ! 896: The articles of the GNU Emacs FAQ are also available from the `usenet' ! 897: database on rtfm.mit.edu (on the standard IP port: 210), along with a ! 898: lot of other FAQ articles. However, these are all indexed at the whole ! 899: article level instead of at the question level. This is a better place ! 900: to look if you want to fetch the entire FAQ. ! 901: ! 902: * In the GNU Emacs distribution. Since GNU Emacs 18.56, the latest ! 903: available version of the FAQ at the time of release has been part of the ! 904: GNU Emacs distribution as file etc/FAQ. 18.58 is the latest version, ! 905: and it was released in February 1992. ! 906: ! 907: * There is an old version of the FAQ list available for FTP in the GNU + ! 908: archives at MIT: + ! 909: + ! 910: /prep.ai.mit.edu:pub/gnu/GNUinfo/FAQ.emacs + ! 911: + ! 912: * As the very last resort, you can e-mail a request to + ! 913: [email protected]. Don't do this unless you have ! 914: made a serious effort to obtain the FAQ list via one of the methods ! 915: listed above. ! 916: ! 917: ! 918: ! 919: Status of Emacs ! 920: ! 921: 23: Where does the name "Emacs" come from? ! 922: ! 923: Emacs originally was an acronym for Editor MACroS. RMS says he "picked ! 924: the name `Emacs' because `E' was not in use as an abbreviation on ITS at ! 925: the time.". The first Emacs was a set of macros written in 1976 at MIT by ! 926: RMS for the editor TECO (Text Editor and COrrector (originally Tape Editor ! 927: and COrrector)) under ITS on a PDP-10. RMS had already extended TECO with ! 928: a "real-time" full screen mode with active keys. Emacs was started by Guy ! 929: Steele <[email protected]> as a project to unify the many divergent TECO ! 930: command sets and keybindings at MIT. ! 931: ! 932: Many people have told me that TECO code looks a lot like line noise. See ! 933: alt.lang.teco if you are interested. I think someone has written a TECO ! 934: implementation in Emacs Lisp. It would be an interesting project to run ! 935: the original TECO Emacs inside of GNU Emacs. ! 936: ! 937: 24: What is the latest version of GNU Emacs? ! 938: ! 939: GNU Emacs 18.58 is the current version. Fixes from 18.57 include better ! 940: mail address parsing, an X visual bell speedup, a call-process ! 941: enhancement, a regexp matching change, the ability to apply a numeric ! 942: argument to a self-inserting digit, getting X resource values from the ! 943: RESOURCE_MANAGER property, more reliable shell mode job control, and a ! 944: change to copy-keymap. Also, support has been added for many new system ! 945: types. Fixes from 18.55 include the removal of arbitrary limits on the ! 946: undo facility. ! 947: ! 948: According to the January 1992 GNU's Bulletin, "Emacs 18 maintenance ! 949: continues for simple bug fixes.". ! 950: ! 951: To visit a file with information about what has changed in recent ! 952: versions, type "C-h n". ! 953: ! 954: 25: When will GNU Emacs 19 be available? ! 955: ! 956: There are strong indications that Emacs 19 will be available in 1992. The ! 957: FSF has recently gone through a spate of copyright disclaimer checking, ! 958: which is a good sign. ! 959: ! 960: Lucid has released Lucid GNU Emacs 19.2, which is based on an early ! 961: unreleased version of GNU Emacs 19. This will be similar to Emacs 19 when ! 962: it finally arrives, but they are not the same. See question 121. ! 963: ! 964: Work has begun on features for Emacs 20. ! 965: ! 966: 26: What is different about GNU Emacs 19? ! 967: ! 968: From the January 1992 GNU's Bulletin: ! 969: ! 970: Version 19 will enter beta test late this year. Among its new features ! 971: are: before and after change hooks, source-level debugging of Emacs Lisp ! 972: programs, X selection processing (including clipboard selections), ! 973: scrollbars, support for European character sets, floating point numbers, ! 974: per-buffer mouse commands, X resource manager interfacing, ! 975: mouse-tracking, Lisp-level binding of function keys, multiple X windows ! 976: (`screens' to Emacs), a new input system, and buffer allocation, which ! 977: uses a new mechanism capable of returning storage to the system when a ! 978: buffer is killed. ! 979: ! 980: The input stream is now a sequence of Lisp objects, instead of a ! 981: sequence of characters. This allows a reasonable representation for ! 982: mouse clicks, function keys, menu selections, etc. ! 983: ! 984: Thanks go to Alan Carroll and the people who worked on Epoch for ! 985: generating initial feedback to a multi-windowed Emacs, and to Eric ! 986: Raymond for help in polishing the Emacs 19 Lisp libraries. ! 987: ! 988: The June 1991 GNU's bulletin had this to say about future plans for Emacs: ! 989: ! 990: Features being considered for later releases of Emacs include: ! 991: associating property lists with regions of text in a buffer; multiple ! 992: fonts, color, and pixmaps defined by those properties; different ! 993: visibility conditions for the regions, and for various windows showing ! 994: one buffer; hooks to be run if point or mouse moves outside a certain ! 995: range; incrementally saving undo history in a file; static menu bars; ! 996: and better pop-up menus. ! 997: ! 998: Mention of this feature disappeared in the January 1992 GNU's bulletin: ! 999: ! 1000: Emacs 19 supports two styles of multiple windows, one with a separate ! 1001: screen for the minibuffer, and another with a minibuffer attached to ! 1002: each screen. ! 1003: ! 1004: Mention of these two proposed features disappeared in the January 1991 ! 1005: GNU's bulletin: ! 1006: ! 1007: * Incremental syntax analysis for various programming languages (Leif). ! 1008: * A more sophisticated emacsclient/server model, which would provide ! 1009: network transparent Emacs widget functionality. ! 1010: ! 1011: 27: What variants of GNU Emacs exist? ! 1012: ! 1013: * Nemacs (Nihongo Emacs), which can handle Japanese text, is derived from + ! 1014: GNU Emacs 18.55. See question 149. ! 1015: ! 1016: * Demacs, which can run under MS-DOS on 386 machines, is derived from ! 1017: Nemacs. See question 122. ! 1018: ! 1019: * Epoch, which has better X support, is derived from GNU Emacs 18.58. ! 1020: See question 120 and 92. ! 1021: ! 1022: * Nepoch (Nihongo Epoch), which can handle Japanese text, is derived from + ! 1023: Epoch. + ! 1024: + ! 1025: * Mule (the MULtilingual Enhancement of GNU Emacs) can handle many + ! 1026: character sets simultaneously. It is derived from Emacs 18.58. It is + ! 1027: available for FTP: + ! 1028: + ! 1029: /sh.wide.ad.jp:/JAPAN/mule/ + ! 1030: /etlport.etl.go.jp:/pub/mule/ + ! 1031: + ! 1032: * Lucid GNU Emacs is derived from an early unreleased version of GNU Emacs + ! 1033: 19. See question 121 and 92. ! 1034: ! 1035: GNU Emacs FAQ: Common Requests/Problems ! 1036: ! 1037: If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to ! 1038: get an overview of just the questions. Then, when you want to look at the text ! 1039: of the answers, just type "C-x $". ! 1040: ! 1041: To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if ! 1042: that doesn't work, then type ESC to end the search. ! 1043: ! 1044: A `+' in the 78th column means something was inserted on the line. A `-' means ! 1045: something was deleted and a `!' means some combination of insertions and ! 1046: deletions occurred. ! 1047: ! 1048: Full instructions for getting the latest FAQ are in question 22. Also see the ! 1049: `Introduction to news.answers' posting in the `news.answers' newsgroup, or send ! 1050: e-mail to `[email protected]' with `help' on a body line, or use FTP, ! 1051: WAIS, or Prospero to rtfm.mit.edu. ! 1052: ! 1053: ! 1054: ! 1055: Common Things People Want To Do ! 1056: ! 1057: 28: How do I set up a .emacs file properly? ! 1058: ! 1059: See `Init File' in the on-line manual. ! 1060: ! 1061: WARNING: In general, new Emacs users should not have .emacs files, because ! 1062: it causes confusing non-standard behavior. Then they send questions to ! 1063: help-gnu-emacs asking why Emacs isn't behaving as documented. :-) ! 1064: ! 1065: 29: How do I debug a .emacs file? ! 1066: ! 1067: First start Emacs with the `-q' command line option. Then, in the ! 1068: *scratch* buffer, type the following: ! 1069: ! 1070: (setq debug-on-error t) LFD ! 1071: (load-file "~/.emacs") LFD ! 1072: ! 1073: (Type LFD by pressing C-j.) ! 1074: ! 1075: If you have an error in your .emacs file, this will invoke the debugger ! 1076: when the error occurs. If you don't know how to use the debugger do ! 1077: (setq stack-trace-on-error t) instead. ! 1078: ! 1079: WARNING: this will not discover errors caused by trying to do something ! 1080: that requires the terminal/window-system initialization code to have ! 1081: been loaded. See question 127. ! 1082: ! 1083: 30: How do I make Emacs display the current line (or column) number? ! 1084: ! 1085: To find out what line of the buffer you are on right now, do "M-x ! 1086: what-line". Use "M-x goto-line" to go to a specific line. To find the ! 1087: current column number, type "M-ESC (current-column)". ! 1088: ! 1089: Typing "C-x l" will also tell you what line you are on, provided the ! 1090: buffer isn't separated into "pages" with C-l characters. In that case, it ! 1091: will only tell you what line of the current "page" you are on. WARNING: ! 1092: "C-x l" gives the wrong value when point is at the beginning of a line. ! 1093: ! 1094: There is no "correct" way to constantly display the current (or total) ! 1095: line (or column) number on the mode line in Emacs 18, or to display the ! 1096: line numbers next to the lines like vi can. Emacs is not a line-oriented ! 1097: editor, and really has no idea what "lines" of the buffer are displayed in ! 1098: the window. It would require a lot of work at the C code level to make ! 1099: Emacs keep track of this. It would not be that hard to get the column ! 1100: number, but it would still require changes at the C code level. ! 1101: ! 1102: None of the vi emulation modes provide the `set number' capability of vi ! 1103: (as far as I know). ! 1104: ! 1105: Emacs 19 will probably be able to show the line number on the mode-line, ! 1106: but probably very inefficiently. ! 1107: ! 1108: People have written various kludges to display line numbers. One is ! 1109: `display-line-numbers' by Wayne Mesard <[email protected], ! 1110: [email protected]>. Look in the Lisp Code Directory. (See question ! 1111: 88.) ! 1112: ! 1113: 31: How do I turn on Abbrevs by default just in mode XXX? ! 1114: ! 1115: Put this in your .emacs file: ! 1116: ! 1117: (condition-case () ! 1118: (read-abbrev-file nil t) ! 1119: (file-error nil)) ! 1120: ! 1121: (setq XXX-mode-hook ! 1122: (function ! 1123: (lambda () ! 1124: (setq abbrev-mode t)))) ! 1125: ! 1126: 32: How do I turn on Auto-Fill mode by default? ! 1127: ! 1128: To turn on Auto-Fill mode just once for one buffer, use "M-x ! 1129: auto-fill-mode". To turn it on for every buffer in, for example, Text ! 1130: mode, do this: ! 1131: ! 1132: (setq text-mode-hook 'turn-on-auto-fill) ! 1133: ! 1134: If you want Auto-Fill mode on in all major modes, do this: ! 1135: ! 1136: (setq-default auto-fill-hook 'do-auto-fill) ! 1137: ! 1138: 33: How do I make Emacs use a certain major mode for certain files? ! 1139: ! 1140: If you want to use XXX mode for all files which end with the extension ! 1141: `.YYY', this will do it for you: ! 1142: ! 1143: (setq auto-mode-alist (cons '("\\.YYY\\'" . XXX-mode) auto-mode-alist)) ! 1144: ! 1145: Otherwise put this somewhere in the first line of any file you want to ! 1146: edit in XXX mode: ! 1147: ! 1148: -*-XXX-*- ! 1149: ! 1150: 34: How do I search for, delete, or replace unprintable (8-bit or control) ! 1151: characters? ! 1152: ! 1153: To search for a single character that appears in the buffer as, for ! 1154: example, `\237', you can type "C-s C-q 2 3 7". (This assumes the value of ! 1155: search-quote-char is 17 (ie., C-q).) Searching for ALL unprintable ! 1156: characters is best done with a "regexp" search. The easiest regexp to use ! 1157: for the unprintable chars is the complement of the regexp for the ! 1158: printable chars. ! 1159: ! 1160: Regexp for the printable chars: [\t\n\r\f -~] ! 1161: ! 1162: Regexp for the unprintable chars: [^\t\n\r\f -~] ! 1163: ! 1164: To type some of these special characters in an interactive argument to ! 1165: isearch-forward-regexp or re-search-forward, you need to use C-q. (`\t', ! 1166: `\n', `\r', and `\f' stand respectively for TAB, LFD, RET, and C-l.) So, ! 1167: to search for unprintable characters using re-search-forward: ! 1168: ! 1169: M-x re-search-forward RET [^ TAB C-q LFD C-q RET C-q C-l SPC -~] RET ! 1170: ! 1171: Using isearch-forward-regexp: ! 1172: ! 1173: M-C-s [^ TAB RET C-q RET C-q C-l SPC -~] ! 1174: ! 1175: To delete all unprintable characters, simply use a replace-regexp: ! 1176: ! 1177: M-x replace-regexp RET [^ TAB C-q LFD C-q RET C-q C-l SPC -~] RET RET ! 1178: ! 1179: Replacing is similar to the above. {I need to write the text for this ! 1180: part of the answer!} ! 1181: ! 1182: Notes: ! 1183: ! 1184: * With isearch, you can type RET to get a quoted LFD (not a quoted RET). ! 1185: ! 1186: * You don't need to quote TAB with either isearch or typing something in ! 1187: the minibuffer. ! 1188: ! 1189: Here are the Emacs Lisp forms of the above regexps: ! 1190: ! 1191: ;; regexp matching all printable characters: ! 1192: "[\t\n\r\f -~]" ! 1193: ! 1194: ;; regexp matching all unprintable characters: ! 1195: "[^\t\n\r\f -~]" ! 1196: ! 1197: 35: How can I highlight a region of text in Emacs? ! 1198: ! 1199: There are ways to get highlighting (reverse video, inverse video) in GNU ! 1200: Emacs 18.58, but either they require patching the C code of Emacs and ! 1201: rebuilding, or they are slow and the highlighting disappears if you scroll ! 1202: or redraw the screen and it can not follow the point. Howard Gayle's ! 1203: patches for 8-bit output appear to allow highlighting (see question ! 1204: ^8-bit-output). Another patch for highlighting is by Kenichi Handa ! 1205: <[email protected]>. There is a patch for use with X by Andy Norman ! 1206: <[email protected]> (and modified for 18.57 by Matthieu Herrb ! 1207: <[email protected]>), which is available for FTP: ! ! 1208: ! ! 1209: /laas.laas.fr:pub/emacs/patch-X11-18.5{5,7} ! ! 1210: ! 1211: You can highlight regions in a variety of ways in Epoch and Lucid Emacs. ! 1212: GNU Emacs 19 may not be able to just temporarily highlight a region. ! ! 1213: ! 1214: Similar comments apply to displaying text in different fonts, except that ! 1215: it is even harder. ! 1216: ! 1217: 36: How do I control Emacs's case-sensitivity when searching/replacing? ! 1218: ! 1219: For searching, the value of the variable case-fold-search determines ! 1220: whether they are case sensitive: ! 1221: ! 1222: (setq case-fold-search nil) ; make searches case sensitive ! 1223: (setq case-fold-search t) ; make searches case insensitive ! 1224: ! 1225: Similarly, for replacing the variable case-replace determines whether ! 1226: replacements preserve case. ! 1227: ! 1228: To change the case sensitivity just for one major mode, use the major ! 1229: mode's hook. For example: ! 1230: ! 1231: (setq XXX-mode-hook ! 1232: (function ! 1233: (lambda () ! 1234: (setq case-fold-search nil)))) ! 1235: ! 1236: 37: How do I make Emacs wrap words for me? ! 1237: ! 1238: M-x auto-fill-mode. The default maximum line width is 74, determined by ! 1239: the variable fill-column. To find how to turn this on automatically see ! 1240: question 32. ! 1241: ! 1242: 38: Where can I get a better spelling checker for Emacs? ! 1243: ! 1244: Use Ispell. See question 119. ! 1245: ! 1246: 39: How can I spell-check TeX or *roff documents? ! 1247: ! 1248: If you want to spell-check TeX or *roff documents with Ispell, you need to ! 1249: arrange for a filter program that understands how to strip TeX or *roff ! 1250: formatting commands to be run. In the TeX distribution, there are several ! 1251: different programs named `detex', all with incompatible options, and a ! 1252: very old pair of programs named `detex' and `delatex', which should ! 1253: probably be avoided. The most useful one for Ispell is `detex' by Daniel ! 1254: Trinkle. A more recent version is available via FTP: ! ! 1255: ! ! 1256: /arthur.cs.purdue.edu:pub/trinkle/detex-2.3.tar.Z ! ! 1257: ! 1258: Raphael Cerf <[email protected]> recently released a program for this + ! 1259: named `xetal': ! ! 1260: ! ! 1261: /spi.ens.fr:pub/unix/tex/ ! ! 1262: ! 1263: There is a program that comes with Unix named `deroff' for stripping ! 1264: formatting commands from *roff files. ! 1265: ! 1266: Here is an example of code you can put in a .emacs file to use these ! 1267: programs: ! 1268: ! 1269: ;; Based on suggestions by David G. Grubbs <[email protected]> and Paul Palmer ! 1270: ;; <[email protected]>. ! 1271: ! 1272: ;; Assuming the use of detex 2.3 by Daniel Trinkle: ! 1273: ;; -w means one word per line. ! 1274: ;; -n means don't expand \input or \include commands. ! 1275: ;; -l means force LaTeX mode. ! 1276: ! 1277: (require 'ispell) ; for the make-variable-buffer-local statements ! 1278: (setq plain-TeX-mode-hook ! 1279: (function ! 1280: (lambda () ! 1281: (setq ispell-filter-hook "detex") ! 1282: (setq ispell-filter-hook-args '("-nw"))))) ! 1283: (setq LaTeX-mode-hook ! 1284: (function ! 1285: (lambda () ! 1286: (setq ispell-filter-hook "detex") ! 1287: (setq ispell-filter-hook-args '("-lnw"))))) ! 1288: (setq nroff-mode-hook ! 1289: (function ! 1290: (lambda () ! 1291: (setq ispell-filter-hook "deroff") ! 1292: (setq ispell-filter-hook-args '("-w"))))) ! 1293: ! 1294: You will have to adjust the arguments for programs other than Trinkle's ! 1295: detex or for other versions of deroff. Experiment running the command ! 1296: from the shell to find the correct options. If you don't have a filter ! 1297: that knows how to output one word per line, you must pipe its output ! 1298: through another filter to break up the output. ! 1299: ! 1300: 40: How do I change load-path? ! 1301: ! 1302: In general, you should only *add* to the load-path. You can add ! 1303: directory /XXX/YYY to the load path like this: ! 1304: ! 1305: (setq load-path (append load-path '("/XXX/YYY/"))) ! 1306: ! 1307: To do this relative to your home directory: ! 1308: ! 1309: (setq load-path (append load-path (list (expand-file-name "~/YYY/")))) ! 1310: ! 1311: 41: How do I use an already running Emacs from another window? ! 1312: ! 1313: The `emacsclient' program is for editing a file using an already running ! 1314: Emacs rather than starting up a new Emacs. It does this by sending a ! 1315: request to the already running Emacs, which must be expecting the request. ! 1316: ! 1317: * Setup ! 1318: ! 1319: Emacs must have executed the `server-start' function for emacsclient to ! 1320: work. This can be done either by a command line option: ! 1321: ! 1322: emacs -f server-start ! 1323: ! 1324: or by invoking server-start from the .emacs file: ! 1325: ! 1326: (if (some conditions are met) (server-start)) ! 1327: ! 1328: When this is done, Emacs starts a subprocess running a program called ! 1329: `server'. `server' creates a Unix domain socket in the user's home ! 1330: directory named `.emacs_server'. ! 1331: ! 1332: To get your news reader, mail reader, etc., to invoke emacsclient, try ! 1333: setting the environment variable EDITOR (or sometimes VISUAL) to the ! 1334: value `emacsclient'. You may have to specify the full pathname of the ! 1335: emacsclient program instead. Examples: ! 1336: ! 1337: # csh commands: ! 1338: setenv EDITOR emacsclient ! 1339: setenv EDITOR /usr/local/emacs/etc/emacsclient # using full pathname ! 1340: ! 1341: # sh command: ! 1342: EDITOR=emacsclient export EDITOR ! 1343: ! 1344: * Normal use ! 1345: ! 1346: When emacsclient is run, it connects to the `.emacs_server' socket and ! 1347: passes its command line options to `server'. When `server' receives ! 1348: these requests, it sends this information on the the Emacs process, ! 1349: which at the next opportunity will visit the files specified. (Line ! 1350: numbers can be specified just like with Emacs.) The user will have to ! 1351: switch to the Emacs window by hand. When the user is done editing a ! 1352: file, the user can type "C-x #" to indicate this. This will switch to ! 1353: another buffer created at the request of emacsclient if there are any. ! 1354: When "C-x #" has been invoked on all of the files that the emacsclient ! 1355: requested to be edited, Emacs will send notification of this to `server' ! 1356: which will pass this on to the emacsclient, which will then exit. ! 1357: ! 1358: NOTE: `emacsclient' and `server' must be running on machines which share ! 1359: the same filesystem for this to work. The pathnames that emacsclient ! 1360: specifies should be correct for the filesystem that the Emacs process ! 1361: sees. The Emacs process should not be suspended at the time emacsclient ! 1362: is invoked. emacsclient should either be invoked from another X window or ! 1363: from a shell window inside Emacs itself. ! 1364: ! 1365: There is an enhanced version of emacsclient/server called `gnuserv' by ! 1366: Andy Norman <[email protected]> which is available in the Emacs Lisp ! 1367: Archive. gnuserv uses Internet domain sockets, so it can work across most ! 1368: network connections. It also supports the execution of arbitrary Emacs ! 1369: Lisp forms and also does not require the client program to wait for ! 1370: completion. It is available via anonymous FTP (Emacs Lisp Archive: ! 1371: packages/gnuserv.shar). ! 1372: ! 1373: 42: How do I make Emacs recognize my compiler's funny error messages? ! 1374: ! 1375: Write a program which runs the compiler as a child and filters its output, ! 1376: rearranging as necessary. Install with same name as compiler somewhere in ! 1377: path. ! 1378: ! 1379: Keith Moore <[email protected]> wrote one such for a C compiler under AIX. ! 1380: Available via FTP: ! ! 1381: ! ! 1382: /cs.utk.edu:readonly/aixcc.lex ! ! 1383: ! 1384: Jim Frost <[email protected]> wrote another for the IBM xlc compiler on the ! 1385: RS/6000. (I don't know if these are both for the same compiler.) ! 1386: Johnathan Vail <[email protected]> wrote something for a High C compiler ! 1387: (`hc', which is one of the compilers on the RS/6000, although I think ! 1388: Johnathan wrote his program for hc on a different computer). ! 1389: ! 1390: 43: How do I indent switch statements like this? ! 1391: ! 1392: Many people want to indent their switch statements like this: ! 1393: ! 1394: f() ! 1395: { ! 1396: switch(x) { ! 1397: case A: ! 1398: x1; ! 1399: break; ! 1400: case B: ! 1401: x2; ! 1402: break; ! 1403: default: ! 1404: x3; ! 1405: } ! 1406: } ! 1407: ! 1408: I don't believe there is any way to do this exactly without modifying the ! 1409: Lisp code in c-mode.el. You can set c-indent-level to 4 and ! 1410: c-label-offset to -2, but this has bad effects elsewhere. {Anyone have a ! 1411: solution?} ! 1412: ! 1413: 44: How can I make Emacs automatically scroll horizontally? ! 1414: ! 1415: There is no completely correct way of doing this that does not involve ! ! 1416: rewriting all commands or writing your own top-level command loop (not a ! ! 1417: completely bad idea). Wayne Mesard <[email protected]> has ! ! 1418: written a particularly advanced kludge called `hscroll.el' that checks ! ! 1419: once a second to make sure point is visible. ! ! 1420: ! 1421: 45: How do I make Emacs "typeover" or "overwrite" instead of inserting? ! 1422: ! 1423: M-x overwrite-mode (a minor mode). ! 1424: ! 1425: 46: How do I stop Emacs from beeping on a terminal? ! 1426: ! 1427: Martin R. Frank <[email protected]> writes: ! 1428: ! 1429: Tell Emacs to use the 'visible bell' instead of the audible bell, and ! 1430: set the visible bell to nothing. ! 1431: ! 1432: Put this in your TERMCAP environment variable: ! 1433: ! 1434: ... :vb=: ... ! 1435: ! 1436: And evaluate this: ! 1437: ! 1438: (setq visible-bell t) ! 1439: ! 1440: 47: How do I turn down the bell volume in Emacs running under X Windows? ! 1441: ! 1442: Under versions of Emacs before 18.58, the bell volume was annoying loud ! 1443: and difficult to turn off. So upgrading to 18.58 will reduce the volume. ! 1444: If you want to turn it off completely, use `xset'. There is no way to ! 1445: turn the bell off just for Emacs without affecting all other programs. ! 1446: ! 1447: Under Epoch you can do: ! 1448: ! 1449: (setq epoch::bell-volume 20) ! 1450: ! 1451: Stu Grossman <[email protected]> wrote a patch that allows the ! 1452: bell volume to be adjusted from inside Emacs just for Emacs. ! 1453: ! 1454: 48: How do I tell Emacs to automatically indent a new line to the ! 1455: indentation of the previous line? ! 1456: ! 1457: One solution is Indented Text Mode (M-x indented-text-mode). ! 1458: ! 1459: If you have Auto-Fill mode on (a minor mode, see question 32), you can ! 1460: tell Emacs to prefix every line with a certain character sequence, the ! 1461: "fill prefix". Type the prefix at the beginning of a line, position point ! 1462: after it, and then type "C-x ." (set-fill-prefix) to set the fill prefix. ! 1463: Thereafter, auto-filling will automatically put the fill prefix at the ! 1464: beginning of new lines, and M-q (fill-paragraph) will maintain any fill ! 1465: prefix when refilling the paragraph. ! 1466: ! 1467: NOTE: If you have paragraphs with different levels of indentation, you ! 1468: will have to set the fill prefix to the correct value each time you move ! 1469: to a new paragraph. To avoid this hassle, try one of the many packages ! 1470: available from the Emacs Lisp Archive. Look up `fill' and `indent' in the ! 1471: Lisp Code Directory for guidance. ! 1472: ! 1473: 49: How do I show which parenthesis matches the one I'm looking at? ! 1474: ! 1475: If you're looking at a right parenthesis (or brace or bracket) you can ! 1476: delete it and reinsert it. Emacs will blink the cursor on the matching ! 1477: parenthesis. ! 1478: ! 1479: M-C-f (forward-sexp) and M-C-b (backward-sexp) will skip over balanced ! 1480: parentheses, so you can see which parentheses match. (You can train it to ! 1481: skip over balanced brackets and braces at the same time by modifying the ! 1482: syntax table.) ! 1483: ! 1484: Here is some Emacs Lisp that will make the % key show the matching ! 1485: parenthesis, like in vi. In addition, if the cursor isn't over a ! 1486: parenthesis, it simply inserts a % like normal. ! 1487: ! 1488: ;; By an unknown contributor ! 1489: ! 1490: (global-set-key "%" 'match-paren) ! 1491: ! 1492: (defun match-paren (arg) ! 1493: "Go to the matching parenthesis if on parenthesis otherwise insert %." ! 1494: (interactive "p") ! 1495: (cond ((looking-at "\\s\(") (forward-list 1) (backward-char 1)) ! 1496: ((looking-at "\\s\)") (forward-char 1) (backward-list 1)) ! 1497: (t (self-insert-command (or arg 1))))) ! 1498: ! 1499: 50: In C mode, can I show just the lines that will be left after #ifdef ! 1500: commands are handled by the compiler? ! 1501: ! 1502: M-x hide-ifdef-mode. (This is a minor mode.) ! 1503: ! 1504: You may have to (load "hideif") first. If you want to do this regularly, ! 1505: put this in your .emacs file: ! 1506: ! 1507: (autoload 'hide-ifdef-mode "hideif" nil t) ! 1508: ! 1509: {Yes, I know, this should be in lisp/loaddefs.el already.} ! 1510: ! 1511: 51: Is there an equivalent to the `.' (dot) command of vi? ! 1512: ! 1513: (`.' is the redo command in vi. It redoes the last insertion/deletion.) ! 1514: ! 1515: No, not really. ! 1516: ! 1517: You can type "C-x ESC" (repeat-complex-command) to reinvoke commands that ! 1518: used the minibuffer to get arguments. In repeat-complex-command you can ! 1519: type M-p and M-n to scan through all the different complex commands you've ! 1520: typed. ! 1521: ! 1522: To repeat something on each line I recommend using keyboard macros. ! 1523: ! 1524: 52: What are the valid X resource settings (ie., stuff in .Xdefaults)? ! 1525: ! 1526: See the Emacs man page, or the etc/OPTIONS file. Ignore the information ! 1527: in etc/XDOC which is way out of date. ! 1528: ! 1529: 53: How do I execute a piece of Emacs Lisp code? ! 1530: ! 1531: There are a number of ways to execute (called "evaluate") an Emacs Lisp ! 1532: "form": ! 1533: ! 1534: * If you want it evaluated every time you run Emacs, put it in a file ! 1535: named `.emacs' in your home directory. ! 1536: ! 1537: * You can type the form in the *scratch* buffer, and then type LFD (or ! 1538: C-j) after it. The result of evaluating the form will be inserted in ! 1539: the buffer. ! 1540: ! 1541: * In Emacs-Lisp mode, typing M-C-x evaluates a top-level form before or ! 1542: around point. ! 1543: ! 1544: * Typing "C-x C-e" in any buffer evaluates the Lisp form immediately ! 1545: before point and prints its value in the echo area. ! 1546: ! 1547: * Typing M-ESC or M-x eval-expression allows you to type a Lisp form in ! 1548: the minibuffer which will be evaluated. ! 1549: ! 1550: * You can use M-x load-file to have Emacs evaluate all the Lisp forms in ! 1551: a file. (To do this from Lisp use the function `load' instead.) ! 1552: ! 1553: These functions are also used for evaluating Lisp forms: ! 1554: ! 1555: load-library, eval-region, eval-current-buffer, require, autoload ! 1556: ! 1557: 54: How do I change Emacs's idea of the tab character's length? ! 1558: ! 1559: Example: (setq default-tab-width 10). ! 1560: ! 1561: 55: How do I insert `>' at the beginning of every line? ! 1562: ! 1563: Type "M-x replace-regexp RET ^ RET > RET". ! 1564: ! 1565: To do this only in the region, type "C-x n M-x replace-regexp RET ^ RET ! 1566: > RET C-x w". ! 1567: ! 1568: WARNING: The command narrow-to-region (C-x n) is disabled by default ! 1569: because it can be very confusing (ie., "Oh no! Where did my file go?"). ! 1570: ! 1571: 56: How do I insert `_^H' before each character in a paragraph to get an ! 1572: underlined paragraph? ! 1573: ! 1574: M-x underline-region. ! 1575: ! 1576: 57: How do I repeat a command as many times as possible? ! 1577: ! 1578: Use "C-x (" and "C-x )" to make a keyboard macro that invokes the command ! 1579: and then type "M-0 C-x e". ! 1580: ! 1581: WARNING: any messages your command prints in the echo area will be ! 1582: suppressed. ! 1583: ! 1584: 58: How do I make Emacs behave like this: when I go up or down, the cursor ! 1585: should stay in the same column even if the line is too short? ! 1586: ! 1587: M-x picture-mode. (This is a minor mode, in theory anyway ...) ! 1588: ! 1589: 59: How do I tell Emacs to iconify itself? ! 1590: ! 1591: You need to modify C source and recompile. Either that or get Epoch or ! 1592: Lucid Emacs instead. Patches have been written by Robert Forsman ! 1593: <[email protected]> and Johan Vromans <[email protected]> to allow Emacs to ! 1594: iconify itself and by Matt Wette <[email protected]> and ! 1595: Manavendra K. Thakur <[email protected]> (for 18.57, plus icon ! 1596: geometry) to allow Emacs to start up iconified. I don't know which of ! 1597: these patches work together. ! 1598: ! 1599: Anonymous FTP: ! 1600: /csi.jpl.nasa.gov:pub/emacs.patch1 (Matt Wette) + ! 1601: /ftp.eu.net:gnu/emacs/FP-Xfun.Z (Johan Vromans) + ! 1602: /ftp.urc.tue.nl:pub/tex/emacs/FP-Xfun (Johan Vromans) + ! 1603: ! 1604: 60: How do I use regexps (regular expressions) in Emacs? ! 1605: ! 1606: See `Regexps' in the online manual. ! 1607: ! 1608: WARNING: The "or" operator is `\|', not `|', and the grouping operators ! 1609: are `\(' and `\)'. Also, the string syntax for a backslash is "\\". ! 1610: Thus, the string syntax for a regular expression like xxx\(foo\|bar\) is ! 1611: "xxx\\(foo\\|bar\\)". Notice the duplicated backslashes! ! 1612: ! 1613: WARNING: Unlike in Unix grep, sed, etc., a complement character set ! 1614: ([^...]) can match a newline character (LFD aka C-j aka \n), unless ! 1615: newline is mentioned as one of the characters not to match. ! 1616: ! 1617: WARNING: The character syntax regexps (eg. `\sw') are not meaningful ! 1618: inside character set regexps (eg. `[aeiou]'). (This is actually typical ! 1619: for regexp syntax.) ! 1620: ! 1621: 61: How do I perform a replace operation across more than one file? ! 1622: ! 1623: The "tags" feature of Emacs includes the command tags-query-replace which ! 1624: performs a query-replace across all the files mentioned in the TAGS file. ! 1625: See `Tags:Tags Search' in the online manual. ! 1626: ! 1627: In addition, Martin Boyer has written a package named global-replace which ! 1628: will perform a query-replace across all the files mentioned in the ! 1629: *compilation* buffer (usually done after a `grep'), which is available via ! 1630: anonymous FTP: ! ! 1631: ! ! 1632: /ireq-robot.hydro.qc.ca:pub/emacs/lisp/compile.el.Z ! ! 1633: /ireq-robot.hydro.qc.ca:pub/emacs/lisp/global-replace.el.Z ! ! 1634: /ireq-robot.hydro.qc.ca:pub/emacs/lisp/query.el.Z ! ! 1635: ! 1636: 62: Where is the documentation for `etags'? ! 1637: ! 1638: `etags' takes options just like a prior version of ctags, so your ctags ! 1639: manual (if any) may be useful. {Can someone send me the details on this?} ! 1640: ! 1641: ! 1642: ! 1643: Bugs/Problems ! 1644: ! 1645: 63: Does Emacs have problems with files larger than 8 megabytes? ! 1646: ! 1647: Most installed versions of GNU Emacs will use 24-bit signed integers (and ! 1648: 24-bit pointers) internally. This limits the file size that Emacs can ! 1649: handle to 8,388,607 bytes (2^23 - 1). ! 1650: ! 1651: Leonard N. Zubkoff <[email protected]> suggests putting the following two ! 1652: lines in src/config.h before compiling Emacs to allow for 26-bit integers ! 1653: and pointers (and thus filesizes of up to 33,554,431 bytes): ! 1654: ! 1655: #define VALBITS 26 ! 1656: #define GCTYPEBITS 5 ! 1657: ! 1658: WARNING: This method may result in `ILLEGAL DATATYPE' and other random ! 1659: errors on some machines. ! 1660: ! 1661: David Gillespie <[email protected]> gives an explanation of why ! 1662: Emacs uses 24 bit integers and pointers: ! 1663: ! 1664: Emacs is largely written in a dialect of Lisp; Lisp is a freely-typed ! 1665: language in the sense that you can put any value of any type into any ! 1666: variable, or return it from a function, and so on. So each value must ! 1667: carry a "tag" along with it identifying what kind of thing it is, eg., ! 1668: integer, pointer to a list, pointer to an editing buffer, and so on. ! 1669: Emacs uses standard 32-bit integers for data objects, taking the top 8 ! 1670: bits for the tag and the bottom 24 bits for the value. So integers (and ! 1671: pointers) are somewhat restricted compared to true C integers and ! 1672: pointers. ! 1673: ! 1674: Emacs uses 8-bit tags because that's a little faster on byte-oriented ! 1675: machines, but there are only really enough tags to require 6 bits. ! 1676: ! 1677: 64: Why can't Emacs find files in current directory on startup? ! 1678: ! 1679: Most likely, you have an environment variable named PWD that is set to a ! 1680: value other than the name of your current directory. This is most ! 1681: likely caused by using two different shell programs. `ksh' and (some ! 1682: versions of) `csh' set and maintain the value of the PWD environment ! 1683: variable, but `sh' doesn't. If you start sh from ksh, change your ! 1684: current directory inside sh, and then start Emacs from inside sh, PWD ! 1685: will have the wrong value but Emacs will use this value. See the ! 1686: etc/OPTIONS file for more details. ! 1687: ! 1688: Perhaps an easier solution is not to use two shells. The `chsh' program ! 1689: can often be used to change one's default login shell. ! 1690: ! 1691: You may have PWD set for other reasons. Another possibility is that you ! 1692: are setting default-directory from your .emacs file. ! 1693: ! 1694: Here is a fix by Jim Blandy <[email protected]>: ! 1695: ! 1696: >--- emacs/jjj/emacs-18.58/lisp/startup.el Tue Jan 15 23:19:04 1991 ! 1697: >+++ startup.el Mon Apr 20 00:21:01 1992 ! 1698: >@@ -81,5 +81,7 @@ ! 1699: > ;; In presence of symlinks, switch to cleaner form of default directory. ! 1700: > (if (and (not (eq system-type 'vax-vms)) ! 1701: >- (getenv "PWD")) ! 1702: >+ (getenv "PWD") ! 1703: >+ (equal (nthcdr 10 (file-attributes default-directory)) ! 1704: >+ (nthcdr 10 (file-attributes (getenv "PWD"))))) ! 1705: > (setq default-directory (file-name-as-directory (getenv "PWD")))) ! 1706: > (unwind-protect ! 1707: ! 1708: 65: How do I get rid of the ^M junk in my Shell buffer? ! 1709: ! 1710: For tcsh, put this in your `.cshrc' (or `.tcshrc') file: ! 1711: ! 1712: if ($?EMACS) then ! 1713: if ("$EMACS" == t) then ! 1714: if ($?tcsh) unset edit ! 1715: stty nl ! 1716: endif ! 1717: endif ! 1718: ! 1719: Or put this in your .emacs_tcsh file: ! 1720: ! 1721: unset edit ! 1722: stty nl ! 1723: ! 1724: Alternatively, use csh in your Shell buffers instead of tcsh. One way ! 1725: is: ! 1726: ! 1727: (setq explicit-shell-file-name "/bin/csh") ! 1728: ! 1729: and another is to do this in your .cshrc (or .tcshrc) file: ! 1730: ! 1731: setenv ESHELL /bin/csh ! 1732: ! 1733: (You must start Emacs over again with the environment variable properly ! 1734: set for this to take effect.) ! 1735: ! 1736: 66: Why do I get `Process shell exited abnormally with code 1'? ! 1737: ! 1738: The most likely reason for this message is that the `env' program is not ! 1739: properly installed. This program should be compiled (for the correct ! 1740: architecture!) and installed with execute permission for everyone in ! 1741: Emacs's program directory, which is normally /usr/local/emacs/etc. You ! 1742: can find what this directory is at your site by inspecting the value of ! 1743: the variable exec-directory by typing "C-h v exec-directory RET". `env' ! 1744: should also be for the correct architecture (check using `file' command). ! 1745: ! 1746: You should also check for other programs named `env' in your path (eg., ! 1747: SunOS has a program named /usr/bin/env). I don't understand why this can ! 1748: cause a failure and I don't know a general solution for working around the ! 1749: problem in this case. ! 1750: ! 1751: The `make clean' command will remove `env' and other vital programs, so be ! 1752: careful when using it. ! 1753: ! 1754: It has been reported that this sometimes happened when Emacs was started ! 1755: as an X client from an xterm window (ie. had a controlling tty) but the ! 1756: xterm was later terminated. ! 1757: ! 1758: See also etc/PROBLEMS for other possible causes of this message. ! 1759: ! 1760: 67: Why can't I cut from Emacs and paste in other X programs? ! 1761: ! 1762: Emacs stores things you "cut" in the X "cut buffers". It also pastes from ! 1763: the cut buffer `CUT_BUFFER0'. This is obsolete. Most modern X programs ! 1764: now expect to work with "selections" instead of cut buffers, although some ! 1765: like `xterm' will try to use the cut buffers if the selection is null. ! 1766: ! 1767: Emacs 18.58 contains a "fix" that makes xterm work by default. This ! 1768: "fix" is that Emacs clears the `PRIMARY' selection when it stores ! 1769: something in the cut buffer. By making the selection null, xterm will ! 1770: then fetch from the cut buffer when you try to paste. ! 1771: ! 1772: For versions of Emacs prior to 18.58, you can make pasting from Emacs into ! 1773: xterm work with the following X resources: ! 1774: ! 1775: ! Solution by Thomas Narten, should work under X11R3 and later GNU ! 1776: ! Emacs only copies to CUT_BUFFER0. xterm by default wants to paste ! 1777: ! from the PRIMARY selection. ! 1778: XTerm*VT100.Translations: #override \ ! 1779: ~Meta <Btn2Up>: insert-selection(CUT_BUFFER0,PRIMARY) ! 1780: ! 1781: You may have problems copying between Emacs and programs other than xterm ! 1782: that won't store cut text in the cut buffers or look in the cut buffers ! 1783: for text to paste (for backwards compatibility with obsolete applications ! 1784: like Emacs :-). The best workaround is to use the `xcutsel' program as an ! 1785: intermediary. - ! 1786: ! 1787: This problem does not exist for Epoch or Lucid Emacs. ! 1788: ! 1789: 68: Where is the termcap/terminfo entry for terminal type `emacs'? ! 1790: ! 1791: The termcap entry for terminal type `emacs' is ordinarily put in the ! 1792: TERMCAP environment variable of subshells. It may help in certain ! 1793: situations (eg., using rlogin from shell buffer) to add an entry for ! 1794: `emacs' to the system-wide termcap file. Here is a correct termcap entry ! 1795: for `emacs': ! 1796: ! 1797: emacs:tc=unknown: ! 1798: ! 1799: To make a terminfo entry for `emacs', use `tic' or `captoinfo'. You need ! 1800: to generate /usr/lib/terminfo/e/emacs. It may work to simply copy ! 1801: /usr/lib/terminfo/d/dumb to /usr/lib/terminfo/e/emacs. ! 1802: ! 1803: Having a termcap/terminfo entry will not enable the use of full screen ! 1804: programs in shell buffers. Use M-x terminal-emulator for that instead. ! 1805: ! 1806: A workaround to the problem of missing termcap/terminfo entries is to ! 1807: change terminal type `emacs' to type `dumb' or `unknown' in your shell ! 1808: start up file. `csh' users could put this in their .cshrc files: ! 1809: ! 1810: if ("$term" == emacs) set term=dumb ! 1811: ! 1812: 69: Why does Emacs spontaneously start displaying `I-search:' and beeping? ! 1813: ! 1814: Your terminal (or something between your terminal and the computer) is ! 1815: sending C-s and C-q for flow control, and Emacs is receiving these ! 1816: characters and interpreting them as commands. (The C-s character normally ! 1817: invokes the isearch-forward command.) For possible solutions, see ! 1818: question 131. ! 1819: ! 1820: 70: Why can't Emacs talk to certain hosts (or certain hostnames)? ! 1821: ! 1822: The problem may be that Emacs is linked with a wimpier version of ! 1823: gethostbyname than the rest of the programs on the machine. This is often ! 1824: manifested as a message on startup of `X server not responding. Check ! 1825: your DISPLAY environment variable.' or a message of `Unknown host' from ! 1826: open-network-stream. ! 1827: ! 1828: On a Sun, this may be because Emacs had to be linked with the static C ! 1829: library. The version of gethostbyname in the static C library may only ! 1830: look in /etc/hosts and the NIS (YP) maps, while the version in the dynamic ! 1831: C library may be smart enough to check DNS in addition to or instead of ! 1832: NIS. On a Motorola Delta running System V R3.6, the version of ! 1833: gethosbyname in the standard library works, but the one that works with ! 1834: NIS doesn't (the one you get with -linet). Other operating systems have ! 1835: similar problems. ! 1836: ! 1837: Try these options: ! 1838: ! 1839: * Explicitly add the host you want to communicate with to /etc/hosts. ! 1840: ! 1841: * Relink Emacs with this line in src/config.h: ! 1842: ! 1843: #define LIBS_SYSTEM -lresolv ! 1844: ! 1845: * Replace gethostbyname and friends in libc.a with more useful versions ! 1846: such as the ones in libresolv.a. Then relink Emacs. ! 1847: ! 1848: * If you are actually running NIS, make sure that `ypbind' is properly ! 1849: told to do DNS lookups with the correct command line switch. ! 1850: ! 1851: * Use tcp.el and tcp.c from GNUS. This has the additional advantage that ! 1852: you can use numeric IP addresses instead of names. open-network-stream ! 1853: currently can't handle numeric addresses. Brian Thomson ! 1854: <[email protected]> has a enhancement to open-network-stream to ! 1855: allow it to handle numeric addresses. ! 1856: ! 1857: 71: Why does Emacs say `Error in init file'? ! 1858: ! 1859: An error occurred while loading either your .emacs file or the system-wide ! 1860: lisp/default.el file. For information on how to debug your .emacs file, ! 1861: see question 29. ! 1862: ! 1863: It may be the case that you may need to load some package first, or use a ! 1864: hook that will be evaluated after the package is loaded. A common case of ! 1865: this is explained in question 127. ! 1866: ! 1867: 72: Why does Emacs ignore my X resources (my .Xdefaults file)? ! 1868: ! 1869: * Try compiling Emacs with the XBACKWARDS macro defined. There is a bug ! 1870: in some implementations of XGetDefault, which do not correspond to the ! 1871: documentation or the header files. ! 1872: ! 1873: * Make sure you are either using the class name of `Emacs' (oops, ! 1874: apparently this is buggy in Emacs 18.58!) or the correct instance name. ! 1875: The instance name is normally the same as the name of the file Emacs is ! 1876: in (ie., the last part of argv[0]), but this can be overridden by -rn ! 1877: command line option or the WM_RES_NAME environment variable. ! 1878: ! 1879: WARNING: Reports say using the class name fails in Emacs 18.58. ! 1880: ! 1881: WARNING: The advice the man page gives to use `emacs' is often wrong. ! 1882: ! 1883: WARNING: Older versions of Emacs got the class name wrong. ! 1884: ! 1885: * Emacs currently ignores the -xrm command line argument. ! 1886: ! 1887: * Emacs does not yet handle X11R5 screen-specific resources. ! 1888: ! 1889: * Emacs has a bug where it ignores color specifications if running on a ! 1890: 1-bit display (ie. a non-color display). ! 1891: ! 1892: * I don't think Emacs will use either of the application-specific resource ! 1893: files. Thus these environment variables don't affect it: XAPPLRESDIR, ! 1894: XUSERFILESEARCHPATH, XFILESEARCHPATH. {Correct?} ! 1895: ! 1896: 73: Why does Emacs take 20 seconds to visit a file? ! 1897: ! 1898: The usual cause is that the master lock file, `!!!SuperLock!!!' has been ! 1899: left in the lock directory somehow. Delete it. ! 1900: ! 1901: Mark Meuer <[email protected]> says that NeXT NFS has a bug where an ! 1902: exclusive create succeeds but returns an error status. This can cause the ! 1903: same problem. Since Emacs's file locking doesn't work over NFS anyway, ! 1904: the best solution is to recompile Emacs with CLASH_DETECTION undefined. ! 1905: ! 1906: 74: How do I edit a file with a `$' in its name? ! 1907: ! 1908: When entering a filename in the minibuffer, Emacs will attempt to expand ! 1909: a `$' followed by a word as an environment variable. To suppress this ! 1910: behavior, type "$$" instead. ! 1911: ! 1912: 75: Why does Shell mode lose track of the shell's current directory? ! 1913: ! 1914: Emacs has no way of knowing when the shell actually changes its directory. ! 1915: This is an intrinsic limitation of Unix. So it tries to guess by ! 1916: recognizing `cd' commands. If you type `cd' followed by a directory name ! 1917: with a variable reference (`cd $HOME/bin') or with a shell metacharacter ! 1918: (`cd ../lib*'), Emacs will fail to correctly guess the shell's new current ! 1919: directory. A huge variety of fixes and enhancements to Shell mode for ! 1920: this problem have been written to handle this problem. Check the Lisp ! 1921: Code Directory (see question 88). ! 1922: ! 1923: 76: Why doesn't my change to load-path work? ! 1924: ! 1925: If you added a directory name containing a tilde (~) to your load-path, ! 1926: expecting the tilde to be interpreted as your home directory, then you ! 1927: need to do something like this: ! 1928: ! 1929: (setq load-path (mapcar 'expand-file-name load-path)) ! 1930: ! 1931: 77: Why does the cursor always go to the wrong column when I move up or ! 1932: down one line? ! 1933: ! 1934: You have inadvertently typed "C-x C-n" (set-goal-column) which sets the ! 1935: "goal column" to the column where the cursor was. To undo this type ! 1936: "C-u C-x C-n". ! 1937: ! 1938: If you make this mistake frequently, you might want to unbind or disable ! 1939: this command by doing one of these two: ! 1940: ! 1941: (define-key ctl-x-map "\C-n" nil) ! 1942: (put 'set-goal-column 'disabled t) ! 1943: ! 1944: 78: Why does Emacs hang with message `Unknown XMenu error' with X11R4? ! 1945: ! 1946: Many different X errors can produce this message. Here is the solution ! 1947: to one problem: ! 1948: ! 1949: X11 Release 4 (and later, including OpenWindows) enforces some conditions ! 1950: in the X protocol that were previously allowed to pass unnoticed. You ! 1951: need to put the X11R4 server into X11R3 bug compatibility mode for Emacs's ! 1952: Xmenu code to work. You can do this with the command `xset bc'. ! 1953: ! 1954: 79: Why doesn't display-time show the load average in the mode line ! 1955: anymore? ! 1956: ! 1957: In GNU Emacs 18.56, a change was made in the display-time code. ! 1958: Formerly, in version 18.55, Emacs used a program named `loadst' to ! 1959: notify Emacs of the change in time every minute. loadst also sent Emacs ! 1960: the system load average if it was installed with sufficient privilege to ! 1961: get that information (or was on a system where no such privilege was ! 1962: needed). Emacs then displayed this information in the mode line. ! 1963: ! 1964: In version 18.56, this code was changed to use a program named `wakeup'. ! 1965: wakeup doesn't send Emacs any information, it's only purpose is to send ! 1966: Emacs *something* every minute, thus invoking the filter function in ! 1967: Emacs once a minute. The filter function in Emacs does all the work of ! 1968: finding the time, date, and load average. However, getting the load ! 1969: average requires the privilege to read kernel memory on most systems. ! 1970: Since giving Emacs this privilege would destroy any security a system ! 1971: might have, for almost everyone this is not an option. In addition, ! 1972: Emacs does not have the code built into it to get this information on ! 1973: the systems which have special system calls for this purpose, even ! 1974: though loadst had code for this. ! 1975: ! 1976: The solution I use is to get the files lisp/display-time.el and ! 1977: etc/loadst.c from version 18.55 and use those with 18.58. (I have heard ! 1978: a rumor that loadst disappeared because of the legal action Unipress ! 1979: threatened against IBM.) ! 1980: ! 1981: WARNING: Do not install Emacs setgid kmem unless you wish to destroy ! 1982: any security your system might have!!!!!!!!!! ! 1983: ! 1984: If you are using Emacs 18.55 or earlier, or already using the solution I ! 1985: describe above, read further: ! 1986: ! 1987: The most likely cause of the problem is that `loadst' can't read the ! 1988: special file /dev/kmem. To properly install loadst, it should be either ! 1989: setuid to the owner of /dev/kmem, or is should be setgid to the group to ! 1990: which /dev/kmem belongs. In either case, /dev/kmem should be readable by ! 1991: its owner or its group, respectively. Assuming the existence of a group ! 1992: named `kmem', here is an example of how to do this: ! 1993: ! 1994: chgrp kmem /dev/kmem ! 1995: chmod g+r /dev/kmem ! 1996: chgrp kmem /usr/local/emacs/etc/loadst ! 1997: chmod g+s /usr/local/emacs/etc/loadst ! 1998: ! 1999: Another possibility is that your version of Unix doesn't have the load ! 2000: average data available in /dev/kmem. Your version of Unix might have a ! 2001: special system call to retrieve this information (eg., inq_stats under ! 2002: UMAX), and loadst might not have been enhanced to cope with this. ! 2003: ! 2004: 80: Why does ispell sometimes ignore the local dictionary? ! 2005: ! 2006: You need to update the version of Ispell to 2.0.02. (Or you can switch to ! 2007: version 3.0 which is still in beta-testing.) A patch is available via ! 2008: anonymous FTP: ! ! 2009: ! ! 2010: /archive.cis.ohio-state.edu:pub/gnu/ispell/patch2.Z ! ! 2011: ! 2012: You also need to change a line in ispell.el from: ! 2013: ! 2014: (defconst ispell-version "2.0.01") ; Check against output of "ispell -v". ! 2015: ! 2016: to: ! 2017: ! 2018: (defconst ispell-version "2.0.02") ; Check against output of "ispell -v". ! 2019: ! 2020: 81: Why does Ispell treat each line as a single word? ! 2021: ! 2022: Ispell expects to get its input one word per line. The ispell filter, ! 2023: which is specified by the variables ispell-filter-hook and ! 2024: ispell-filter-hook-args, should output at most one word per line. ! 2025: ! 2026: 82: Are there any security risks in GNU Emacs? ! 2027: ! 2028: * the `movemail' incident (No, this is not a risk.) ! 2029: ! 2030: Cliff Stoll in his book `The Cuckoo's Egg' describes this in chapter 4. ! 2031: The site at LBL had installed the `etc/movemail' program setuid root. ! 2032: Since `movemail' had not been designed for this situation, a security ! 2033: hole was created and users could get root priveleges. ! 2034: ! 2035: `movemail' has since been changed so that even if it is installed setuid ! 2036: root this security hole will not be a result. ! 2037: ! 2038: I have heard unverified reports that the Internet worm took advantage of ! 2039: this configuration problem. ! 2040: ! 2041: * the file-local-variable feature (Yes, a risk, but easy to change.) ! 2042: ! 2043: There is an Emacs feature that allows the setting of local values for ! 2044: variables when editing a file by including specially formatted text near ! 2045: the end of the file. This feature also includes the ability to have ! 2046: arbitrary Emacs Lisp code evaluated when the file is visited. ! 2047: Obviously, there is a potential for Trojan horses to exploit this ! 2048: feature. ! 2049: ! 2050: If you set the variable inhibit-local-variables to a non-nil value, ! 2051: Emacs will display the special local variable settings of a file that ! 2052: you visit and ask you if you really want them. This variable is not ! 2053: mentioned in the manual. ! 2054: ! 2055: It is wise to do this in lisp/site-init.el before building Emacs: ! 2056: ! 2057: (setq inhibit-local-variables t) ! 2058: ! 2059: If Emacs has already been built, the expression can be put in ! 2060: lisp/default.el instead, or an individual can put it in their own .emacs ! 2061: file. ! 2062: ! 2063: The ability to exploit this feature by sending e-mail to an RMAIL user ! 2064: was fixed sometime after Emacs 18.52. However, any new package that ! 2065: uses find-file or find-file-noselect has to be careful about this. ! 2066: ! 2067: For more information, see `File Variables' in the online manual (which, ! 2068: incidentally, does not describe how to disable the feature). ! 2069: ! 2070: There is a new variable in Emacs 18.58 named ignore-local-eval which ! 2071: turns out to be useless as currently implemented. Ignore it. ! 2072: ! 2073: * synthetic X events (Yes, a risk, use MIT-MAGIC-COOKIE-1 or better.) ! 2074: ! 2075: Emacs accepts synthetic X events generated by the SendEvent request as ! 2076: though they were regular events. As a result, if you are using the ! 2077: trivial host-based authentication, other users who can open X ! 2078: connections to your X workstatation can make your Emacs process do ! 2079: anything, including run other processes with your priveleges. ! 2080: ! 2081: The only fix for this is to prevent other users from being able to open ! 2082: X connections. The standard way to prevent this is to use a real ! 2083: authentication mechanism, such as MIT-MAGIC-COOKIE-1. If using the ! 2084: `xauth' program has any effect, then you are probably using ! 2085: MIT-MAGIC-COOKIE-1. Your site may be using a superior authentication ! 2086: method; ask your system administrator. ! 2087: ! 2088: If real authentication is not a possibility, you may be satisfied by ! 2089: just allowing hosts access for brief intervals while you start your X ! 2090: programs, then removing the access. This reduces the risk somewhat by ! 2091: narrowing the time window when hostile users would have access, but DOES ! 2092: NOT ELIMINATE THE RISK. ! 2093: ! 2094: Lucid GNU Emacs does not accept synthetic X events unless you set a + ! 2095: variable. + ! 2096: ! 2097: * autosave file permissions (Yes, a risk, hard to work around.) ! 2098: ! 2099: The file permissions for autosave files are determined solely by the ! 2100: Emacs process's `umask' value. The permissions of the file being ! 2101: autosaved are not used. The easiest workaround is to keep sensitive ! 2102: files in protected directories. Sebastian Kremer has written an ! 2103: enhanced version of the autosave file name picking code that can avoid ! 2104: this problem by keeping autosave files in a protected directory. {FTP ! 2105: information please?} This problem will be fixed in Emacs 19. ! 2106: ! 2107: ! 2108: ! 2109: Difficulties Building/Installing/Porting Emacs ! 2110: ! 2111: 83: What should I do if I have trouble building Emacs? ! 2112: ! 2113: First look in the file etc/PROBLEMS to see if there is already a solution ! 2114: for your problem. Next check the FAQ (you're reading it). If you don't ! 2115: find a solution, then report your problem via e-mail to ! 2116: [email protected]. Please do not post it to gnu.emacs.help or ! 2117: e-mail it to [email protected]. For further guidelines, see ! 2118: question 8. ! 2119: ! 2120: 84: How do I stop Emacs from failing when the executable is stripped? ! 2121: ! 2122: Don't do that. ! 2123: ! 2124: This problem has been reported on SGI Indigo machines running Irix 4.0.* ! 2125: and RS/6000 machines. Scott Henry <[email protected]> posted a ! 2126: patch that fixes the problem for Irix. ! 2127: ! 2128: 85: Why does linking Emacs with -lX11 fail? ! ! 2129: ! ! 2130: Emacs needs to be linked with the static version of the X11 library, ! ! 2131: libX11.a. This may be missing. ! ! 2132: ! ! 2133: Under OpenWindows, you may need to use `add_services' to add the ! ! 2134: `OpenWindows Programmers' optional software category from the CD-ROM. - ! 2135: ! 2136: Under HP-UX 8.0, you may need to run `update' again to load the - ! 2137: X11-PRG `fileset'. This may be missing even if you specified `all ! 2138: filesets' the first time. If libcurses.a is missing, you may need to load ! 2139: the `Berkeley Development Option' {???}. ! 2140: ! 2141: If you are building the MIT X11 sources, you may need to modify your + ! 2142: `site.cf' file to get static versions of the libraries. (Info from David + ! 2143: Zuhn <[email protected]>.) + ! 2144: + ! 2145: Other systems may have similar problems. You can always define + ! 2146: CANNOT_DUMP and link with the shared libraries instead. ! 2147: ! 2148: To get the Xmenu stuff to work, you need to find a copy of MIT's + ! 2149: liboldX.a. + ! 2150: ! 2151: 86: Why does Emacs 18.55 say `Fatal error (6).Abort' under SunOS 4.1? ! 2152: ! 2153: I had hoped this question would go away after Emacs 18.57 was released, ! 2154: but people continue to compile 18.55. Easiest solution: upgrade. ! 2155: ! 2156: This is a result of the SunOS localtime/tzsetwall malloc bug, which was ! 2157: (finally!) fixed in SunOS 4.1.2. If you actually need the full ! 2158: explanation, send me e-mail. If you absolutely must compile Emacs 18.55 ! 2159: (eg., you are compiling Nemacs), the easiest workaround was to put ! 2160: `#define SYSTEM_MALLOC' in src/config.h. - ! 2161: ! 2162: GNU Emacs FAQ: Getting Emacs/Packages ! 2163: ! 2164: If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to ! 2165: get an overview of just the questions. Then, when you want to look at the text ! 2166: of the answers, just type "C-x $". ! 2167: ! 2168: To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if ! 2169: that doesn't work, then type ESC to end the search. ! 2170: ! 2171: A `+' in the 78th column means something was inserted on the line. A `-' means ! 2172: something was deleted and a `!' means some combination of insertions and ! 2173: deletions occurred. ! 2174: ! 2175: Full instructions for getting the latest FAQ are in question 22. Also see the ! 2176: `Introduction to news.answers' posting in the `news.answers' newsgroup, or send ! 2177: e-mail to `[email protected]' with `help' on a body line, or use FTP, ! 2178: WAIS, or Prospero to rtfm.mit.edu. ! 2179: ! 2180: ! 2181: ! 2182: Finding/Getting Emacs and Related Packages ! 2183: ! 2184: 87: Where can I get GNU Emacs on the net (or by snail mail)? ! 2185: ! 2186: Look in the files etc/DISTRIB and etc/FTP for information on nearby ! 2187: archive sites. If you don't already have GNU Emacs, see question 20 ! 2188: for how to get these two files. ! 2189: ! 2190: The latest version is always available via anonymous FTP at MIT: ! ! 2191: ! ! 2192: /prep.ai.mit.edu:pub/gnu/emacs-18.58.tar.Z ! ! 2193: ! 2194: See question 91. ! 2195: ! 2196: 88: How do I find a GNU Emacs Lisp package that does XXX? ! 2197: ! 2198: A listing of Emacs Lisp packages, called the Lisp Code Directory, is being ! 2199: maintained by Dave Brennan <[email protected]> and Dave Sill <[email protected]>. ! 2200: You can search through this list to find if someone has written something ! 2201: that fits your needs. ! 2202: ! 2203: This list is file LCD-datafile.Z in the Emacs Lisp Archive. (See ! 2204: question 89 for methods for getting this file.) The files lispdir.el.Z ! 2205: and lispdir.doc.Z in the archive contain information to help you use the ! 2206: list. Once you have installed lispdir.el and LCD-datafile, then you can ! 2207: use the "M-x lisp-dir-apropos" command to look things up in the database. ! 2208: For example, the command "M-x lisp-dir-apropos RET ange-ftp RET" produces ! 2209: this (outdated) output: ! 2210: ! 2211: GNU Emacs Lisp Code Apropos -- "ange-ftp" ! 2212: ! 2213: ange-ftp (3.112) 91-08-12 ! 2214: Andy Norman, <[email protected]> ! 2215: archive.cis.ohio-state.edu: ! 2216: /pub/gnu/emacs/elisp-archive/as-is/ange-ftp.el.Z ! 2217: transparent FTP Support for GNU Emacs ! 2218: ! 2219: 89: Where can I get GNU Emacs Lisp packages that don't come with Emacs? ! 2220: ! 2221: First, check the Lisp Code Directory to find the name of the package you ! 2222: are looking for. (See question 88). Then check local archives and ! 2223: the Emacs Lisp Archive to find a copy of the relevant files. Then, if ! 2224: you still haven't found it, you can send e-mail to the author asking for ! 2225: a copy. ! 2226: ! 2227: You can access the Emacs Lisp Archive via anonymous FTP: ! ! 2228: ! ! 2229: /archive.cis.ohio-state.edu:/pub/gnu/emacs/elisp-archive/ ! ! 2230: ! 2231: Fetch the file README first. ! 2232: ! 2233: NOTE: The archive maintainers do not have time to answer individual ! 2234: requests for packages or the list of packages in the archive. If you ! 2235: cannot use FTP or UUCP to access the archive yourself, try to find a ! 2236: friend who can, but please don't ask the maintainers. ! 2237: ! 2238: NOTE: Any files with names ending in `.Z' are compressed, and you should ! 2239: use `binary' mode in FTP to retrieve them. You should also use binary ! 2240: mode whenever you retrieve any files with names ending in `.elc'. ! 2241: ! 2242: 90: How do I submit code to the Emacs Lisp Archive? ! 2243: ! 2244: Submissions should be mailed to [email protected]. The ! 2245: lispdir.el package has a function named submit-lcd-entry which will help ! 2246: you with this. Mail messages (submissions) are automatically saved and ! 2247: periodically archived. Urgent mail may be sent directly to Dave Sill ! 2248: <[email protected]> or Dave Brennan <[email protected]> or should contain the ! 2249: string `urgent' in the subject. The incoming ftp directory is no longer ! 2250: available at the request of Ohio State. {Is this still true?} ! 2251: ! 2252: However, if someone has a submission with multiple files (which would be ! 2253: archived as a tar file) or binary files, then FTP transfer is preferred ! 2254: and can be arranged via an anonymous FTP site. This is faster than ! 2255: uudecoding, unsharing, etc., and re-packaging files. ! 2256: ! 2257: Before submitting anything, please read the file guidelines.Z, which is ! 2258: available in the archive. Whenever possible, submissions should contain a ! 2259: complete LCD entry since this helps reduce administrative overhead for the ! 2260: maintainers. You can include an entry in this format: ! 2261: ! 2262: ;; LCD Archive Entry: ! 2263: ;; package name|author's name|email address ! 2264: ;; |description ! 2265: ;; |date|version|archive path ! 2266: ! 2267: For example: ! 2268: ! 2269: ;; LCD Archive Entry: ! 2270: ;; tex-complete|Sebastian Kremer|[email protected] ! 2271: ;; |Minibuffer name completion for editing [La]TeX. ! 2272: ;; |91-03-26|$Revision: 1.12 $|~/packages/tex-complete.el.Z ! 2273: ! 2274: Dave Brennan has software which automatically looks for data in this ! 2275: format. The format is fairly flexible. The entry ends when a line is ! 2276: reached with a different prefix or the seventh field terminator is ! 2277: seen. ! 2278: ! 2279: If you are submitting a multi-file submission you should include a file ! 2280: named "LCD-entry" which contains the archive entry, instead of placing ! 2281: it in one or more of the individual files. ! 2282: ! 2283: 91: Where can I get other up-to-date GNU stuff? ! 2284: ! 2285: The most up-to-date official GNU stuff is normally kept on prep.ai.mit.edu ! 2286: and is available for anonymous FTP in the pub/gnu directory. See the ! 2287: files etc/DISTRIB and etc/FTP for more information. (To get copies of ! 2288: these files, see question 20.) ! 2289: ! 2290: The following sites are all mirror images of the GNU distribution area: ! 2291: ! 2292: /prep.ai.mit.edu:pub/gnu/ + ! 2293: /ftp.uu.net:packages/gnu/ + ! 2294: /src.doc.ic.ac.uk:gnu/ (available via FTP, NIFTP, FTAM) + ! 2295: /ftp.win.tue.nl:pub/gnu/ ! ! 2296: /utsun.s.u-tokyo.ac.jp:ftpsync/prep/ + ! 2297: /nic.funet.fi:pub/gnu/ + ! 2298: ! 2299: The directory at ftp.uu.net is a mirror of prep.ai.mit.edu:pub/gnu, ! 2300: except that files larger than 1 megabyte {right?} are automatically ! 2301: split into multiple parts. If you have trouble transferring large ! 2302: files, you should try here. A file normally named `XXX' is split into ! 2303: files XXX-split/part[0-9][0-9], and there will be a file named ! 2304: XXX-split/README which contains the list of parts (especially helpful ! 2305: when FTP-ing by e-mail), their checksums, and reassembly instructions. ! 2306: Some of the other mirror sites may have the same property. {Can someone ! 2307: check this out? Thanks!} ! 2308: ! 2309: Information was provided by Lee McLoughlin <[email protected]>, Jonathan ! 2310: R. Ferro <[email protected]>, Arjan de Vet <[email protected]>, and - ! 2311: Simon Marshall <[email protected]>. ! 2312: ! 2313: 92: Where can I get an Emacs with better mouse and X window support? ! 2314: ! 2315: Emacs 18 has some limited X Window System support, but there are ! 2316: problems. Emacs 19 will have amazing mouse and window support. Right ! 2317: now, there are Epoch which is derived from GNU Emacs 18.58 and Lucid GNU ! 2318: Emacs which is derived from an early unreleased version of GNU Emacs 19, ! 2319: both of which have greatly improved mouse and window support. See ! 2320: questions 120 and 121. ! 2321: ! 2322: The HP unofficial GNU Emacs also has nice mouse support. See question ! 2323: 95. ! 2324: ! 2325: There are numerous Emacs Lisp packages that have been written to extend ! 2326: Emacs 18's mouse handling capabilities. Some of these packages also have ! 2327: patches to the C code to provide enhanced capabilities. Look up `mouse' ! 2328: in the Lisp Code Directory (see question 88). ! 2329: ! 2330: There is a package called BAM (Born Again Menus) which provides menus for + ! 2331: GNU Emacs via an external C program. It does not provide mouse support in + ! 2332: the Emacs window such as scrollbars, cut-and-paste, etc. + ! 2333: ! 2334: NOTE: Epoch only works with the X Window System; it works on ordinary ! 2335: terminals by invoking regular GNU Emacs. Lucid Emacs does not currently ! 2336: work on ordinary terminals, although there are plans to fix this. ! 2337: ! 2338: 93: What is the difference between GNU Emacs and Epoch? ! 2339: ! 2340: Marc Andreessen <[email protected]> writes: ! 2341: ! 2342: Epoch is GNU Emacs on steroids: an adaptation of GNU Emacs with lots of ! 2343: additional support for features made possible by the X11 windowing ! 2344: system. These features include multiple editing windows, arbitrary ! 2345: colors and fonts (fixed-width and proportional), selectable zones per ! 2346: buffer with arbitrary display styles (font, color, underline, stipple, ! 2347: pixmap), an optional separate minibuffer window, improved keyboard and ! 2348: mouse handling, full 8-bit character set support, and more. ! 2349: ! 2350: 94: What is the difference between GNU Emacs and Lucid GNU Emacs? ! 2351: ! 2352: This information is condensed from the release notice: ! 2353: ! 2354: Lucid GNU Emacs is based on an early version of GNU Emacs version 19 ! 2355: with many enhancements. It currently requires X Windows to run. For ! 2356: information on where to get Lucid GNU Emacs see 121. X Windows support ! 2357: is greatly enhanced over GNU Emacs version 18, including support for ! 2358: multiple X Windows (a.k.a. screens in Emacs), Zmacs/Lispm style region ! 2359: highlighting, a customizable, Motif-like menubar, more powerful keymap ! 2360: support (allowing different actions to be associated with Backspace, ! 2361: Control-h, etc.), flexible text attribute (e.g. font, color) support on ! 2362: regional and screen-local basis through X resources and/or lisp, and ! 2363: support for the X11 selection mechanism. Some other features include ! 2364: run-time computation of the load-path, support for floating point ! 2365: numbers, native timer support, and sound file support on Sun ! 2366: SPARCstations. To build Lucid GNU Emacs, an ANSI C compiler (e.g. gcc) ! 2367: is required. ! 2368: ! 2369: 95: Where can I get the "unofficial HP GNU Emacs"? ! 2370: ! 2371: The unofficial HP GNU Emacs is available via anonymous FTP: ! ! 2372: ! ! 2373: /me10.lbl.gov:pub/interex/HUGE/ ! ! 2374: /ee.utah.edu:HUGE/ (PLEASE FTP DURING NON-WORK HOURS!!!) ! ! 2375: ! 2376: and takes about 35 megabytes of disk space to build. It is useful for ! 2377: non-HP machines, but some of the added features will only work under ! 2378: HP-UX. ! 2379: ! 2380: You will need to get patches to work with HP-UX 8.0 or on 700 series ! 2381: machines via e-mail from Darryl Okahata <[email protected]>. ! 2382: ! 2383: 96: Where can I get Emacs for my PC running MS-DOS? ! 2384: ! 2385: * Demacs ! 2386: ! 2387: For 386 or 486 PCs running MS-DOS, there is a version of GNU Emacs ! 2388: called Demacs. To get Demacs see question 122. ! 2389: ! 2390: From the announcement message: ! 2391: ! 2392: Demacs is almost a full set of GNU Emacs but does not support some ! 2393: features: asynchronous process, locking a file, etc. ! 2394: ! 2395: Demacs provides following DOS specific features: ! 2396: ! 2397: * File type: text or binary file translation. ! 2398: * "8-bit clean" display mode. ! 2399: * 8086 software interrupt call by int86 lisp function. ! 2400: * Machine specific features such as function key support. ! 2401: * File name completion with drive name. ! 2402: * Child process (suspend-emacs, call-process). ! 2403: * Enhanced dired mode which can work without 'ls.exe'. ! 2404: ! 2405: To our regret `shell-mode' does not work, but `compile' command works ! 2406: properly. ! 2407: ! 2408: Demacs was developed using an MS-DOS version of gcc called djgpp by ! 2409: D. J. Delorie <[email protected]> which can compile and run large programs ! 2410: under MS-DOS, but not under MS Windows. Demacs was derived from Nemacs ! 2411: rather than straight from GNU Emacs. ! 2412: ! 2413: There are a variety of other Emacses for MS-DOS including among them the ! 2414: following. ! 2415: ! 2416: * Freemacs ! 2417: ! 2418: Russ Nelson <[email protected]>, the author, describes ! 2419: Freemacs: ! 2420: ! 2421: * Freemacs is free, and it was designed from the start to be ! 2422: programmable. ! 2423: * Freemacs is the only IBM-PC editor that tries to be like GNU Emacs. ! 2424: * Freemacs can only edit files less than 64K in length. ! 2425: * Freemacs doesn't have undo. ! 2426: ! 2427: Carl Witty <[email protected]> reviews Freemacs: ! 2428: ! 2429: Better is Freemacs, which follows the tradition of ITS and GNU Emacs ! 2430: by having an full, turing-complete extension language which is ! 2431: incompatible with everything else. In fact, it's even closer to ITS ! 2432: Emacs than GNU Emacs is, because Mint (Freemacs' extension language) ! 2433: is absolutely illegible without weeks of study, much like TECO. ! 2434: ! 2435: To get Freemacs see question 123. ! 2436: ! 2437: * MicroEmacs ! 2438: ! 2439: MicroEmacs is a descendant of Microemacs {originally by Dave Conroy?}. ! 2440: It is programmable in a BASIC-like language. Many of the keybindings ! 2441: are different from GNU Emacs. It is rumored that MicroEmacs can not ! 2442: correctly edit files larger than memory. The author is Daniel Lawrence ! 2443: <[email protected], [email protected], [email protected]>. The ! 2444: latest version is 3.10 and it is available via anonymous FTP: ! ! 2445: ! ! 2446: /midas.mgmt.purdue.edu: (non-working hours only) ! ! 2447: /durer.cme.nist.gov: ! ! 2448: /wuarchive.wustl.edu:/mirrors/msdos/memacs/ ! ! 2449: ! 2450: Version 3.11 is in beta test. ! 2451: ! 2452: * JOVE ! 2453: ! 2454: Another Emacs for small machines is JOVE (Jonathan's Own Version of ! 2455: Emacs). The latest official version is 4.14. There appears to be a ! 2456: newer version. People rumored to be working on JOVE include Mark Moraes ! 2457: <[email protected]> and Bill Marsh <[email protected]>. It is ! 2458: available via anonymous FTP: ! ! 2459: ! ! 2460: /cs.rochester.edu:/pub/jove.tar.4.14.Z ! ! 2461: /cs.toronto.edu:/pub/moraes/jove4.14.3.tar.Z ! ! 2462: /ftp.uu.net: ! ! 2463: ! 2464: * MG ! 2465: ! 2466: MG is another descendant of Microemacs. MG used to stand for ! 2467: MicroGNUEmacs, but now just stands for MG. The look-and-feel of MG is ! 2468: intended to be close to that of GNU Emacs. It is rumored that MG can ! 2469: not correctly edit files larger than memory. The current version is ! 2470: rumored to be 2. There is a version 3 in beta which works on the Amiga. ! 2471: It is also available via anonymous FTP: ! ! 2472: ! ! 2473: /ftp.white.toronto.edu:pub/mg/ ! ! 2474: /wuarchive.wustl.edu:/mirrors/unix-c/editors/ ! ! 2475: /procyon.cis.ksu.edu: (source and executable) ! ! 2476: ! 2477: 97: Where can I get Emacs for my PC running Windows? ! 2478: ! 2479: I believe that no version of GNU Emacs runs under Windows. Pierre Perret ! 2480: <[email protected]> has ported MicroEMACS 3.11c to Windows. ! 2481: ! 2482: Anonymous FTP: ! 2483: /ftp.cica.indiana.edu:pub/pc/win3/util/mewin10.zip ! ! 2484: /ftp.cica.indiana.edu:pub/pc/win3/util/mewin10s.zip ! ! 2485: /ftp.cica.indiana.edu:pub/pc/win3/util/mewri.zip ! ! 2486: ! 2487: 98: Where can I get Emacs for my PC running OS/2? ! 2488: ! 2489: From the OS/2 Programmer's FAQ: ! ! 2490: ! ! 2491: GNU Emacs 18.58 is available. It requires you to have EMX installed ! ! 2492: on your machine, but it comes with all the EMX files you will need. ! ! 2493: Emacs is available on ftp-os2 in /pub/os2/2.0/gnu/emacs. (If you want ! ! 2494: to recompile emacs, you will need the full EMX distribution see ! ! 2495: question 1.2.) ! ! 2496: ! ! 2497: The above quote may be out of date. See the latest OS/2 Programmer's FAQ ! ! 2498: {perhaps in comp.os.os2.misc?} for the latest news. Anonymous FTP info: ! ! 2499: ! ! 2500: /ftp-os2.nmsu.edu:pub/os2/2.0/gnu/emacs/ ! ! 2501: ("ftp-os2" was formerly named "hobbes") ! ! 2502: ! ! 2503: Thanks go to Stephen Simpson <[email protected]>, Jonathan ! ! 2504: Miller <[email protected]>, Terry Kane <[email protected]>, J. D. ! ! 2505: Baldwin <[email protected]>, and Ken Bass ! ! 2506: <[email protected]>. ! ! 2507: ! 2508: 99: Where can I get Emacs for my Atari ST? ! 2509: ! 2510: Emacs 18.57 is the latest version for TOS. Stefan Mueller-Pfeiffer ! 2511: <[email protected]> says: ! 2512: ! 2513: There is also a version for MiNT, the multitasking enhancement for ! 2514: ATARI's TOS, which behaves almost like EMACS on a "real computer". This ! 2515: port was done by Erling Henanger <[email protected]>. ! 2516: ! 2517: Anonymous FTP: ! 2518: /atari.archive.umich.edu:atari/gnustuff/tos/ (TOS Emacs 18.57) + ! 2519: /atari.archive.umich.edu:atari/new/mntemacs.zoo (MiNT Emacs) + ! 2520: /cs.uni-sb.de:/pub/atari/emacs/ + ! 2521: ! 2522: 100: Where can I get Emacs for my Amiga? ! 2523: ! 2524: All of the files are lharc-ed. ! 2525: ! 2526: Anonymous FTP: ! 2527: /oes.orst.edu:/pub/almanac/comp/amiga/software/gnuemacs-1.10/ ! ! 2528: ! 2529: Via e-mail: ! 2530: To: [email protected] - ! 2531: body: ! 2532: mode uuencode ! 2533: send computer amiga software gnuemacs <file> ! 2534: <file> is replaced by one of the following: ! 2535: Required: d1.lzh d2.lzh ! 2536: Recommended: d3_info.lzh d3_infolisp.lzh ! 2537: Optional: d3_autoloaded.lzh d3_entertainmentetc.lzh ! 2538: d3_entertainmentlisp.lzh d4_src.lzh d5_languagelisp.lzh ! 2539: d5_viclone.lzh d6_gnulibsrc.lzh d6_mailpackage.lzh ! 2540: d6_mathpackage.lzh d6_misc.lzh d6_textformat.lzh ! 2541: The `d#' at the beginning of each file is its disk number, which is ! 2542: referred to by the documentation. ! 2543: ! 2544: 101: Where can I get Emacs for my Apple computer? ! 2545: ! 2546: The FSF is a participant in a boycott of Apple because of Apple's "look ! 2547: and feel" copyright suits. See the file etc/APPLE for more details. ! 2548: Because of this boycott, the FSF doesn't include support in GNU software ! 2549: for Apple computers such as the Macintosh. ! 2550: ! 2551: Please don't help people port or develop software for Apple computers. ! 2552: ! 2553: 102: Where can I get Emacs with NeWS support? ! 2554: ! 2555: Chris Maio's NeWS support package for GNU Emacs is available via anonymous ! 2556: FTP: ! ! 2557: ! ! 2558: /columbia.edu:pub/ps-emacs.tar.Z ! ! 2559: /archive.cis.ohio-state.edu:pub/gnu/emacs/ps-emacs.tar.Z ! ! 2560: ! 2561: and via e-mail: ! ! 2562: ! 2563: To: [email protected] ! 2564: body: send NeWS emacs-support ! ! 2565: ! 2566: 103: Where do I get Emacs that runs on VMS under DECwindows? ! 2567: ! 2568: Hal R. Brand <[email protected]> is said to have a VMS save set with a ! 2569: ready-to-run VMS version of Emacs 18.55 for X Windows. It is available ! 2570: via anonymous FTP (addvax.llnl.gov). It is possible that the VMS versions ! 2571: of Emacs at other sites have X support compiled in. See etc/FTP for ! 2572: locations. ! 2573: ! 2574: Johan Vromans <[email protected]> writes: ! 2575: ! 2576: Getting Emacs to run on VMS with DECwindows requires a number of changes ! 2577: to the sources. Fortunately this has been done already. Joshua Marantz ! 2578: <[email protected]> did most of the work for Emacs 18.52, and the mods ! 2579: were ported to 18.55 by Johan Vromans <[email protected]>. Also included is the ! 2580: handling of DEC's LK201 keyboard. You need to apply the changes to a ! 2581: fresh Emacs 18.55 distribution on a Unix system, and then you can copy ! 2582: the sources to VMS to perform the compile/link/build. ! 2583: ! 2584: The set of changes have been posted a number of times three times the ! 2585: last 12 months, so they should be widely available. ! 2586: ! 2587: Richard Levitte <[email protected]> tells us that there are patches for + ! 2588: Emacs 18.57 and 18.58 available via e-mail: + ! 2589: + ! 2590: To: [email protected] + ! 2591: body: SEND EMACS-1857-PATCHES + ! 2592: or: SEND EMACS-1858-PATCHES + ! 2593: ! 2594: 104: Where can I get modes for Lex, Yacc/Bison, Bourne Shell, Csh, C++, ! 2595: Objective C, Pascal, Awk? ! 2596: ! 2597: As usual, look in the Lisp Code Directory (see question 88). For C++, ! 2598: if you use lisp-dir-apropos, you must specify the pattern like this: ! 2599: ! 2600: M-x lisp-dir-apropos RET c\+\+ RET ! 2601: ! 2602: 105: What is the IP address of XXX.YYY.ZZZ? ! 2603: ! 2604: If you are at a site with a deficient nameserver, you may need to know ! 2605: the IP address of a host to FTP files from it. You can get this ! 2606: information in two ways: - ! 2607: ! 2608: * By telnet: ! 2609: ! 2610: telnet nic.ddn.mil hostnames (or `telnet 192.112.36.5 101') ! 2611: hname XXX.YYY.ZZZ - ! 2612: ! 2613: * By e-mail: ! 2614: ! 2615: To: [email protected] ! 2616: Subject: host XXX.YYY.ZZZ ! 2617: or: whois XXX.YYY.ZZZ ! 2618: or: help ! 2619: ! 2620: or: + ! 2621: + ! 2622: To: [email protected] + ! 2623: body: site XXX.YYY.ZZZ + ! 2624: + ! 2625: Information from Brendan Kehoe <[email protected]>. + ! 2626: ! 2627: ! 2628: ! 2629: ! 2630: Major Emacs Lisp Packages, Emacs Extensions, and Related Programs ! 2631: ! 2632: This section lists version numbers, FTP sites, mailing lists, newsgroups, ! 2633: and other information for many important packages, extensions, and related ! 2634: programs. There is some overlap with the Lisp Code Directory, but these ! 2635: entries give more detailed information. ! 2636: ! 2637: If you know of any other packages that are so substantial that they ! 2638: deserve to be mentioned here, please tell me. Having its own mailing list ! 2639: or newsgroup or more than half a megabyte of source code are good signs. ! 2640: ! 2641: 106: VM (View Mail) -- another mail reader within Emacs ! 2642: ! 2643: Author: Kyle Jones <[email protected]> ! 2644: Latest released version: 4.41 ! 2645: Beta test version: 5.32 ! 2646: Anonymous FTP: ! 2647: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/vm-4.41.tar.Z ! ! 2648: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/as-is/timer.shar.Z ! ! 2649: /ftp.uu.net:mail/vm-4.41.tar.Z ! ! 2650: /ftp.uu.net:mail/vm-5.32beta.tar.Z + ! 2651: Newsgroups and mailing lists: ! 2652: Info-VM: ! 2653: gnu.emacs.vm.info ! 2654: [email protected] (for subscriptions) ! 2655: [email protected] (for submissions) ! 2656: Bug-VM: ! 2657: gnu.emacs.vm.bug ! 2658: [email protected] (for subscriptions) ! 2659: [email protected] (for submissions) ! 2660: ! 2661: 107: Supercite -- mail and news citation package within Emacs ! 2662: ! 2663: Author: Barry Warsaw <[email protected]> ! 2664: Mailing list: [email protected] (for subscriptions) ! 2665: [email protected] (for submissions) ! 2666: Latest version: 2.2 ! 2667: Anonymous FTP: ! 2668: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/sc-2.2.tar.Z ! ! 2669: /ftp.cme.nist.gov:pub/gnu/sc2.2.tar.Z + ! 2670: Via e-mail: ! 2671: To: [email protected] ! 2672: Subject: help ! 2673: NOTE: Superyank is an old version of Supercite. ! 2674: ! 2675: 108: GNUS -- news reader within Emacs ! 2676: ! 2677: Author: Masanobu Umeda <[email protected]> ! 2678: Latest official version: 3.13 ! 2679: Unofficial test version: 3.14.1 ! 2680: Anonymous FTP: ! 2681: /cs.umn.edu:pub/gnu/emacs/gnus-3.14.1.tar.Z. + ! 2682: /aun.uninett.no:pub/gnus-3.14.1.tar.Z + ! 2683: /wnoc-fuk.wide.ad.jp:pub/GNU/etc/gnus-3.14.1.tar.Z + ! 2684: /liasun3.epfl.ch:pub/gnu/emacs/gnus-3.14.1.tar.Z + ! 2685: /aix370.rrz.uni-koeln.de:/pub/gnu/emacs/gnus-3.14.1.tar.Z + ! 2686: /funet.fi:/networking/news/gnus-3.14.1.tar.Z + ! 2687: /src.doc.ic.ac.uk:/gnu/EmacsBits/gnus/gnus-3.14.1.tar.Z + ! 2688: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/gnus-3.13.tar.Z ! ! 2689: Newsgroups and mailing lists: ! 2690: English-only: ! 2691: gnu.emacs.gnus ! 2692: [email protected] (for subscriptions) ! 2693: [email protected] (for submissions) ! 2694: Japanese (and some English): ! 2695: [email protected] (for subscriptions) ! 2696: [email protected] (for submissions) ! 2697: ! 2698: 109: Calc -- poor man's Mathematica within Emacs ! 2699: ! 2700: Author: Dave Gillespie <[email protected]> ! 2701: Latest released version: 2.02 ! 2702: Anonymous FTP: ! 2703: /csvax.cs.caltech.edu:pub/calc-2.02.tar.Z + ! 2704: /prep.ai.mit.edu:pub/gnu/calc-2.02.tar.Z + ! 2705: NOTE: Unlike Wolfram Research, Dave has never threatened to sue anyone ! 2706: for having a program with a similar command language to Calc. :-) ! 2707: ! 2708: 110: Calendar/Diary -- calendar manager within Emacs ! 2709: ! 2710: Author: Edward M. Reingold <[email protected]> ! 2711: Latest version: 4.02 ! 2712: Anonymous FTP: ! 2713: /emr.cs.uiuc.edu:pub/emacs/calendar {???} + ! 2714: Via e-mail: ! 2715: To: [email protected] ! 2716: Subject: send-emacs-cal ! 2717: Put your best internet e-mail address in the body. ! 2718: ! 2719: 111: Ange-FTP -- transparent FTP access for Emacs's file access routines ! 2720: ! 2721: Author: Andy Norman <[email protected]> ! 2722: Latest official version: 4.20 ! ! 2723: Anonymous FTP: ! 2724: /alpha.gnu.ai.mit.edu:ange-ftp/ange-ftp.tar.Z ! ! 2725: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/ange-ftp.tar.Z ! ! 2726: ugle.unit.no:pub/gnu/emacs-lisp/ange-ftp.tar.Z - ! 2727: Mailing lists: ! 2728: [email protected] (for subscriptions) ! 2729: Ange-FTP Lovers: ! 2730: [email protected] (for submissions) ! 2731: /ftp.reed.edu:pub/mailing-lists/ange-ftp/ (archives) ! ! 2732: Ange-FTP Announcements: ! 2733: [email protected] ! 2734: NOTE: now with support for accessing VMS, CMS, and MTS systems ! 2735: ! 2736: 112: VIP -- vi emulation for Emacs ! 2737: ! 2738: Author: Aamod Sane <[email protected]> ! 2739: Latest released version: 4.3 ! 2740: Anonymous FTP: ! 2741: /cs.uiuc.edu:pub/vip4.3.tar.Z + ! 2742: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/modes/vip-mode.tar.Z ! ! 2743: NOTE: This version much more closely emulates vi than the one ! 2744: distributed with Emacs. ! 2745: ! 2746: 113: Dired -- better directory editor for Emacs ! 2747: ! 2748: Author: Sebastian Kremer <[email protected]> ! 2749: Latest released version: 5.239 ! 2750: Anonymous FTP: /ftp.cs.buffalo.edu:pub/Emacs/diredall.tar.Z + ! 2751: /ftp.uni-koeln.de:pub/gnu/emacs/diredall.tar.Z + ! 2752: NOTE: This is a huge improvement over the Dired distributed with Emacs. ! 2753: This version will be in Emacs 19. ! 2754: ! 2755: 114: AUC TeX -- enhanced LaTeX mode with debugging facilities ! 2756: ! 2757: Author: Kresten Krab Thorup <[email protected]> ! 2758: Latest released version: 6.1 {???} ! ! 2759: Anonymous FTP: ! 2760: /iesd.auc.dk:pub/emacs-lisp/auctex_5_6e.tar.Z {wrong} ! ! 2761: /iesd.auc.dk:pub/emacs-lisp/auc-tex.tar.Z ! ! 2762: Mailing list: ! 2763: [email protected] (for subscriptions) ! 2764: [email protected] (for submissions) ! 2765: [email protected] (auc-tex development team) ! 2766: ! 2767: 115: Hyperbole -- extensible hypertext management system within Emacs ! 2768: ! 2769: Author: Bob Weiner <[email protected]> ! 2770: Anonymous FTP: ! 2771: /wilma.cs.brown.edu:pub/hyperbole/ h*.tar.Z + ! 2772: Mailing lists: ! 2773: hyperbole-announce -- Hyperbole release announcements only. ! 2774: Subscriptions: ! 2775: To: [email protected] ! 2776: Subject: Add <[email protected]> to hyperbole-announce ! 2777: hyperbole -- Hyperbole discussion. ! 2778: Subscriptions: ! 2779: To: [email protected] ! 2780: Subject: Add <[email protected]> to hyperbole ! 2781: Submissions: ! 2782: [email protected] ! 2783: NOTE: Any member of the hyperbole mailing list is automatically a ! 2784: member of the hyperbole-announce mailing list. ! 2785: NOTE: No .UUCP or ! addresses are allowed on these mailing lists. ! 2786: ! 2787: 116: Byte Compiler -- enhanced version of Emacs's byte compiler ! 2788: ! 2789: Author: Jamie Zawinski <[email protected]>, ! 2790: Hallvard B. Furuseth <[email protected]> ! 2791: Anonymous FTP: ! 2792: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/bytecomp.tar.Z ! ! 2793: /ftp.uu.net:languages/elisp/packages/bytecomp.tar.Z + ! 2794: /src.doc.ic.ac.uk:gnu/EmacsBits/elisp-archive/packages/bytecomp.tar.Z + ! 2795: ! 2796: 117: comint -- hugely enhanced shell mode and other derived modes ! 2797: ! 2798: Author: Olin Shivers <[email protected]> ! 2799: Anonymous FTP: ! 2800: /cs.cmu.edu:/afs/cs.cmu.edu/user/shivers/lib/emacs/ + ! 2801: {comint,cmu{tex,shell,scheme,lisp},ml}.el ! 2802: (anonymous password must contain `@', ! 2803: cannot cd to intermediate directories) ! 2804: ! 2805: 118: BBDB -- personal info rolodex integrated with mail/news readers ! 2806: ! 2807: Author: Jamie Zawinski <[email protected]> ! 2808: Latest released version: 1.47 ! ! 2809: Anonymous FTP: ! 2810: /archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/bbdb.tar.Z ! ! 2811: Mailing list: ! 2812: [email protected] (for subscriptions) ! 2813: [email protected] - ! 2814: [email protected] (to be informed of new releases) ! 2815: Note: BBDB does not work with VM 4. It does work with VM 5, RMAIL, GNUS, ! ! 2816: and MH-E. ! ! 2817: ! 2818: 119: Ispell -- spell checker in C with interface for Emacs ! 2819: ! 2820: Author: Geoff Kuenning <[email protected]> ! 2821: Latest released version: 2.0.02 ! 2822: Beta test version: 3.0 (9 patches) ! 2823: Anonymous FTP: ! 2824: /archive.cis.ohio-state.edu:/pub/gnu/ispell/ (version 2.0.02) ! ! 2825: /ftp.cs.ucla.edu:/pub/ispell/ (version 3.0, patches, dictionaries) ! ! 2826: /argus.math.orst.edu:pub/ispell/ (version 3.0, patches, dictionaries) ! ! 2827: /ftp.th-darmstadt.de:pub/dicts/ispell/ (mirror of argus) ! ! 2828: NOTE: Do not send mail to Geoff asking him to send you the latest ! 2829: version of Ispell. He does not have free e-mail. ! 2830: ! 2831: 120: Epoch -- enhanced GNU Emacs with better X interface ! 2832: ! 2833: Latest released version: 4.2 ! ! 2834: Anonymous FTP: ! 2835: /cs.uiuc.edu:pub/epoch-files/epoch/epoch-4.2.tar.Z ! ! 2836: /cs.uiuc.edu:pub/epoch-files/epoch/epoch-diff-4.1-4.2.tar.Z + ! 2837: /src.doc.ic.ac.uk:gnu/epoch/ + ! 2838: /aix370.rrz.uni-koeln.de:gnu/emacs/epoch/ + ! 2839: Newsgroup and mailing lists: ! 2840: Epoch: ! 2841: gnu.emacs.epoch ! 2842: [email protected] (for subscriptions) ! 2843: [email protected] (for submissions) ! 2844: Epoch-Design: ! 2845: [email protected] (for subscriptions) ! 2846: [email protected] (for submissions) ! 2847: FAQ list: ! 2848: Maintainer: Marc Andreessen <[email protected]> ! 2849: Anonymous FTP: ! 2850: /rtfm.mit.edu:pub/usenet/news.answers/epoch-faq + ! 2851: /ftp.ncsa.uiuc.edu:outgoing/marca/epoch/Epoch.FAQ + ! 2852: ! 2853: 121: Lucid GNU Emacs -- alternative Emacs 19 with better X interface ! 2854: ! 2855: Primary Maintainer: Jamie Zawinski <[email protected]> + ! 2856: Other Developers: Eric Benson <[email protected]> ! ! 2857: Matthieu Devin <[email protected]> ! ! 2858: Harlan Sexton <[email protected]> ! ! 2859: Latest released version: 19.3 ! ! 2860: Anonymous FTP: ! 2861: /labrea.stanford.edu:pub/gnu/lucid/lemacs-19.3.tar.Z (source) ! ! 2862: /labrea.stanford.edu:pub/gnu/lucid/lemacs-19.3-sun4.tar.Z (Sun4binaries) ! ! 2863: Newsgroup and mailing lists: ! 2864: Bugs: ! 2865: [email protected] (for subscriptions) ! 2866: [email protected] (for submissions) ! 2867: Help: ! 2868: [email protected] (for subscriptions) ! 2869: [email protected] (for submissions) ! 2870: ! 2871: 122: Demacs -- GNU Emacs altered to run on MS-DOS on 386/486 machines ! 2872: ! 2873: Authors: Manabu Higashida <[email protected]> ! 2874: HIRANO Satoshi <[email protected]> ! 2875: Latest released version: 1.2.0 ! 2876: Anonymous FTP: ! 2877: /utsun.s.u-tokyo.ac.jp:GNU/demacs/ (nearest to U.S.A.) ! ! 2878: /ftp.sigmath.osaka-u.ac.jp:pub/Msdos/Demacs/ + ! 2879: /wnoc-fuk.wide.ad.jp:pub/msdos/Demacs/ ! ! 2880: /ftp.3com.com:pub/gnu/msdos/demacs/ ! ! 2881: /mindseye.berkeley.edu:pub/kanji/demacs/ ! ! 2882: /ftp.hawaii.edu:pub/editors/demacs.tar.Z ! ! 2883: /ftp.math.ksu.edu:pub/pc/demacs/ + ! 2884: /wsmr-simtel20.army.mil:pd1:<msdos.demacs> {ange-ftp syntax?} ! ! 2885: /ftp.uni-koeln.de:msdos/gnuprogs/dem120e.zip (executables, lisp-code, doc) ! ! 2886: (PLEASE USE ONLY OUTSIDE WORKING HOURS!) + ! 2887: /ftp.uni-koeln.de:msdos/gnuprogs/dem120s.zip (sources, diffs) + ! 2888: (PLEASE USE ONLY OUTSIDE WORKING HOURS!) + ! 2889: /ftp.lysator.liu.se:pub/msdos/gnu/emacs/ + ! 2890: /mizar.docs.uu.se:pub/gnu/demacs/ ! ! 2891: /iamsun.unibe.ch:PC/demacs/ ! ! 2892: /flop.informatik.tu-muenchen.de:outgoing/demacs.tar ! ! 2893: /ftp.funet.fi:pub/gnu/emacs/demacs/ + ! 2894: /garbo.uwasa.fi:pc/editor/dem120e.zip ! ! 2895: /garbo.uwasa.fi:pc/editor/dem120s.zip ! ! 2896: /ftp.win.tue.nl:pub/gnu/demacs/ ! ! 2897: /ugle.unit.no:pub/gnu/Demacs/ ! ! 2898: {Does anyone know which sites have the Kanji version?} ! 2899: Via e-mail: ! 2900: From garbo.uwasa.fi: ! 2901: To: [email protected] ! 2902: Subject: garbo-request ! 2903: Body: send pc/editor/dem120e.zip ! 2904: send pc/editor/dem120s.zip ! 2905: quit ! 2906: Downloading: ! 2907: EXEC-PC (Milwaukee, WI) 414-789-4210 (2400 bps) ! 2908: in the Mahoney MS-DOS file area in its Editors/wordprocessors ! 2909: library (F), named GNUEMACS.ZIP ! 2910: Channel 1 (Cambridge, MA) 617-345-8873 (9600 bps) ! 2911: in the New Uploads file area, named GNUEMACS.ZIP ! 2912: NOTE: Use the -d option of [pk]unzip for all .zip archives. Some sites ! 2913: have Demacs lharc'ed. If you need to find programs to unpack lharc and - ! 2914: zip format archives, Chris Dean <[email protected]> points out that you ! 2915: should see the comp.compression FAQ, available for FTP: ! ! 2916: /rtfm.mit.edu:pub/usenet/comp.compression/ ! ! 2917: Mailing list: ! 2918: NOTE: There is no mailing list for Demacs. However, there is a list ! 2919: for DJGPP, which is the environment that Demacs runs in. Many ! 2920: Demacs problems are actually issues with DJGPP. ! 2921: DJGPP: ! 2922: Subscriptions: ! 2923: To: [email protected] ! 2924: body: add <your-address> djgpp ! 2925: or put `help' in the body. ! 2926: If this fails, mail to [email protected]. ! 2927: Submissions: ! 2928: [email protected] ! 2929: FAQ list: ! 2930: Maintainer: Dave Steibel <[email protected]> ! 2931: Anonymous FTP: algol.cs.umbc.edu:pub/demacs/demacs.faq ! 2932: ! 2933: 123: Freemacs -- a small Emacs for MS-DOS ! 2934: ! 2935: Author: Russ Nelson <[email protected]> ! 2936: Latest released version: 1.6a ! 2937: Anonymous FTP: ! 2938: /simtel20.army.mil:PD:<MSDOS.FREEMACS> {ange-ftp syntax?} ! ! 2939: /grape.ecs.clarkson.edu:pub/msdos/freemacs/ ! ! 2940: Via e-mail: ! 2941: To: [email protected] ! 2942: body: help ! 2943: Via snail mail: ! 2944: address: Russell Nelson, 11 Grant St., Potsdam, NY 13676 ! 2945: Send $15 copying fee, and specify preferred floppy disk format: ! 2946: 5.25", 360K, or 3.50", 720K ! 2947: Mailing lists: ! 2948: Subscriptions: ! 2949: To: [email protected] ! 2950: body: add <your-address> <name-of-list> ! 2951: or put `help' in the body. ! 2952: List distribution addresses: ! 2953: [email protected] ! 2954: [email protected] ! 2955: [email protected] (send bug reports here) ! 2956: ! 2957: 124: Patch -- program to apply "diffs" for updating files ! 2958: ! 2959: Author: Larry Wall <[email protected]> ! 2960: Latest version: 2.0 patchlevel 12u8 ! ! 2961: (This is the version that supports the new unified diff format.) ! 2962: Anonymous FTP: ! 2963: /prep.ai.mit.edu:pub/gnu/patch-2.0.12u8.tar.Z ! ! 2964: /prep.ai.mit.edu:pub/gnu/patch-2.0.12g8.tar.Z (GNU version) + ! 2965: ! 2966: GNU Emacs FAQ: Keybindings/Output ! 2967: ! 2968: If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to ! 2969: get an overview of just the questions. Then, when you want to look at the text ! 2970: of the answers, just type "C-x $". ! 2971: ! 2972: To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if ! 2973: that doesn't work, then type ESC to end the search. ! 2974: ! 2975: A `+' in the 78th column means something was inserted on the line. A `-' means ! 2976: something was deleted and a `!' means some combination of insertions and ! 2977: deletions occurred. ! 2978: ! 2979: Full instructions for getting the latest FAQ are in question 22. Also see the ! 2980: `Introduction to news.answers' posting in the `news.answers' newsgroup, or send ! 2981: e-mail to `[email protected]' with `help' on a body line, or use FTP, ! 2982: WAIS, or Prospero to rtfm.mit.edu. ! 2983: ! 2984: ! 2985: ! 2986: Changing Key Bindings and Handling Key Binding Problems ! 2987: ! 2988: 125: How do I bind keys (including function keys) to commands? ! 2989: ! 2990: 1. Find out what character sequence is generated by the keystroke sequence ! 2991: you wish to bind to a command. See question 129 for how to do this. ! 2992: Keep in mind that the character sequences generated by a keystroke ! 2993: sequence varies from one terminal to another. You may also get ! 2994: different results depending on what type of machine you are running on ! 2995: (see question 128). For example, these keystrokes may generate these ! 2996: character sequences: ! 2997: ! 2998: F1 ---> ESC [ 2 2 4 z ! 2999: Shift-R10 ---> ESC O t ! 3000: L7 ---> ESC [ 3 1 ~ ! 3001: Remove ---> C-@ ! 3002: ! 3003: 2. Figure out what the Emacs Lisp syntax is for this character sequence. ! 3004: Inside an Emacs Lisp string, RET, LFD, DEL, ESC, SPC, and TAB are ! 3005: specified with `\r', `\n', `\C-?', `\e', ` ', and `\t'. C-x is ! 3006: specified by `\C-x'. M-x is specified the same was as "ESC x". ! 3007: (Control characters may also be specified as themselves, but I don't ! 3008: recommend it.) An Emacs Lisp string begins and ends with the double ! 3009: quote character, `"'. Here are some examples: ! 3010: ! 3011: ESC [ D ---> "\e[D" ! 3012: ESC [ 2 2 7 z ---> "\e[227z" ! 3013: ESC [ 1 8 ~ ---> "\e[18~" ! 3014: C-M-r ---> "\e\C-r" ! 3015: ! 3016: 3. If some prefix of the character sequence is already bound, you must ! 3017: unbind it by binding it to `nil'. For example: ! 3018: ! 3019: (global-set-key "\e[" nil) ! 3020: ! 3021: 4. Pick a command to bind your key sequence to. A command can be a ! 3022: "symbol" with a function definition, or a "lambda list", or a string ! 3023: (which is treated as a macro). For example: ! 3024: ! 3025: (global-set-key "\e[D" 'backward-char) ! 3026: (global-set-key "\e[227~" "\exgoto-line\r") ; macro ! 3027: ! 3028: See `Key Bindings' and `Rebinding' in the online manual. ! 3029: ! 3030: In Emacs 19 (including Lucid Emacs), you can bind function key F24 like + ! 3031: this: + ! 3032: + ! 3033: (global-set-key 'f24 'some-command) + ! 3034: ! 3035: 126: Why does Emacs say `Key sequence XXX uses invalid prefix characters'? ! 3036: ! 3037: A prefix of the character sequence you were trying to bind was already ! 3038: bound. Usually, the sequence is "ESC [", in which case you should ! 3039: evaluate this form first: ! 3040: ! 3041: (define-key esc-map "[" nil) ! 3042: ! 3043: NOTE: By default, "ESC [" is bound to backward-paragraph, and if you do ! 3044: this you will lose this key binding. For most people, this is not a ! 3045: problem. ! 3046: ! 3047: See question 125. ! 3048: ! 3049: 127: Why doesn't this [terminal or window-system setup] code work in my ! 3050: .emacs file, but it works just fine after Emacs starts up? ! 3051: ! 3052: This is because you're trying to do something in your .emacs file that ! 3053: needs to be postponed until after the terminal/window-system setup code ! 3054: is loaded. This is a result of the order in which things are done ! 3055: during the startup of Emacs. For more details see question 135. ! 3056: ! 3057: In order to postpone the execution of Emacs Lisp code until after the ! 3058: terminal/window-system setup, set the value of the variable ! 3059: term-setup-hook or window-setup-hook to be a function which does what ! 3060: you want. ! 3061: ! 3062: See etc/OPTIONS for a complete explanation of what Emacs does every time ! 3063: it is started. ! 3064: ! 3065: Here is a simple example of how to set term-setup-hook: ! 3066: ! 3067: (setq term-setup-hook ! 3068: (function ! 3069: (lambda () ! 3070: (cond ((string-match "\\`vt220" (or (getenv "TERM") "")) ! 3071: ;; Make vt220's "Do" key behave like M-x: ! 3072: (define-key CSI-map "29~" 'execute-extended-command)) ! 3073: )))) ! 3074: ! 3075: 128: How do I use function keys under X Windows? ! 3076: ! 3077: This depends on whether you are running Emacs inside a terminal emulator ! 3078: window, or whether you are allowing Emacs to create its own X window. ! 3079: You can tell which you are doing by noticing whether Emacs creates a new ! 3080: window when you start it. ! 3081: ! 3082: If you are running Emacs inside a terminal emulator window, then it ! 3083: behaves exactly as it does on any other tty. In this case, for function ! 3084: keys to be useful, they must generate character sequences that are sent ! 3085: to the programs running inside the window as input. The `xterm' program ! 3086: has two different sets of character sequences that it generates when ! 3087: function keys are pressed, depending on the sunFunctionKeys X resource ! 3088: and the -sf and +sf command line options. (To find out what these key ! 3089: sequences are, see question 129.) In addition, with xterm, ! 3090: you can override what key sequence a specific function key (or any other ! 3091: key) will generate with the `translations' resource. This, for example: ! 3092: ! 3093: XTerm.VT100.Translations: #override \ ! 3094: <KeyPress>F1: string(0x1b) string("[xyzzy") ! 3095: ! 3096: makes the function key F1 generate the character sequence "ESC [xyzzy". ! 3097: ! 3098: On the other hand, if Emacs is managing its own X window, the following ! 3099: description applies. Emacs receives `KeyPress' events from the X server ! 3100: when a key is pressed while the keyboard focus is in its window. The ! 3101: KeyPress event contains an X "keysym" code, which is simply an arbitrary ! 3102: number corresponding to the name of the keysym, and information on which ! 3103: "modifiers" such as `control' and `shift' are active. For example, the ! 3104: `Tab' keysym is 0xff09. (Generally, a key on the keyboard will generate a ! 3105: keysym whose name is the same as the label on the key, ie. the `Tab' key ! 3106: will normally generate the `Tab' keysym. This can be changed with the ! 3107: xmodmap program.) Emacs recognizes all the keysyms that correspond to ! 3108: standard ASCII characters and internally uses the ASCII character instead. ! 3109: ! 3110: (WARNING: I am about to describe a gross, disgusting hack to you, have ! 3111: your barf bag ready.) ! 3112: ! 3113: When Emacs receives the X keysym of one of the arrow keys, it behaves ! 3114: the same as if it had received a letter key with the control modifier ! 3115: down as follows (this is hard-coded): ! 3116: ! 3117: Up becomes C-p ! 3118: Down becomes C-n ! 3119: Right becomes C-f ! 3120: Left becomes C-b ! 3121: ! 3122: The way Emacs treats other keysyms depends on what kind of machine it was ! 3123: compiled on. The type of the display machine is irrelevant! Function ! 3124: keys are mapped internally to escape sequences, while other keys are ! 3125: completely ignored. ! 3126: ! 3127: 1. If compiled on a Sun, Emacs recognizes these X keysyms that ! 3128: are normally on a Sun keyboard: ! 3129: ! 3130: F1 through F9 ! 3131: L1 through L10 (same as F11 through F20) ! 3132: R1 through R15 (same as F21 through F35) ! 3133: (The keys labelled R8, R10, R12, and R14 usually are mapped to the ! 3134: X keysyms Up, Left, Right, and Down.) ! 3135: Break (the `Alternate' key is given this keysym) ! 3136: ! 3137: These keys work like Sun function keys. When Emacs recieves the ! 3138: keysym, it will internally use character sequences that look like "ESC ! 3139: [ ### z", where ### is replaced by a number. The character sequences ! 3140: are identical to those generated by Sun's keyboard under SunView. Any ! 3141: function key not listed above generates "ESC [ - 1 z". ! 3142: ! 3143: In order to use these key sequences, they should be bound to commands ! 3144: using the standard key binding methods, just as if Emacs were running ! 3145: on a regular terminal. ! 3146: ! 3147: WARNING: F11 and L1 are the same keysym in X, as are F12 and L2, etc. ! 3148: {Yes, this is stupid. Complain to the X consortium.} ! 3149: ! 3150: 2. If not compiled on a Sun, the function keys will appear to Emacs in a ! 3151: way remarkably similar to the keys of a DEC LK201 keyboard (used on ! 3152: some VT series terminals). These X keysyms will be recognized: ! 3153: ! 3154: F1 through F20 ! 3155: Help (treated same as F15) ! 3156: Menu (treated same as F16, is the LK201 `Do' key) ! 3157: Find ! 3158: Insert (LK201 `Insert Here' key) ! 3159: Select ! 3160: Prior (LK201 `Prev Screen' key *** ONLY IN 18.58 AND LATER ***) ! 3161: Next (LK201 `Next Screen' key *** ONLY IN 18.58 AND LATER ***) ! 3162: ! 3163: And finally, the LK201 key labelled `Remove' (or `Delete') is often ! 3164: mapped to the Delete keysym which generates the DEL character (C-?) ! 3165: instead of the key sequence given by the LK201 `Remove' key. It may ! 3166: also be mapped to some other keysym, such as `_Remove', in which case ! 3167: you can't use it from within Emacs at all. ! 3168: ! 3169: Each function key will be internally converted to a character sequence ! 3170: that looks like "ESC [ ## ~", where ## is replaced by a number. The ! 3171: character sequences are identical to those generated by a LK201 ! 3172: keyboard. Any function key not listed above generates "ESC [ - 1 ~". ! 3173: ! 3174: For the complete list of the numbers which are generated by the function ! 3175: keys, look in the file src/x11term.c at the definitions of the function ! 3176: stringFuncVal. ! 3177: ! 3178: If you are running Emacs on a Sun machine, even if your X display is ! 3179: running on a non-Sun machine (eg., an X terminal), you get the setup ! 3180: described above for Suns. The determining factor is what type of ! 3181: machine Emacs is running (was compiled) on, not what type of machine ! 3182: your X display is on. ! 3183: ! 3184: If you have function keys not listed above on your keyboard, you can use ! 3185: `xmodmap' to change their keysym assignments to get keys that Emacs will ! 3186: recognize, but that may screw up other programs. ! 3187: ! 3188: X resources are not used by Emacs to affect the key sequences generated. ! 3189: In particular, there are no X key "translations" for Emacs. ! 3190: ! 3191: If you have function keys not listed above and you don't want to use ! 3192: xmodmap to change their names, you might want to make a modification to ! 3193: your Emacs. Johan Vromans <[email protected]> has made available a patch for Emacs ! 3194: that adds the x-rebind-key function of Epoch to Emacs 18.58. This allows ! 3195: another layer of key rebinding before Emacs even sees the keys, and in ! 3196: this layer you can rebind all of the keys and modifier combinations as ! 3197: well. ! 3198: ! 3199: Anonymous FTP: ! 3200: /ftp.eu.net:gnu/emacs/FP-Xfun.Z + ! 3201: /ftp.urc.tue.nl:pub/tex/emacs/FP-Xfun + ! 3202: ! 3203: Johan Vromans explains what this buys for you: ! 3204: ! 3205: After implementing this, all keyboard keys can be configured to send ! 3206: user definable sequences, eg., ! 3207: ! 3208: (x-rebind-key "KP_F1" 0 "\033OP") ! 3209: ! 3210: This will have the keypad key PF1 send the sequence "ESC O P", just like ! 3211: an ordinary VT series terminal. ! 3212: ! 3213: 129: How do I tell what characters my function or arrow keys emit? ! 3214: ! 3215: Use this function by Randal L. Schwartz <[email protected]>: ! 3216: ! 3217: (defun see-chars () ! 3218: "Displays characters typed, terminated by a 3-second timeout." ! 3219: (interactive) ! 3220: (let ((chars "") ! 3221: (inhibit-quit t)) ! 3222: (message "Enter characters, terminated by 3-second timeout.") ! 3223: (while (not (sit-for 3)) ! 3224: (setq chars (concat chars (list (read-char))) ! 3225: quit-flag nil)) ; quit-flag maybe set by C-g ! 3226: (message "Characters entered: %s" (key-description chars)))) ! 3227: ! 3228: Alternatively, use the "C-h l" view-lossage command, which will display ! 3229: the last 100 characters Emacs has seen in its input stream. Kevin ! 3230: Gallagher <[email protected]> suggests typing some unique string ! 3231: like "wxyz", typing the key in question, then typing "C-h l". The ! 3232: characters that appear between "wxyz" and "C-h l" were generated by the ! 3233: key. ! 3234: ! 3235: 130: How do I set the X key "translations" for Emacs? ! 3236: ! 3237: Sorry, you can't; there are no "translations" to be set. Emacs is not ! 3238: written using the Xt library. The only way to affect the behavior of keys ! 3239: within Emacs is through `xmodmap' (outside Emacs) or `define-key' (inside ! 3240: Emacs). ! 3241: ! 3242: 131: How do I handle C-s and C-q being used for flow control? ! 3243: ! 3244: C-s and C-q are used in the XON/XOFF flow control protocol. This screws ! 3245: up Emacs because it binds these characters to commands. Also, by default ! 3246: Emacs will not honor them as flow control characters and may overwhelm ! 3247: output buffers. Sometimes, intermediate software using XON/XOFF flow ! 3248: control will prevent Emacs from ever seeing C-s and C-q. ! 3249: ! 3250: Possible solutions: ! 3251: ! 3252: * Disable the use of C-s and C-q for flow control. ! 3253: ! 3254: You need to determine what is the cause of the flow control. ! 3255: ! 3256: * your terminal ! 3257: ! 3258: Your terminal may use XON/XOFF flow control to have time to display ! 3259: all the characters it receives. For example, VT series terminals do ! 3260: this. It may be possible to turn this off from a setup menu. For ! 3261: example, on a VT220 you may select `No XOFF' in the setup menu. This ! 3262: is also true for some terminal emulation programs on PCs. ! 3263: ! 3264: When you turn off flow control at the terminal, you will also need to ! 3265: turn it off at the other end, which might be at the computer you are ! 3266: logged in to or at some terminal server in between. ! 3267: ! 3268: If you turn off flow control, characters may be lost; using a printer ! 3269: connected to the terminal may fail. You may be able to get around ! 3270: this problem by modifying the `termcap' entry for your terminal to ! 3271: include extra NUL padding characters. ! 3272: ! 3273: * a modem ! 3274: ! 3275: If you are using a dialup connection, the modems may be using XON/XOFF ! 3276: flow control. I don't know how to get around this. ! 3277: ! 3278: * a router or terminal server ! 3279: ! 3280: Some network box between the terminal and your computer may be using ! 3281: XON/XOFF flow control. It may be possible to make it use some other ! 3282: kind of flow control. You will probably have to ask your local ! 3283: network experts for help with this. ! 3284: ! 3285: * tty and/or pty devices ! 3286: ! 3287: If your connection to Emacs goes through multiple tty and/or pty ! 3288: devices, they may be using XON/XOFF flow control even when it is not ! 3289: necessary. ! 3290: ! 3291: Eirik Fuller <[email protected]> writes: ! 3292: ! 3293: Some versions of `rlogin' (and possibly telnet) do not pass flow ! 3294: control characters to the remote system to which they connect. On ! 3295: such systems, Emacs on the remote system cannot disable flow control ! 3296: on the local system. Sometimes `rlogin -8' will avoid this problem. ! 3297: ! 3298: One way to cure this is to disable flow control on the local host ! 3299: (the one running rlogin, not the one running rlogind) using the stty ! 3300: command, before starting the rlogin process. On many systems, `stty ! 3301: start u stop u' will do this. ! 3302: ! 3303: Some versions of `tcsh' will prevent even this from working. One ! 3304: way around this is to start another shell before starting rlogin, ! 3305: and issue the stty command to disable flow control from that shell. ! 3306: ! 3307: Use `stty -ixon' instead of `stty start u stop u' on some systems. ! 3308: ! 3309: * Make Emacs speak the XON/XOFF flow control protocol. ! 3310: ! 3311: You can make Emacs treat C-s and C-q as flow control characters by ! 3312: evaluating this form: ! 3313: ! 3314: (set-input-mode nil t) ! 3315: ! 3316: If you are fixing this for yourself, simply put the form in your .emacs ! 3317: file. If you are fixing this for your entire site, the best place to ! 3318: put it is unclear. I don't know if this has any effect when used in ! 3319: lisp/site-init.el when building Emacs; I've never tried that. {Can ! 3320: someone tell me whether it works?} Putting things in users' .emacs files ! 3321: has a number of problems. ! 3322: ! 3323: Putting this form in lisp/default.el has the problem that if the user's ! 3324: .emacs file has an error, this will prevent lisp/default.el from being ! 3325: loaded and Emacs may be unusable for the user, even for correcting their ! 3326: .emacs file (unless they're smart enough to move it to another name). A ! 3327: possible solution is to initially disable C-s and C-q by setting ! 3328: keyboard-translate-table in lisp/site-init.el, either with swap-keys ! 3329: (see question 136) or with the following form: ! 3330: ! 3331: ;; by Roger Crew <[email protected]>: ! 3332: (setq keyboard-translate-table ! 3333: "\C-@\C-a\C-b\C-c\C-d\C-e\C-f\C-g\C-h\C-i\C-j\C-k\C-l\C-m\C-n\C-o\C-p\C-^\C-r\C-\\\C-t\C-u\C-v\C-w\C-x\C-y\C-z\C-[\C-s\C-]\C-q\C-_") ! 3334: ! 3335: This will at least prevent Emacs from being confused by the flow control ! 3336: characters, even if lisp/default.el cannot be loaded. Then, in ! 3337: lisp/default.el, enable XON/XOFF flow control with set-input-mode. ! 3338: ! 3339: For further discussion of this issue, read the file PROBLEMS in the ! 3340: Emacs distribution. ! 3341: ! 3342: 132: How do I use commands bound to C-s and C-q (or any key) if these keys ! 3343: are filtered out? ! 3344: ! 3345: I suggest swapping C-s with C-\ and C-q with C-^: ! 3346: ! 3347: (swap-keys ?\C-s ?\C-\\) ! 3348: (swap-keys ?\C-q ?\C-^) ! 3349: ! 3350: See question 136 for the implementation of swap-keys. This method ! 3351: has the advantage that it simultaneously swaps the characters everywhere ! 3352: throughout Emacs, while just switching the keybindings will miss important ! 3353: places where the character codes are stored (eg., the search-repeat-char ! 3354: variable, major mode keymaps, etc.). ! 3355: ! 3356: To do this for an entire site, you may want to swap the keys in ! 3357: lisp/default.el. If only some of your users are connecting through ! 3358: XON/XOFF flow-controlled connections, you will want to do this ! 3359: conditionally. I suggest pre-swapping them in lisp/site-init.el when ! 3360: Emacs is built, and then in lisp/default.el, if it is determined to be ! 3361: safe, they can be reenabled (being careful not to screw up any other key ! 3362: mappings users might have established using keyboard-translate-table). ! 3363: See question 131 for an easy way to pre-swap these keys. ! 3364: ! 3365: WARNING: If you do this for an entire site, the users will be confused by ! 3366: the disparity between what the documentation says and how Emacs actually ! 3367: behaves. ! 3368: ! 3369: 133: Why does the `BackSpace' key invoke help? ! 3370: ! 3371: The BackSpace key (on every keyboard I've used) generates ASCII code 8. ! 3372: C-h sends the same code. In Emacs by default C-h invokes help-command. ! 3373: This is intended to be easy to remember since the first letter of "help" ! 3374: is "h". The easiest solution to this problem is to use C-h (and ! 3375: BackSpace) for help and DEL (the Delete key) for deleting the previous ! 3376: character. ! 3377: ! 3378: For many people this solution may be problematic: ! 3379: ! 3380: * They normally use BackSpace outside of Emacs for deleting the previous ! 3381: character typed. This can be solved by making DEL be the command for ! 3382: deleting the previous character outside of Emacs. This command will do ! 3383: this on many Unix systems: ! 3384: ! 3385: stty erase '^?' ! 3386: ! 3387: * The person may prefer using the BackSpace key for deleting the previous ! 3388: character because it is more conveniently located on their keyboard or ! 3389: because they don't even have a separate Delete key. In this case, the ! 3390: BackSpace key should be made to behave like Delete. There are several ! 3391: methods. ! 3392: ! 3393: * Under X Windows, the easiest solution is to change the BackSpace key ! 3394: into a Delete key like this: ! 3395: ! 3396: xmodmap -e "keysym BackSpace = Delete" ! 3397: ! 3398: * Some terminals (eg., VT3## terminals) allow the character generated by ! 3399: the BackSpace key to be changed from a setup menu. ! 3400: ! 3401: * You may be able to get a keyboard that is completely programmable. ! 3402: ! 3403: * Under X or on a dumb terminal, it is possible to swap the BackSpace ! 3404: and Delete keys inside Emacs: ! 3405: ! 3406: (swap-keys ?\C-h ?\C-?) ! 3407: ! 3408: See question 136 for the implementation of swap-keys. ! 3409: ! 3410: * Another approach is to switch keybindings and put help on "C-x h" ! 3411: instead: ! 3412: ! 3413: (global-set-key "\C-h" 'delete-backward-char) ! 3414: (global-set-key "\C-xh" 'help-command) ; override mark-whole-buffer ! 3415: ! 3416: Other popular key bindings for help are M-? and "C-x ?". ! 3417: ! 3418: WARNING: Don't try to bind DEL to help-command, because there are many ! 3419: modes that have local bindings of DEL that will interfere. - ! 3420: ! 3421: 134: Why doesn't Emacs look at the stty settings for Backspace vs. Delete? ! 3422: ! 3423: Good question! ! 3424: ! 3425: 135: Why don't the arrow keys work? ! 3426: ! 3427: When Emacs starts up, it doesn't know anything about arrow keys at all ! 3428: (except when running under X, see question 128). During the process of ! 3429: starting up, Emacs will load a terminal-specific initialization file for ! 3430: your terminal type (as determined by the environment variable TERM), if ! 3431: one exists. This file has the responsibility for enabling the arrow keys. ! 3432: ! 3433: There are several things that can go wrong: ! 3434: ! 3435: 1. There is no initialization file for your terminal. ! 3436: ! 3437: You can determine this by looking in the lisp/term directory. If your ! 3438: terminal type (as determined by the TERM environment variable) is ! 3439: xxx-yy-z, then the first of these files in the lisp/term directory will ! 3440: be loaded as the terminal-specific initialization file: xxx-yy-z.el, ! 3441: xxx-yy.el, or xxx.el. ! 3442: ! 3443: There are two major cases of this problem: ! 3444: ! 3445: * Your terminal type is very similar to one that has an init file. ! 3446: ! 3447: In this case, there are several techniques suggested by Colin Jensen ! 3448: <[email protected]>, Ben Liblit <[email protected]>, and Marc ! 3449: Auslander <[email protected]>: ! 3450: ! 3451: A. Add a symbolic link in lisp/term for your terminal type that ! 3452: points to the similar type. For example, you could make VT102 ! 3453: terminals work with this command: ! 3454: ! 3455: ln -s vt100.el vt102.el ! 3456: ! 3457: This fixes things for everyone on the system who uses the terminal ! 3458: type. ! 3459: ! 3460: B. If you can't do the solution in part A, you can add code to your ! 3461: term-setup-hook that loads the correct file like this: ! 3462: ! 3463: (setq term-setup-hook ! 3464: (function ! 3465: (lambda () ! 3466: (cond ((equal "vt102" (or (getenv "TERM") "")) ! 3467: (load (concat term-file-prefix "vt100"))) ! 3468: (;; Code for other terminal types goes here ... ! 3469: ))))) ! 3470: ! 3471: C. If you use `tset' to set your TERM environment variable when you ! 3472: login, you can use the `-m' switch to tell tset to use a terminal ! 3473: type known by Emacs instead of another similar one. For example, ! 3474: specifying this: ! 3475: ! 3476: tset ... -m 'dec-vt220:vt220' ... ! 3477: ! 3478: will make tset say you are on a `vt220' instead of a `dec-vt220'. ! 3479: ! 3480: D. Interactively, you can type "M-x load-library RET term/vt100" to ! 3481: load the terminal-specific initialization files for VT100 ! 3482: terminals. ! 3483: ! 3484: * Your terminal type is not similar to one that has an init file. ! 3485: ! 3486: One can be made for your terminal, or you can just add code to your ! 3487: own .emacs to handle this problem for yourself. For example, if your ! 3488: terminal's arrow keys send these character sequences: ! 3489: ! 3490: Up: ESC [ A ! 3491: Down: ESC [ B ! 3492: Right: ESC [ C ! 3493: Left: ESC [ D ! 3494: ! 3495: then you can bind these keys to the appropriate commands with code in ! 3496: your .emacs like this: ! 3497: ! 3498: (setq term-setup-hook ! 3499: (function ! 3500: (lambda () ! 3501: (cond ((string-match "\\`xyzzy" (or (getenv "TERM") "")) ! 3502: ;; First, must unmap the binding for left bracket ! 3503: (or (keymapp (lookup-key global-map "\e\[")) ! 3504: (define-key global-map "\e\[" nil)) ! 3505: ;; Enable terminal type xyzzy's arrow keys: ! 3506: (define-key global-map "\e\[A" 'previous-line) ! 3507: (define-key global-map "\e\[B" 'next-line) ! 3508: (define-key global-map "\e\[C" 'forward-char) ! 3509: (define-key global-map "\e\[D" 'backward-char)) ! 3510: ((string-match "\\`abcde" (or (getenv "TERM") "")) ! 3511: ;; Do something different for terminal type abcde ! 3512: ;; ..... ! 3513: ))))) ! 3514: ! 3515: NOTE: You may have to restart Emacs to get changes to take effect. ! 3516: ! 3517: NOTE: Your arrow keys may send sequences beginning with "ESC O" when ! 3518: Emacs is running, even if they send sequences beginning with "ESC [" at ! 3519: all other times. This is because Emacs uses any command there may be ! 3520: in your terminal's termcap entry for putting the terminal into ! 3521: "Application Keypad Mode". Just map these sequences the same way as ! 3522: above. ! 3523: ! 3524: The next two cases are problems even if there is a initialization file for ! 3525: your terminal type. ! 3526: ! 3527: 2. The initialization file for your terminal doesn't bind arrow keys. ! 3528: ! 3529: If your terminal type is `xterm', you will have to bind the arrow keys ! 3530: as in part 1 above, since the xterm.el file doesn't do anything useful. ! 3531: There may be other terminal types with the same problem. ! 3532: ! 3533: 3. Your terminal's arrow keys send individual control characters. ! 3534: ! 3535: For example, the arrow keys on an ADM-3 send C-h, C-j, C-k, and C-l. ! 3536: ! 3537: There is not much Emacs can do in this situation, since all the control ! 3538: characters except for C-^ and C-\ are already used as Emacs commands. ! 3539: It may be possible to convince the terminal to send something else when ! 3540: you press the arrow keys; it is worth investigating. ! 3541: ! 3542: You have to make the hard choices of how to rebind keys to commands to ! 3543: make things work the way you want. Another alternative is to start ! 3544: learning the standard Emacs keybindings for moving point around: C-b, ! 3545: C-f, C-p, and C-n. Personally, I no longer use the arrow keys when ! 3546: editing because I have switched keyboards so many times. ! 3547: ! 3548: 4. Your terminal's arrow keys send sequences beginning with "ESC [". ! 3549: ! 3550: Due to an extremely poor design decision (ie., these sequences are ANSI ! 3551: standard), none of the the terminal-specific initialization files that ! 3552: are distributed with Emacs will bind these character sequences to the ! 3553: appropriate commands by default. (This also applies to any other ! 3554: function keys which generate character sequences starting with "ESC ! 3555: [".) This is because it was deemed far more important to preserve the ! 3556: binding of M-[ to the backward-paragraph command. It appears that this ! 3557: will change in Emacs 19. ! 3558: ! 3559: Some of the terminal-specific initialization files that come with Emacs ! 3560: provide a command enable-arrow-keys that will fix this problem. To get ! 3561: this automatically invoked, put this in your .emacs: ! 3562: ! 3563: (setq term-setup-hook ! 3564: (function ! 3565: (lambda () ! 3566: (if (fboundp 'enable-arrow-keys) (enable-arrow-keys))))) ! 3567: ! 3568: We put this in our lisp/default.el file, so users don't have to worry ! 3569: about it: ! 3570: ! 3571: ;; don't override a user's term-setup-hook ! 3572: (or term-setup-hook ! 3573: (setq term-setup-hook ! 3574: (function ! 3575: (lambda () ! 3576: (and (fboundp 'enable-arrow-keys) ! 3577: ;; don't override a user key mapping ! 3578: (eq 'backward-paragraph (lookup-key esc-map "[")) ! 3579: (enable-arrow-keys)))))) ! 3580: ! 3581: If your terminal type is `sun', you should put this in your .emacs ! 3582: instead (or in addition to the above): ! 3583: ! 3584: (setq sun-esc-bracket t) ! 3585: ! 3586: It is possible that the terminal-specific initialization file for your ! 3587: terminal type was written locally and does not follow the rule ! 3588: mentioned above. In this case you may need to inspect it to find out ! 3589: how to enable the arrow keys. (Actually, if it was written locally, it ! 3590: probably enables the arrow keys by default.) ! 3591: ! 3592: 136: How do I "swap" two keys? ! 3593: ! 3594: When Emacs receives a character, you can make Emacs behave as though it ! 3595: received another character by setting the value of ! 3596: keyboard-translate-table. The following Emacs Lisp will do this for you, ! 3597: allowing you to "swap" keys. After arranging for this Lisp to be ! 3598: evaluated by Emacs, you can evaluate `(swap-keys ?A ?B)' to swap A and B. ! 3599: ! 3600: (defun swap-keys (key1 key2) ! 3601: "Swap keys KEY1 and KEY2 using map-key." ! 3602: (map-key key1 key2) ! 3603: (map-key key2 key1)) ! 3604: ! 3605: (defun map-key (from to) ! 3606: "Make key FROM behave as though key TO was typed instead." ! 3607: (setq keyboard-translate-table ! 3608: (concat keyboard-translate-table ! 3609: (let* ((i (length keyboard-translate-table)) ! 3610: (j from) ! 3611: (k i) ! 3612: (str (make-string (max 0 (- j (1- i))) ?X))) ! 3613: (while (<= k j) ! 3614: (aset str (- k i) k) ! 3615: (setq k (1+ k))) ! 3616: str))) ! 3617: (aset keyboard-translate-table from to) ! 3618: (let ((i (1- (length keyboard-translate-table)))) ! 3619: (while (and (>= i 0) (eq (aref keyboard-translate-table i) i)) ! 3620: (setq i (1- i))) ! 3621: (setq keyboard-translate-table ! 3622: (if (eq i -1) ! 3623: nil ! 3624: (substring keyboard-translate-table 0 (1+ i)))))) ! 3625: ! 3626: NOTE: You must evaluate the definition of these functions before calling ! 3627: them! For example, list the function definitions before their use in your ! 3628: .emacs file. ! 3629: ! 3630: NOTE: These functions take two numbers as arguments. The example above, ! 3631: `(swap-keys ?A ?B)' is actually `(swap-keys 65 66)', because `?A' is ! 3632: merely notation for 65, the ASCII value of `A'. ! 3633: ! 3634: NOTE: These functions only work for single characters. You cannot swap ! 3635: two multi-character sequences. ! 3636: ! 3637: 137: How do I produce C-XXX with my keyboard? ! 3638: ! 3639: For C-@ and C-^, often you can just type Control-2 and Control-6. For ! 3640: C-_, you may have to hold down the shift key, typing Control-Shift-Hyphen. ! 3641: C-@ can often be generated by typing Control-Space. C-@ is often called ! 3642: the NUL character, and has ASCII value 0. C-_ can often be generated by ! 3643: typing Control-7 or Control-/. C-? (aka DEL) may be generated by typing ! 3644: Shift-BackSpace or Control-BackSpace or a key labelled Delete or Del. ! 3645: ! 3646: Try Control with all of the digits on your keyboard to see what gets ! 3647: generated. ! 3648: ! 3649: 138: What if I don't have a Meta key? ! 3650: ! 3651: Instead of typing M-a, you can type "ESC a" instead. In fact, Emacs ! 3652: converts M-a internally into "ESC a" anyway (depending on the value of ! 3653: meta-prefix-char). ! 3654: ! 3655: 139: What if I don't have an Escape key? ! 3656: ! 3657: Type C-[ instead. This should send ASCII code 27 just like an Escape ! 3658: key would. Try also C-;. ! 3659: ! 3660: 140: How do I type DEL on PC terminal emulators? ! 3661: ! 3662: Some IBM PC compatibles do not have a key labeled `Del' or `Delete' {is ! 3663: this true?}. Those that do generally have it in an inconvenient location. ! 3664: (Also, in some terminal emulators, the `Del' key does not transmit DEL.) ! 3665: The result is the standard "BackSpace invoking help" problem (see question ! 3666: 133). ! 3667: ! 3668: The usual solution, suggested by Michael Covington ! 3669: <[email protected]>, is to somehow tell the terminal emulator ! 3670: program that BackSpace should transmit DEL. Read the program's manual. ! 3671: Shift-BackSpace or Control-BackSpace may send DEL. The `Del' key may only ! 3672: send DEL if the NumLock key hasn't been pressed. ! 3673: ! 3674: 141: Can I make my `Compose Character' key behave like a Meta key? ! 3675: ! 3676: On a dumb terminal such as a VT220, no. It is rumored that certain VT220 ! 3677: clones could have their Compose key configured this way. If you're using ! 3678: X, you might be able to do this with the `xmodmap' program (this is ! 3679: what I do). ! 3680: ! 3681: 142: How do I bind a combination of modifier key and function key? ! 3682: ! 3683: Unless you're using Emacs under emacstool (or xvetool?), have a working ! ! 3684: version of x-rebind-key (see question 128), or are using Emacs 19 (Lucid + ! 3685: Emacs), you can't do this with Emacs alone. + ! 3686: ! 3687: If you are using emacstool, Emacs sees different character sequences for ! 3688: the combination of a modifier and a function key from what it sees for the ! 3689: function key alone. See etc/emacstool.1 for more information. Since ! 3690: Emacs sees different character sequences, you can bind these different ! 3691: sequences to different commands. ! 3692: ! 3693: If you are running Emacs inside a terminal emulator window like xterm, you ! 3694: can modify its translation tables to make it generate different character ! 3695: sequences for the combination of a modifier and a function key. For ! 3696: example, this X resource setting: ! 3697: ! 3698: XTerm.VT100.Translations: #override \ ! 3699: Shift<KeyPress>F1: string(0x1b) string("[xyzzy") ! 3700: ! 3701: makes Shift-F1 generate the character sequence "ESC [ xyzzy". You can ! 3702: bind these character sequences in Emacs as normal. Nick Ruprecht ! 3703: <[email protected]> has written an extensive X ! 3704: translation mapping for xterm that does this. {Does this have an FTP ! 3705: site?} ! 3706: ! 3707: If you have x-rebind-key, you can have any arbitrary combination of + ! 3708: modifiers with a key replaced by any sequence of "normal" characters. For + ! 3709: example, this makes Shift-Return behave as though you had typed "C-x C-e" + ! 3710: (example from Jerry Graves): + ! 3711: + ! 3712: (x-rebind-key "Return" 'shift "\C-x\C-e") + ! 3713: + ! 3714: In Emacs 19 (Lucid Emacs), you can bind Meta-Left-Arrow like this (example + ! 3715: from Jamie Zawinski): + ! 3716: + ! 3717: (global-set-key '(meta left) 'backward-word) + ! 3718: + ! 3719: With the last two methods, use `xmodmap' and `xev' to discover the keysym + ! 3720: and modifier names. + ! 3721: ! 3722: 143: Why doesn't my Meta key work in an xterm window? ! 3723: ! 3724: Try all of these methods before asking for further help: ! 3725: ! 3726: * You may have big problems using `mwm' as your window manager. {Does ! 3727: anyone know a good generic solution to allow the use of the Meta key in ! 3728: Emacs with mwm?} ! 3729: ! 3730: * For X11R4: Make sure it really is a Meta key. Use `xev' to find out ! 3731: what keysym your Meta key generates. It should be either Meta_L or ! 3732: Meta_R. If it isn't, use xmodmap to fix the situation. ! 3733: ! 3734: * Make sure the pty the xterm is using is passing 8 bit characters. ! 3735: `stty -a' (or `stty everything') should show `cs8' somewhere. If it ! 3736: shows `cs7' instead, use `stty cs8 -istrip' (or `stty pass8') to fix ! 3737: it. ! 3738: ! 3739: * If there is an rlogin connection between the xterm and the Emacs, the ! 3740: `-8' argument may need to be given to rlogin to make it pass all 8 ! 3741: bits of every character. ! 3742: ! 3743: * If the Emacs is running under Ultrix, it is reported that evaluating ! 3744: (set-input-mode t nil) helps. ! 3745: ! 3746: * If all else fails, you can make xterm generate "ESC W" when you type ! 3747: M-W, which is the same conversion Emacs would make if it got the M-W ! 3748: anyway. In X11R4, the following resource specification will do this: ! 3749: ! 3750: XTerm.VT100.EightBitInput: false ! 3751: ! 3752: (This changes the behavior of the insert-eight-bit action.) ! 3753: ! 3754: With older xterms, you can specify this behavior with a translation: ! 3755: ! 3756: XTerm.VT100.Translations: #override \ ! 3757: Meta<KeyPress>: string(0x1b) insert() ! 3758: ! 3759: You might have to replace `Meta' with `Alt'. ! 3760: ! 3761: 144: Why doesn't my ExtendChar key work as a Meta key under HP-UX 8.0? ! 3762: ! 3763: This is a result of an internationalization extension in X11R4 and the ! 3764: fact that HP is now using this extension. Emacs assumes that ! 3765: XLookupString returns the same result regardless of the Meta key state ! 3766: which is no longer necessarily true. Until Emacs is fixed, the temporary ! 3767: kludge is to run this command after each time the X server is started but ! 3768: preferably before any xterm clients are: ! 3769: ! 3770: xmodmap -e 'remove mod1 = Mode_switch' ! 3771: ! 3772: NOTE: This will disable the use of the extra keysyms systemwide, which ! 3773: may be undesirable if you actually intend to use them. ! 3774: ! 3775: 145: Where can I get key bindings to make Emacs emulate WordStar? ! 3776: ! 3777: There is a package `wordstar' by Jim Frost <[email protected]> and ! 3778: `ws-mode.el' by Juergen Nickelsen <[email protected]>. Check in the ! 3779: Emacs Lisp Archive (see question 89). ! 3780: ! 3781: 146: Where can I get an XEDIT emulator for Emacs? ! 3782: ! 3783: This question comes up once every couple of months. I have never seen a ! 3784: positive reply, so I presume no one has ever written one. ! 3785: ! 3786: ! 3787: ! 3788: Using Emacs with Alternate Character Sets ! 3789: ! 3790: 147: How do I make Emacs display 8-bit characters? ! 3791: ! 3792: There is a patch called the `8-bit ctl-arrow patch' that allows Emacs to ! 3793: display characters with codes from 128 to 255. {The original appears to ! 3794: have been by Kenneth Cline <[email protected]>.} Partially based ! 3795: on Johan Widen's earlier work, Johan Vromans <[email protected]> has updated this ! 3796: patch for Emacs 18.58 along with some other 8-bit improvements. ! 3797: ! 3798: Anonymous FTP: ! 3799: /ftp.eu.net:gnu/emacs/FP-EightBit.Z + ! 3800: /ftp.urc.tue.nl:pub/tex/emacs/FP-EightBit + ! 3801: /cs.purdue.edu:pub/ygz/cemacs.tar.Z:cemacs/8bit-patch-18.57 + ! 3802: /sics.se:archive/emacs-18.55-8bit-diff + ! 3803: /laas.laas.fr:pub/emacs/patch-8bit-18.55 ! ! 3804: /laas.laas.fr:pub/emacs/patch-8bit-18.57 ! ! 3805: ! 3806: Via e-mail: ! 3807: To: [email protected] ! 3808: body: send emacs-18.55-8bit-diff ! 3809: ! 3810: Anders Edenbrandt <[email protected]> has produced a more comprehensive ! 3811: patch for Emacs 18.57 that allows for 8-bit input and output. ! 3812: ! 3813: Anonymous FTP: ! 3814: /sics.se:archive/emacs-8bit-diff-lth + ! 3815: /gatekeeper.dec.com:pub/GNU/DS-emacs-18.57-8bit-diff-lth + ! 3816: ! 3817: The most comprehensive patches for 8-bit output are by Howard Gayle ! 3818: (originally for Emacs 18.55. These patches allow displaying any arbitrary ! 3819: string for a given 8-bit character (except TAB and C-j). Also supported ! 3820: is defining the sorting order and the uppercase and lowercase ! 3821: translations. It is reported that the 8-bit character support in Emacs 19 ! 3822: is largely based on these patches. Thomas Bellman ! 3823: <[email protected]> has updated these patches for Emacs 18.57. ! 3824: ! 3825: Anonymous FTP: ! 3826: /sics.se:archive/emacs-gayle.tar.Z (patches for 18.55) + ! 3827: /ftp.lysator.liu.se:pub/emacs/gayle-18.57.diff.tar.Z (patches) + ! 3828: /ftp.lysator.liu.se:pub/emacs/emacs-18.57-gayle.tar.Z (patched Emacs) + ! 3829: ! 3830: I am not sure if Epoch can display 8-bit characters as is. Lucid Emacs ! 3831: has the ctl-arrow patch installed. Nemacs displays 8-bit characters, and ! 3832: it may be useful for displaying the 8-bit ISO-8859 alphabet, but I don't ! 3833: know for sure (see question 149). ! 3834: ! 3835: 148: How do I input 8-bit characters? ! 3836: ! 3837: Minor modes for ISO Latin-1 that allow one to easily input this character ! 3838: set have been written by several people. Such modes have been written by ! 3839: Matthieu Herrb <[email protected]> (laas.laas.fr:pub/emacs/iso-latin-1.el), ! 3840: Johan Vromans <[email protected]> {FTP site??}, and Marc Shapiro ! 3841: <[email protected]> {FTP site??}. ! 3842: ! 3843: These approaches differ from the one taken by Anders Edenbrandt in that ! 3844: his method uses direct 8-bit input, while these methods use a compose ! 3845: sequence for 8-bit characters. {I have heard conflicting reports on ! 3846: whether this results in losing the Meta key. Perhaps this depends on ! 3847: whether Emacs is running under X. Can someone resolve this?} ! 3848: ! 3849: Karl Heuer <[email protected]> is said to have a patch to allow ! 3850: 8-bit input. Georg-Wilhelm Koltermann <[email protected]> also has a ! 3851: patch for either 18.57 or 18.58 that allows 8-bit input. ! 3852: ! 3853: Epoch comes with a patch that allows it to input 8-bit characters, but it ! 3854: is not enabled by default. {Is this right?} ! 3855: ! 3856: Jamie Zawinski says: + ! 3857: + ! 3858: Lucid GNU Emacs allows the input of any ISO-8859/1 keysyms that your + ! 3859: keyboard generates (see xmodmap), and contains a package that implements + ! 3860: a DEC/OpenWindows-like "Compose" key for systems which don't have one. + ! 3861: ! 3862: 149: Where can I get an Emacs that can handle kanji characters? ! 3863: ! 3864: Nemacs 3.3.2 (Nihongo GNU Emacs) is a modified version of GNU Emacs 18.55 ! 3865: that handles kanji characters. It is available via anonymous FTP: ! ! 3866: ! ! 3867: /crl.nmsu.edu:pub/misc/nemacs-3.3.2.tar.Z ! ! 3868: /uhccux.uhcc.hawaii.edu:editors/Nemacs-3.3.2/ ! ! 3869: /miki.cs.titech.ac.jp:JAPAN/nemacs/nemacs-3.3.2.tar.Z ! ! 3870: ! 3871: You might also need files for "wnn", a kanji input method ! 3872: (wnn-4.0.3{-README,.tar.Z} {on which machine?}). You need a terminal (or ! 3873: terminal emulator) that can display text encoded in JIS, Shift-JIS, or EUC ! 3874: (Extended Unix Code), or the ability to run Nemacs as a direct X Window ! 3875: client. ! 3876: ! 3877: 150: Where can I get an Emacs that can handle Chinese? ! 3878: ! 3879: `cemacs' by Stephen G. Simpson <[email protected]> is a patch to Emacs ! 3880: 18.57 (the ctl-arrow patch) and some Emacs Lisp code that combined with ! 3881: Cxterm allows using Chinese characters. It is available via anonymous ! 3882: FTP: ! ! 3883: ! ! 3884: /crl.nmsu.edu:pub/chinese/cemacs.tar.Z ! ! 3885: /cs.purdue.edu:pub/ygz/cemacs.tar.Z ! ! 3886: ! 3887: Cxterm is available from the same place: ! ! 3888: ! ! 3889: /cs.purdue.edu:pub/ygz/cxterm-11.5.1.tar.Z ! ! 3890: ! 3891: 151: Where is an Emacs that can handle Semitic (right-to-left) alphabets? ! 3892: ! 3893: Joel M. Hoffman <[email protected]> writes: ! 3894: ! 3895: A couple of years ago a wrote a hebrew.el file that allows right-to-left ! 3896: editing of Hebrew. I relied on the hardware to display the Hebrew ! 3897: letters, given the right codes, but not for any right-to-left support; ! 3898: the hardware also doesn't have to send any specific char. codes. Emacs ! 3899: keeps track of when the user is typing Hebrew vs. English. (The VT-* ! 3900: terminals in Israel contain built-in support for Hebrew.) ! 3901: ! 3902: To get it to work I had to modify only a few lines of GNU Emacs's source ! 3903: code --- just enough to make it 8-bit clean. ! 3904: ! 3905: [and in a separate message:] ! 3906: ! 3907: It doesn't produce time-order ["sefer" format] (I wouldn't recommend ! 3908: trying that with emacs, because converting time-order to screen-order ! 3909: with arbitrarily long lines is a bit tricky), but I also concocted a ! 3910: quick filter to convert screen-order into time-order. I'll be happy to ! 3911: send you the requisite files if you want them. If you're using it for ! 3912: anything large, however, you'll want something that works better. ! 3913: ! 3914: Joel Hoffman has also written a "bi-directional bi-lingual Emacs-like" ! 3915: editor for MS-DOS named Ibelbe (Itty Bitty Emacs-Like Bidirectional ! 3916: Editor). Ibelbe is written in Turbo Pascal and comes with source code. ! 3917: Here is the description: ! 3918: ! 3919: Ibelbe looks like emacs (it even has a minibuffer and filename ! 3920: completion), and fully supports both right-to-left and left-to-right ! 3921: editing. Other than an EGA monitor or better, no special hardware is ! 3922: required. You will need an EGA Hebrew font to use Ibelbe with Hebrew. ! 3923: ! 3924: Anonymous FTP: ! 3925: /israel.nysernet.org:israel/msdos/ibelbe.zip ! ! 3926: /israel.nysernet.org:israel/msdos/hebfont.zip ! ! 3927: ! 3928: Joseph Friedman <[email protected], [email protected]> has written ! 3929: patches for Emacs 18.55 and 18.58 that provide Semitic language support ! 3930: under X Windows. ! 3931: ! 3932: Warren Burstein <[email protected]> says he has mapped 7-bit keys by ! 3933: modifying self-insert-command "for Hebrew input on 7-bit keyboards". ! 3934: ! 3935: A good suggestion is to query archie for files named with `hebrew'. ! 3936: ! 3937: ! 3938: GNU Emacs FAQ: Mail and News ! 3939: ! 3940: This portion of the GNU Emacs FAQ list is cross-posted to `gnu.emacs.gnus' ! 3941: because many of the questions herein deal with GNUS. See `gnu.emacs.help' for ! 3942: the rest of the FAQ list. ! 3943: ! 3944: If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to ! 3945: get an overview of just the questions. Then, when you want to look at the text ! 3946: of the answers, just type "C-x $". ! 3947: ! 3948: To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if ! 3949: that doesn't work, then type ESC to end the search. ! 3950: ! 3951: A `+' in the 78th column means something was inserted on the line. A `-' means ! 3952: something was deleted and a `!' means some combination of insertions and ! 3953: deletions occurred. ! 3954: ! 3955: Full instructions for getting the latest FAQ are in question 22. Also see the ! 3956: `Introduction to news.answers' posting in the `news.answers' newsgroup, or send ! 3957: e-mail to `[email protected]' with `help' on a body line, or use FTP, ! 3958: WAIS, or Prospero to rtfm.mit.edu. ! 3959: ! 3960: ! 3961: ! 3962: Mail and News ! 3963: ! 3964: 152: How do I change the included text prefix in mail/news followups? ! 3965: ! 3966: Many people want Emacs to prefix included text with something like ` > ' ! 3967: instead of with three spaces. One way is to change the code of the ! 3968: function `mail-yank-original' in lisp/sendmail.el that prefixes with ! 3969: spaces. A more flexible solution is to use Supercite, which provides wide ! 3970: configurability in how you format included text in replies. See question ! 3971: 107. Both of these solutions work for RMAIL and GNUS. ! 3972: ! 3973: A related problem is how to prevent Emacs from including various headers ! 3974: of the replied-to message. For this, you should set the value of ! 3975: mail-yank-ignored-headers, which takes a regexp value. ! 3976: ! 3977: 153: How do I save a copy of outgoing mail? ! 3978: ! 3979: Two methods: ! 3980: ! 3981: 1. (setq mail-self-blind t) will result in a `BCC:' header line with your ! 3982: address being added to mail composition buffers. This will cause the ! 3983: mail system to send a copy of the mail back to you. ! 3984: ! 3985: 2. (setq mail-archive-file-name (expand-file-name "~/outgoing")) will ! 3986: result in an `FCC:' header line with the pathname of ~/outgoing being ! 3987: added to mail composition buffers. When you send the mail, Emacs will ! 3988: save a copy of the mail in the file ~/outgoing and then strip off the ! 3989: `FCC:' line before actually sending. ! 3990: ! 3991: WARNING: There is a bug in Emacs 18.58 that prevents mail readers such ! 3992: as RMAIL from reading the saved mail messages individually. See ! 3993: question 155. ! 3994: ! 3995: WARNING: If you are visiting the file ~/outgoing at the time you send ! 3996: the mail, this can cause a variety of horrible problems. Jamie + ! 3997: Zawinski has written a solution for this. + ! 3998: ! 3999: It does not work to put `set record filename' in the .mailrc file. ! 4000: ! 4001: 154: Why doesn't Emacs expand my aliases when sending mail? ! 4002: ! 4003: * You must separate multiple addresses in the headers of the mail buffer ! 4004: with commas. This is because Emacs supports RFC822 standard addresses ! 4005: like this one: ! 4006: ! 4007: To: Willy Smith <[email protected]> ! 4008: ! 4009: However, you do not need to separate addresses with commas in your ! 4010: .mailrc file. ! 4011: ! 4012: WARNING: Emacs breaks up aliases in the .mailrc file into multiple ! 4013: addresses both on commas and on whitespace, regardless of any use of ! 4014: quotes. This is probably a bug. You can get around this by directly ! 4015: setting the value of mail-aliases. ! 4016: ! 4017: * Emacs normally only reads the `.mailrc' file once per session, when you ! 4018: start to compose your first mail message. If you edit .mailrc, you can ! 4019: type "M-ESC (build-mail-aliases) RET" to make Emacs reread .mailrc. ! 4020: (You have to include the parentheses where they are shown!) ! 4021: ! 4022: * Emacs does not interpret vendor-specific additions to the format of the ! 4023: .mailrc file such as the `source' command. It also ignores any `set' ! 4024: commands. The only commands it looks at are `alias' and `group' ! 4025: commands. ! 4026: ! 4027: 155: Why does RMAIL think all my saved messages are one big message? ! 4028: ! 4029: There is a bug for FCC-ed messages in Emacs 18.58 where it adds a timezone ! 4030: on the "From " line after the year instead of before the year. (Before it ! 4031: didn't add the timezone at all.) This is incompatible with the standard ! 4032: format for the "From " line, and RMAIL in particular can no longer ! 4033: distinguish between the messages. Karl Berry <[email protected]>, Felix Lee ! 4034: <[email protected]>, Nick Gianniotis <[email protected]> and many ! 4035: others have all posted patches for this. Karl's is the simplest and just ! 4036: stops Emacs from adding the timezone: ! 4037: ! 4038: >*** ./ORIG/sendmail.el Tue Jan 28 16:22:56 1992 ! 4039: >--- ./sendmail.el Thu May 14 18:23:48 1992 ! 4040: >*************** ! 4041: >*** 285,287 **** ! 4042: > (insert "\nFrom " (user-login-name) " " ! 4043: >! (current-time-string) " " timezone "\n") ! 4044: > (insert-buffer-substring rmailbuf) ! 4045: >--- 285,287 ---- ! 4046: > (insert "\nFrom " (user-login-name) " " ! 4047: >! (current-time-string) "\n") ! 4048: > (insert-buffer-substring rmailbuf) ! 4049: ! 4050: 156: How can I sort the messages in my RMAIL folder? ! 4051: ! 4052: Use rmailsort.el by Masanobu Umeda. ! 4053: ! 4054: 157: Why does RMAIL need to write to /usr/spool/mail? ! 4055: ! 4056: This is the behavior of the `movemail' program which RMAIL uses. This ! 4057: indicates that movemail is configured to use lock files. ! 4058: ! 4059: RMS writes: ! 4060: ! 4061: Certain systems require lock files to interlock access to mail files. ! 4062: On these systems, movemail must write lock files, or you risk losing ! 4063: mail. You simply must arrange to let movemail write them. ! 4064: ! 4065: Other systems use the flock system call to interlock access. On these ! 4066: systems, you should configure movemail to use flock. ! 4067: ! 4068: 158: How do I recover my mail files after RMAIL munges their format? ! 4069: ! 4070: Users who just want to try RMAIL out to see how it works end up trapped ! 4071: using it because saved mail in their `mbox' file has been converted into ! 4072: an incompatible format (BABYL) that only RMAIL understands. RMAIL ! 4073: provides no obvious way to reverse this transformation. Kyle Jones has + ! 4074: aptly named this "the great Emacs Mail Eating Monster". To convert a mail + ! 4075: file back to standard Unix format, there are several methods: ! 4076: ! 4077: * Use the rmail-output ("C-o") command within RMAIL on each message in the ! 4078: file. First use M-x rmail or M-x rmail-input to visit the RMAIL file in ! 4079: Rmail mode. Type "1 j" to go to the first message. Use the C-o command ! 4080: to output the message to a Unix format file. Type "n" to go to the next ! 4081: message. Repeat. ! 4082: ! 4083: * If the file contains hundreds of messages, you may not want to repeat ! 4084: this for all of them. Instead of the above, after getting to the first ! 4085: message type this (where "mbox" is the file you want to put the messages ! 4086: in): ! 4087: ! 4088: C-x ( C-o mbox RET M-s ^From: RET M-0 C-x ) ! 4089: ! 4090: (The rmail-search command ("M-s") is used instead of just "n" because it ! 4091: is the only command which will cause an error when it reaches the last ! 4092: message in the file, which is necessary to terminate the keyboard macro. ! 4093: This will fail if there are messages in the file that don't have a ! 4094: `From:' header. This assumes rmail-delete-after-output is nil.) ! 4095: ! 4096: It is wise to save a copy of the RMAIL file first, in case you make a ! 4097: mistake. ! 4098: ! 4099: * There are software packages available for converting files or even ! 4100: entire directories of BABYL files to standard Unix format. These are ! 4101: helpful in this situation, but are intended mainly for people who have ! 4102: used RMAIL for a long time and are converting to some other mail reader. ! 4103: Lookup `rmail', `vm', and `babyl' in the Emacs Lisp Archive (see ! 4104: question 89). ! 4105: ! 4106: You may wish to disable RMAIL to avoid accidentally destroying your mbox ! 4107: file (I have this in my .emacs): ! 4108: ! 4109: (put 'rmail 'disabled t) ; avoid mbox destruction ! 4110: ! 4111: 159: How do I make Emacs automatically start my mail/news reader? ! 4112: ! 4113: Example: ! 4114: ! 4115: emacs -f gnus ! 4116: ! 4117: Also: ! 4118: ! 4119: alias gnus 'emacs -f gnus' ! 4120: ! 4121: It is probably unwise to automatically start your mail or news reader from ! 4122: your .emacs file. This would cause problems if you needed to run two ! 4123: copies of Emacs at one time. Also, this would make it difficult for you ! 4124: to start Emacs quickly when you needed to. ! 4125: ! 4126: 160: How do I read news under Emacs? ! 4127: ! 4128: There are at least three news reading packages that operate inside Emacs. ! 4129: `rnews' comes with Emacs. GNUS and Gnews come separately. rnews will ! 4130: be replaced by GNUS in Emacs 19. ! 4131: ! 4132: rnews works only with a local news spool directory. Both GNUS and Gnews ! 4133: handle reading news remotely via NNTP in addition to reading from a local ! 4134: news spool. GNUS supports reading mail stored in MH folders or articles ! 4135: saved by GNUS. ! 4136: ! 4137: Gnews is styled after `rn' and seems to work like RMAIL. GNUS feels more ! 4138: like VM. People have complained that GNUS uses a lot of CPU time (it ! 4139: does). Some people have complained that Gnews is slower than GNUS. ! 4140: ! 4141: For more information about GNUS, see question 108. ! 4142: ! 4143: Gnews was written by Matthew P. Wiener <[email protected]>. ! 4144: The latest version seems to be 2.0, posted October 3, 1988. Matthew ! 4145: posted some fixes on October 26, 1988. Gnews does not appear to have been ! 4146: supported after this date. In particular, it has been reported that Gnews ! 4147: does not work with Emacs 18.57. There is a newsgroup for Gnews called ! 4148: gnu.emacs.gnews. ! 4149: ! 4150: 161: Why does `rnews' say "No News is good news" when there is news? ! 4151: ! 4152: rnews doesn't speak NNTP. You may need to use GNUS or Gnews. ! 4153: ! 4154: 162: Why doesn't GNUS work anymore via NNTP? ! 4155: ! 4156: There is a bug in NNTP version 1.5.10, such that when multiple requests ! 4157: are sent to the NNTP server, the server only handles the first one before ! 4158: blocking waiting for more input which never comes. NNTP version 1.5.11 ! 4159: claims to fix this. ! 4160: ! 4161: You can work around the bug inside Emacs like this: ! 4162: ! 4163: (setq nntp-maximum-request 1) ! 4164: ! 4165: I also have a patch for NNTP 1.5.10 by Mike Pelletier ! 4166: <[email protected]> that is based on the timeout code that was in ! 4167: 1.5.9. However, please try to upgrade to 1.5.11 first. ! 4168: ! 4169: You can find out what version of NNTP your news server is running by ! 4170: telnetting to the NNTP port (usually 119) on the news server machine (ie., ! 4171: `telnet server-machine 119'). The server should give its version number ! 4172: in the welcome message. Type `quit' to get out. ! 4173: ! 4174: 163: How do I view text with embedded underlining (eg., ClariNews)? ! 4175: ! 4176: Underlining appears like this: ! 4177: ! 4178: _^Hu_^Hn_^Hd_^He_^Hr_^Hl_^Hi_^Hn_^Hi_^Hn_^Hg ! 4179: ! 4180: You can destructively remove underlining with M-x ununderline-region. ! 4181: ! 4182: For ClariNews articles, clari-clean.el by David N. Blank-Edelman ! 4183: <[email protected]> will remove both underlining and overstriking ! 4184: automatically. ! 4185: ! 4186: 164: When I try to post a long article in GNUS (about 10K or longer), I get ! 4187: the error, "Writing to process: no more processes, nntpd" ! 4188: ! 4189: Upgrade to Emacs 18.58. ! 4190: ! 4191: 165: How do I save all the items of a multi-part posting in GNUS? ! 4192: ! 4193: Use gnus-mark.el by Jamie Zawinski <[email protected]>. ! 4194: ! 4195: 166: Why does GNUS put the subjects in replies beyond the 80th column? ! 4196: ! 4197: This is a feature. If you set gnus-thread-hide-subject to non-nil, GNUS ! 4198: will only display the subject of the first posting in a thread, even if ! 4199: some of the replies use different subjects. It hides the subjects by ! 4200: putting them past the edge of the window and setting truncate lines to t. ! 4201: ! 4202: If your screen looks messed up, then for some reason truncate-lines in ! 4203: your `*Subject*' buffer has been set to nil. It should be set to t. ! 4204: ! 4205: (I have an enhancement to GNUS 3.13 that will make it only hide the subject ! 4206: of a posting when it is unchanged from the followed-up-to posting. Thus, ! 4207: you can use the subject hiding feature and still know when someone changes ! 4208: the subject. (I have forgotten who originally gave me the idea for this.)) ! 4209: ! 4210: 167: Why is GNUS so slow to start up? ! 4211: ! 4212: GNUS does several things that take quadratic time of the number of ! 4213: newsgroups that are listed in .newsrc. The quick fix for this is to ! 4214: remove all the newsgroups in which you have no interest from your .newrc ! 4215: file by using GNUS's C-k command in the `*Newsgroup*' buffer after ! 4216: displaying all newsgroups with the L command. If you were to directly ! 4217: edit your .newsrc to remove the newsgroups, GNUS would add them back. ! 4218: ! 4219: GNUS uses a quadratic algorithm to check for duplicates when the .newsrc ! 4220: file is newer than the .newsrc.el file (ie., you edited your .newsrc). ! 4221: GNUS uses a quadratic algorithm to check for new newsgroups every time it ! 4222: connects to the news server. {There may be other quadratic algorithms ! 4223: that I am not aware of.} ! 4224: ! 4225: You can speed up GNUS by using the C-k command in the *Newsgroup* buffer ! 4226: to remove newsgroups from your .newsrc file. ! 4227: ! 4228: Of course, GNUS will run faster if you make sure it is byte-compiled. ! 4229: ! 4230: Felix Lee wrote some enhancements called `gnus-speedups.el' that fix some + ! 4231: of the problems. See the Emacs Lisp Archive. + ! 4232: ! 4233: 168: How do I catch up all newsgroups in GNUS? ! 4234: ! 4235: In the `*Newsgroup*' buffer, type the following magical incantation: ! 4236: ! 4237: M-< C-x ( C-@ c y C-u C-@ C-e C-f C-f M-0 C-x ) ! 4238: ! 4239: Leave off the "M-<" if you only want to catch up from point to the end of ! 4240: the `*Newsgroup' buffer. ! 4241: ! 4242: 169: Why can't I kill in GNUS on the Newsgroups/Keywords/Control line? ! 4243: ! 4244: GNUS 3.14.1 will complain that the `Newsgroups:', `Keywords:', and ! 4245: `Control:' headers are `Unknown header field's. ! 4246: ! 4247: For the `Newsgroups:' header, there is an easy workaround: kill on the ! 4248: `Xref' header instead, which will be present on any cross-posted article. ! 4249: ! 4250: If you really want to kill on one of these headers, you can do it like ! 4251: this: ! 4252: ! 4253: (gnus-kill nil "^Newsgroups: .*\\(bad\\.group\\|worse\\.group\\)") ! 4254: ! 4255: Various people (eg., Greg Holley <[email protected]>) have posted ! 4256: solutions to allow more efficient killing on these headers than the ! 4257: preceding solution. Masanobu Umeda plans to fix this problem. ! 4258: ! 4259: 170: How do I get rid of flashing messages in GNUS for slow connections? ! 4260: ! 4261: GNUS outputs "NNTP: Reading..." message and then clears them, over and ! 4262: over. In version 3.14.1 there is a variable named nntp-debug-read that ! 4263: can help. Johan Vromans <[email protected]> wrote a fix. Others have also written ! 4264: fixes. ! 4265: ! 4266: 171: Why is catch up slow in Gnews/GNUS? ! 4267: ! 4268: Because GNUS is marking crosspostings read. {I think it should do this at ! 4269: the time the article is read to spread out the load. Maybe someone will ! 4270: write the code to do this.} ! 4271: ! 4272: 172: Why does GNUS hang for a long time when posting? ! 4273: ! 4274: David Lawrence <[email protected]> explains: ! ! 4275: ! ! 4276: The problem is almost always interaction between NNTP and C News. NNTP ! ! 4277: POST asks C News's inews to not background itself but rather hang around ! ! 4278: and give its exit status so it knows whether the post was successful. ! ! 4279: (That wait will on some systems not return the exit status of the ! ! 4280: waited for job is a different sort of problem.) It ends up taking a ! ! 4281: long time because inews is calling relaynews, which often waits for ! ! 4282: another relaynews to free the lock on the news system so it can file the ! ! 4283: article. ! ! 4284: ! ! 4285: My preferred solution is to change inews to not call relaynews, but ! ! 4286: rather use newsspool. This loses some error-catching functionality, but ! ! 4287: is for the most part safe as inews will detect a lot of the errors on ! ! 4288: its own. The C News folks have sped up inews, too, so speed should look ! ! 4289: better to most folks as that update propagates around. ! ! 4290: ! 4291: 173: Why don't my news postings in GNUS get past the local machine? ! 4292: ! 4293: Three possible reasons: local distribution, C News date problem (see ! 4294: question 174, and the path problem. This piece of code may fix the path ! ! 4295: problem for you: ! ! 4296: ! ! 4297: (setq gnus-use-generic-path t) ! ! 4298: ! 4299: 174: Why is the GNUS-generated `Date:' header invalid? ! 4300: ! 4301: GNUS generates `Date:' headers without time zones. C-News's `inews' ! 4302: doesn't replace it with a valid header, but will generate it if not ! 4303: already there. If it is invalid, the article will not be forwarded ! 4304: properly. Quick fix: ! 4305: ! 4306: (defun gnus-inews-date () nil) ! 4307: ! 4308: I think this is fixed in GNUS 3.14.1 if you set gnus-news-system {?} to + ! 4309: Cnews. + ! 4310: ! 4311: 175: Why doesn't GNUS generate the `Lines:' header? ! 4312: ! 4313: GNUS was written for B news, which would generate the `Lines:' header. C ! 4314: news doesn't. There is a comment in C news's `inews' that you can ! 4315: uncomment to enable this functionality. Or you can have GNUS generate the ! 4316: header, for example: ! 4317: ! 4318: ;; idea by [email protected] (Jack Bryans) ! 4319: (defun add-lines-header () ! 4320: ;; Count the number of lines in the current posting and insert the ! 4321: ;; header line Lines into the message. ! 4322: (save-excursion ! 4323: (goto-char (point-min)) ! 4324: (if (search-forward "\n\n") ;; ***** I suspect this is wrong ***** ! 4325: (let ((lines (count-lines (point) (point-max)))) ! 4326: (forward-line -1) ! 4327: (insert-string "Lines: " lines "\n"))))) ! 4328: ! 4329: Mike Williams <[email protected]> has written something similar. ! 4330: ! 4331: Ronald Florence <[email protected]> has a patch for GNUS that makes it ! 4332: calculate the `Lines:' header for incoming articles when necessary that ! 4333: works for sites with local news spools. ! 4334: ! 4335: David Lawrence <[email protected]> says that GNUS 3.14.1 generates Lines + ! 4336: if gnus-news-system is Cnews. + ! 4337: ! 4338: 176: Why do I get "Cannot open load file" "nntp" when compiling GNUS? ! 4339: ! 4340: Specifically, the error message is this: ! 4341: ! 4342: Error occurred processing gnus.el: File error (("Cannot open load file" "nntp")) ! 4343: ! 4344: This means that nntp.el is not in Emacs's load-path, which is easy to ! 4345: happen when compiling using the Makefile. ! 4346: ! 4347: Easiest solution: set EMACSLOADPATH in Makefile (idea from Glenn Gribble ! 4348: <[email protected]>): ! 4349: ! 4350: EMACSLOADPATH=/usr/local/emacs/lisp:. ! 4351: ELC= env EMACSLOADPATH=$(EMACSLOADPATH) emacs -batch -f batch-byte-compile ! 4352: ! 4353: Another solution, in hack.el put this: ! 4354: ! 4355: (defun gross-hack () (setq load-path (cons "/directory" load-path))) ! 4356: ! 4357: Then in Makefile: ! 4358: ! 4359: ELC= emacs -batch -l hack.el -f gross-hack -f batch-byte-compile ! 4360: ! 4361: 177: How do I kill all articles in GNUS but those matching a pattern? ! 4362: ! 4363: Example: ! 4364: ! 4365: ;; kill everything ! 4366: (gnus-kill "subject" "" nil nil) ! 4367: ;; then restore stuff by our favorite poster ! 4368: (gnus-kill "from" "good-guy" ! 4369: (function ! 4370: (lambda () ! 4371: (if (eq ?X (char-after (save-excursion ! 4372: (beginning-of-line 1) ! 4373: (point)))) ! 4374: (gnus-Subject-clear-mark-forward 1)))) ! 4375: t) ! 4376: ! 4377:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.