comparison etc/FAQ @ 24074:96a0e2b175a7

Merge previous edits.
author Dave Love <fx@gnu.org>
date Thu, 14 Jan 1999 20:28:50 +0000
parents 633699bb2aae
children 30df0c6bf3f7
comparison
equal deleted inserted replaced
24073:633699bb2aae 24074:96a0e2b175a7
1 GNU Emacs FAQ: Introduction 1 GNU Emacs FAQ: Introduction
2 2
3 This is the introduction to a list of frequently asked questions (FAQ) 3 This is the introduction to a list of frequently asked questions (FAQ)
4 about GNU Emacs 20 with answers. Some of the answers are not valid for GNU 4 about GNU Emacs 20 with answers. Some of the answers are not valid for GNU
5 Emacs 18 or 19. 5 Emacs 18 or 19.
6
7 [This version has been somewhat edited from the last-posted version
8 (as of January 1999) for inclusion in the Emacs distribution.]
6 9
7 The FAQ is posted (in five parts) to reduce the noise level in the 10 The FAQ is posted (in five parts) to reduce the noise level in the
8 gnu.emacs.help newsgroup (which is also the help-gnu-emacs mailing list) 11 gnu.emacs.help newsgroup (which is also the help-gnu-emacs mailing list)
9 which results from the repetition of frequently asked questions, wrong 12 which results from the repetition of frequently asked questions, wrong
10 answers to these questions, corrections to the wrong answers, corrections 13 answers to these questions, corrections to the wrong answers, corrections
129 65: How do I delete menus and menu options? 132 65: How do I delete menus and menu options?
130 66: How do I turn on syntax highlighting? 133 66: How do I turn on syntax highlighting?
131 67: How can I force Emacs to scroll only one line when I move past the 134 67: How can I force Emacs to scroll only one line when I move past the
132 bottom of the screen? 135 bottom of the screen?
133 68: How can I replace highlighted text with what I type? 136 68: How can I replace highlighted text with what I type?
134 69: How can I edit MS-DOS files using Emacs? 137 69: How can I edit MS-DOS-style text files using Emacs?
135 70: How can I tell Emacs to fill paragraphs with a single space after 138 70: How can I tell Emacs to fill paragraphs with a single space after
136 each period? 139 each period?
137 140
138 Bugs/Problems 141 Bugs/Problems
139 142
166 91: How do I submit code to the Emacs Lisp Archive? 169 91: How do I submit code to the Emacs Lisp Archive?
167 92: Where can I get other up-to-date GNU stuff? 170 92: Where can I get other up-to-date GNU stuff?
168 93: What is the difference between Emacs and XEmacs (formerly "Lucid 171 93: What is the difference between Emacs and XEmacs (formerly "Lucid
169 Emacs")? 172 Emacs")?
170 94: Where can I get Emacs for my PC running MS-DOS? 173 94: Where can I get Emacs for my PC running MS-DOS?
171 95: Where can I get Emacs for Microsoft Windows, Windows '95, or Windows 174 95: Where can I get Emacs for Microsoft Windows, Windows 9x, or Windows
172 NT? 175 NT?
173 96: Where can I get Emacs for my PC running OS/2? 176 96: Where can I get Emacs for my PC running OS/2?
174 97: Where can I get Emacs for my Atari ST? 177 97: Where can I get Emacs for my Atari ST?
175 98: Where can I get Emacs for my Amiga? 178 98: Where can I get Emacs for my Amiga?
176 99: Where can I get Emacs for NeXTSTEP? 179 99: Where can I get Emacs for NeXTSTEP?
262 at the text of the answers, just type "C-x $". 265 at the text of the answers, just type "C-x $".
263 266
264 To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a 267 To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a
265 C-r if that doesn't work. Type RET to end the search. 268 C-r if that doesn't work. Type RET to end the search.
266 269
267 If you have w3-mode installed (see question 111), you can visit ftp and 270 If you have a web browser and the browse-url package configured for
268 HTTP uniform resource locators (URLs) by placing the cursor on the URL and 271 it, you can visit ftp and HTTP uniform resource locators (URLs) by
269 typing M-x w3-follow-url-at-point. 272 placing the cursor on the URL and typing M-x browse-url-at-point.
270 273
271 The FAQ is posted in five parts; if you are missing a section or would 274 The FAQ is posted in five parts; if you are missing a section or would
272 prefer to read the FAQ in a single file, see question 22. 275 prefer to read the FAQ in a single file, see question 22.
273 276
274 ------------------------------------------------------------ 277 ------------------------------------------------------------
469 years, although there may be some unintentional gaps in coverage. The 472 years, although there may be some unintentional gaps in coverage. The
470 archive is not particularly well organized or easy to retrieve individual 473 archive is not particularly well organized or easy to retrieve individual
471 postings from, but pretty much everything is there. The latest archives 474 postings from, but pretty much everything is there. The latest archives
472 are available at 475 are available at
473 476
474 ftp://ftp.gnu.org/pub/gnu/MailingListArchives/current 477 ftp://gnudist.gnu.org/pub/gnu/MailingListArchives/current
475 478
476 Web-based Usenet search services, such as DejaNews, also archive the 479 Web-based Usenet search services, such as DejaNews, also archive the
477 gnu.* groups. You can reach DejaNews at 480 gnu.* groups. You can reach DejaNews at
478 481
479 http://www.dejanews.com 482 http://www.dejanews.com
627 630
628 The Emacs Lisp Reference Manual is also available on-line, in Info 631 The Emacs Lisp Reference Manual is also available on-line, in Info
629 format. Texinfo source for the manual (along with pregenerated Info 632 format. Texinfo source for the manual (along with pregenerated Info
630 files) is available at 633 files) is available at
631 634
632 ftp://ftp.gnu.org/pub/gnu/elisp-manual-20-2.5.tar.gz 635 ftp://gnudist.gnu.org/pub/gnu/elisp-manual-20-2.5.tar.gz
633 636
634 and all mirrors of ftp.gnu.org (See question 92 for a list). See 637 and all mirrors of gnudist.gnu.org (See question 92 for a list). See
635 question 17 if you want to install the Info files, or question 18 if you 638 question 17 if you want to install the Info files, or question 18 if you
636 want to use the Texinfo source to print the manual yourself. 639 want to use the Texinfo source to print the manual yourself.
637 640
638 WWW versions of the Emacs Lisp Reference Manual are available at 641 WWW versions of the Emacs Lisp Reference Manual are available at
639 642
644 647
645 First, you must turn the Texinfo files into Info files. You may do this 648 First, you must turn the Texinfo files into Info files. You may do this
646 using the stand-alone "makeinfo" program, available as part of the latest 649 using the stand-alone "makeinfo" program, available as part of the latest
647 Texinfo package at 650 Texinfo package at
648 651
649 ftp://ftp.gnu.org/pub/gnu/texinfo-3.12.tar.gz 652 ftp://gnudist.gnu.org/pub/gnu/texinfo-3.12.tar.gz
650 653
651 and all mirrors of ftp.gnu.org (see question 92 for a list). 654 and all mirrors of gnudist.gnu.org (see question 92 for a list).
652 655
653 For information about the Texinfo format, read the Texinfo manual which 656 For information about the Texinfo format, read the Texinfo manual which
654 comes with Emacs. This manual also comes installed in Info format, so 657 comes with Emacs. This manual also comes installed in Info format, so
655 you can read it on-line. 658 you can read it on-line.
656 659
663 2. Edit the file info/dir in the installed Emacs distribution, and add a 666 2. Edit the file info/dir in the installed Emacs distribution, and add a
664 line for the top level node in the Info package that you are 667 line for the top level node in the Info package that you are
665 installing. Follow the examples already in this file. The format is: 668 installing. Follow the examples already in this file. The format is:
666 669
667 * Topic: (relative-pathname). Short description of topic. 670 * Topic: (relative-pathname). Short description of topic.
671
672 If (as it should have done) the Texinfo file used the @direntry
673 command, you can run the "install-info" command from the current
674 Texinfo distribution to do this automatically -- see the example in
675 the top-level Makefile in the Emacs source.
668 676
669 If you want to install Info files and you don't have the necessary 677 If you want to install Info files and you don't have the necessary
670 privileges, you have several options: 678 privileges, you have several options:
671 679
672 * Info files don't actually need to be installed before being used. You 680 * Info files don't actually need to be installed before being used. You
718 726
719 5. Print the DVI file XXX.dvi in the normal way for printing DVI files at 727 5. Print the DVI file XXX.dvi in the normal way for printing DVI files at
720 your site. 728 your site.
721 729
722 To get more general instructions, retrieve the latest Texinfo package 730 To get more general instructions, retrieve the latest Texinfo package
723 mentioned in question 17. 731 mentioned in question 17. The "texi2dvi" command from it will perform
732 the above steps 1 to 4 for you.
724 733
725 19: Can I view Info files without using Emacs? 734 19: Can I view Info files without using Emacs?
726 735
727 Yes. Here are some alternative programs: 736 Yes. Here are some alternative programs:
728 737
730 Texinfo package. See question 17 for details. 739 Texinfo package. See question 17 for details.
731 740
732 * Xinfo, a stand-alone version of the Info program that runs under X 741 * Xinfo, a stand-alone version of the Info program that runs under X
733 Windows. You can get it at 742 Windows. You can get it at
734 743
735 ftp://ftp.gnu.org/pub/gnu/xinfo-1.01.01.tar.gz 744 ftp://gnudist.gnu.org/pub/gnu/xinfo-1.01.01.tar.gz
736 745
737 and all mirrors of ftp.gnu.org (See question 92 for a list). 746 and all mirrors of gnudist.gnu.org (See question 92 for a list).
738 747
739 * Tkinfo, an Info viewer that runs under X Windows and uses Tcl/Tk. You 748 * Tkinfo, an Info viewer that runs under X Windows and uses Tcl/Tk. You
740 can get Tkinfo at 749 can get Tkinfo at
741 750
742 http://math-www.uni-paderborn.de/~axel/tkinfo/ 751 http://math-www.uni-paderborn.de/~axel/tkinfo/
760 UNIX-compatible software system with BYTE editors 769 UNIX-compatible software system with BYTE editors
761 LPF -- Why you should join the League for Programming Freedom 770 LPF -- Why you should join the League for Programming Freedom
762 MACHINES -- Status of Emacs on Various Machines and Systems 771 MACHINES -- Status of Emacs on Various Machines and Systems
763 MAILINGLISTS -- GNU Project Electronic Mailing Lists 772 MAILINGLISTS -- GNU Project Electronic Mailing Lists
764 NEWS -- Emacs news, a history of user-visible changes 773 NEWS -- Emacs news, a history of user-visible changes
774 PROBLEMS -- Known problems with building and running Emacs in various
775 situations, often with workarounds.
765 SERVICE -- GNU Service Directory 776 SERVICE -- GNU Service Directory
766 SUN-SUPPORT -- including "Using Emacstool with GNU Emacs" 777 SUN-SUPPORT -- including "Using Emacstool with GNU Emacs"
767 778
768 Latest versions of the above files also available at 779 Latest versions of some of the above files are also available at
769 780
770 ftp://ftp.gnu.org/pub/gnu/GNUinfo/ 781 ftp://gnudist.gnu.org/pub/gnu/GNUinfo/
771 782
772 More GNU information, including back issues of the "GNU's Bulletin", are at 783 More GNU information, including back issues of the "GNU's Bulletin", are at
773 784
774 http://www.gnu.org/bulletins/bulletins.html 785 http://www.gnu.org/bulletins/bulletins.html
775 http://www.cs.pdx.edu/~trent/gnu/gnu.html 786 http://www.cs.pdx.edu/~trent/gnu/gnu.html
779 See question 84 for some basic installation hints, and question 83 if you 790 See question 84 for some basic installation hints, and question 83 if you
780 have problems with the installation. 791 have problems with the installation.
781 792
782 The file etc/SERVICE (see question 4 if you're not sure where that is) 793 The file etc/SERVICE (see question 4 if you're not sure where that is)
783 lists companies and individuals willing to sell you help in installing or 794 lists companies and individuals willing to sell you help in installing or
784 using Emacs. An up-to-date version this file is available on ftp.gnu.org 795 using Emacs. An up-to-date version this file is available on gnudist.gnu.org
785 (see question 20). 796 (see question 20).
786 797
787 22: Where can I get the latest version of this document (the FAQ list)? 798 22: Where can I get the latest version of this document (the FAQ list)?
788 799
789 The Emacs FAQ is available in several ways: 800 The Emacs FAQ is available in several ways:
878 For some not-so-serious alternative reasons for Emacs to have that name, 889 For some not-so-serious alternative reasons for Emacs to have that name,
879 check out etc/JOKES (see question 4). 890 check out etc/JOKES (see question 4).
880 891
881 24: What is the latest version of Emacs? 892 24: What is the latest version of Emacs?
882 893
883 Emacs 20.3 is the current version as of this writing. 894 Emacs 20.4 is the current version as of this writing.
884 895
885 25: What is different about Emacs 20? 896 25: What is different about Emacs 20?
886 897
887 To find out what has changed in recent versions, type C-h n (M-x 898 To find out what has changed in recent versions, type C-h n (M-x
888 view-emacs-news). The oldest changes are at the bottom of the file, so 899 view-emacs-news). The oldest changes are at the bottom of the file, so
897 of MULE code for languages that use non-Latin characters, the "customize" 908 of MULE code for languages that use non-Latin characters, the "customize"
898 facility for modifying variables without having to use Lisp, and 909 facility for modifying variables without having to use Lisp, and
899 automatic conversion of files from Macintosh, Microsoft, and Unix 910 automatic conversion of files from Macintosh, Microsoft, and Unix
900 platforms. 911 platforms.
901 912
902 A number of older Lisp packages, such as Gnus, Supercite and the 913 Many Lisp packages have been updated and enhanced for Emacs 20.
903 calendar/diary, have been updated and enhanced to work with Emacs 20, and
904 are now included with the standard distribution.
905 914
906 915
907 Common Things People Want To Do 916 Common Things People Want To Do
908 917
909 26: How do I set up a .emacs file properly? 918 26: How do I set up a .emacs file properly?
914 because it causes confusing non-standard behavior. Then they send 923 because it causes confusing non-standard behavior. Then they send
915 questions to help-gnu-emacs asking why Emacs isn't behaving as 924 questions to help-gnu-emacs asking why Emacs isn't behaving as
916 documented. :-) 925 documented. :-)
917 926
918 Emacs 20 includes the new "customize" facility, which can be invoked 927 Emacs 20 includes the new "customize" facility, which can be invoked
919 using M-x customize RET. This allows users who are unfamiliar with Emacs 928 using M-x customize RET or via the Help menu. This allows users who are
920 Lisp to modify their .emacs files in a relatively straightforward way, 929 unfamiliar with Emacs Lisp to modify their .emacs files in a relatively
921 using menus rather than Lisp code. Not all packages support Customize as 930 straightforward way, using menus rather than Lisp code. While all the
922 of this writing, but the number is growing fairly steadily. 931 packages included with Emacs (are meant to) support Customize now,
932 packages from other sources may not.
923 933
924 While Customize might indeed make it easier to configure Emacs, consider 934 While Customize might indeed make it easier to configure Emacs, consider
925 taking a bit of time to learn Emacs Lisp and modifying your .emacs 935 taking a bit of time to learn Emacs Lisp and modifying your .emacs
926 directly. Simple configuration options are described rather completely in 936 directly. Simple configuration options are described rather completely in
927 the "Init File" section of the on-line manual, for users interested in 937 the "Init File" section of the on-line manual, for users interested in
936 buffer will display the Lisp code from your .emacs file that caused the 946 buffer will display the Lisp code from your .emacs file that caused the
937 problem. 947 problem.
938 948
939 You can also evaluate an individual function or argument to a function in 949 You can also evaluate an individual function or argument to a function in
940 your .emacs file by moving the cursor to the end of the function or 950 your .emacs file by moving the cursor to the end of the function or
941 argument and typing "C-x C-e" (M-x eval-last-sexp). 951 argument and typing "C-x C-e" (M-x eval-last-sexp). "C-M-x" (M-x
952 eval-defun) is particularly useful for re-evaluating "defvar" and
953 "customize" forms.
942 954
943 Use "C-h v" (M-x describe-variable) to check the value of variables which 955 Use "C-h v" (M-x describe-variable) to check the value of variables which
944 you are trying to set or use. 956 you are trying to set or use.
945 957
946 28: How do I make Emacs display the current line (or column) number? 958 28: How do I make Emacs display the current line (or column) number?
947 959
948 To have Emacs automatically display the current line number of the point 960 To toggle having Emacs automatically display the current line number of the
949 in the mode line, do "M-x line-number-mode". You can also put the form 961 point in the mode line, do "M-x line-number-mode". (This option is on by
950 962 default.) Note that Emacs will not display the line number if the buffer is
951 (setq line-number-mode t) 963 larger than the value of the variable line-number-display-limit.
952
953 in your .emacs file to achieve this whenever you start Emacs. Note that
954 Emacs will not display the line number if the buffer is larger than the
955 value of the variable line-number-display-limit.
956 964
957 As of Emacs 20, you can similarly display the current column with "M-x 965 As of Emacs 20, you can similarly display the current column with "M-x
958 column-number-mode", or by putting the form 966 column-number-mode", by putting the form
959 967
960 (setq column-number-mode t) 968 (setq column-number-mode t)
961 969
962 in your .emacs file. 970 in your .emacs file or by using Customize.
963 971
964 The "%c" format specifier in the variable mode-line-format will insert 972 The "%c" format specifier in the variable mode-line-format will insert
965 the current column's value into the mode line. See the documentation for 973 the current column's value into the mode line. See the documentation for
966 mode-line-format (using "C-h v mode-line-format RET") for more 974 mode-line-format (using "C-h v mode-line-format RET") for more
967 information on how to set and use this variable. 975 information on how to set and use this variable.
969 Users of all Emacs versions can display the current column using Per 977 Users of all Emacs versions can display the current column using Per
970 Abrahamsen's <abraham@iesd.auc.dk> "column" package. See question 90 for 978 Abrahamsen's <abraham@iesd.auc.dk> "column" package. See question 90 for
971 instructions on how to get it. 979 instructions on how to get it.
972 980
973 None of the vi emulation modes provide the "set number" capability of vi 981 None of the vi emulation modes provide the "set number" capability of vi
974 (as far as we know). 982 (as far as we know) but Kyle Jones's setnu.el package implements such a
983 feature.
975 984
976 29: How can I modify the titlebar to contain the current filename? 985 29: How can I modify the titlebar to contain the current filename?
977 986
978 The contains of an Emacs frame's titlebar is controlled by the variable 987 The contains of an Emacs frame's titlebar is controlled by the variable
979 frame-title-format, which has the same structure as the variable 988 frame-title-format, which has the same structure as the variable
1001 (condition-case () 1010 (condition-case ()
1002 (quietly-read-abbrev-file) 1011 (quietly-read-abbrev-file)
1003 (file-error nil)) 1012 (file-error nil))
1004 1013
1005 (add-hook 'XXX-mode-hook 1014 (add-hook 'XXX-mode-hook
1006 (function 1015 (lambda ()
1007 (lambda () 1016 (setq abbrev-mode t)))
1008 (setq abbrev-mode t))))
1009 1017
1010 31: How do I turn on auto-fill mode by default? 1018 31: How do I turn on auto-fill mode by default?
1011 1019
1012 To turn on auto-fill mode just once for one buffer, use "M-x 1020 To turn on auto-fill mode just once for one buffer, use "M-x
1013 auto-fill-mode". 1021 auto-fill-mode".
1016 for that mode. For example, to turn on auto-fill mode for all text 1024 for that mode. For example, to turn on auto-fill mode for all text
1017 buffers, including the following in your .emacs file: 1025 buffers, including the following in your .emacs file:
1018 1026
1019 (add-hook 'text-mode-hook 'turn-on-auto-fill) 1027 (add-hook 'text-mode-hook 'turn-on-auto-fill)
1020 1028
1029 You can also do this via the Help -> Options menu, which runs the command
1030 toggle-text-mode-auto-fill.
1031
1021 If you want auto-fill mode on in all major modes, do this: 1032 If you want auto-fill mode on in all major modes, do this:
1022 1033
1023 (setq-default auto-fill-function 'do-auto-fill) 1034 (setq-default auto-fill-function 'do-auto-fill)
1024 1035
1025 32: How do I make Emacs use a certain major mode for certain files? 1036 32: How do I make Emacs use a certain major mode for certain files?
1026 1037
1027 If you want to use XXX mode for all files which end with the extension 1038 If you want to use XXX mode for all files which end with the extension
1028 ".YYY", this will do it for you: 1039 ".YYY", this will do it for you:
1029 1040
1030 (setq auto-mode-alist (cons '("\\.YYY\\'" . XXX-mode) auto-mode-alist)) 1041 (add-to-list 'auto-mode-alist '("\\.YYY\\'" . XXX-mode))
1031 1042
1032 Otherwise put this somewhere in the first line of any file you want to 1043 Otherwise put this somewhere in the first line of any file you want to
1033 edit in XXX mode (in the second line, if the first line begins with 1044 edit in XXX mode (in the second line, if the first line begins with
1034 "#!"): 1045 "#!"):
1035 1046
1083 If you are using a windowing system such as X, you can cause the region 1094 If you are using a windowing system such as X, you can cause the region
1084 to be highlighted when the mark is active by including 1095 to be highlighted when the mark is active by including
1085 1096
1086 (transient-mark-mode t) 1097 (transient-mark-mode t)
1087 1098
1088 in your .emacs file. (Also see question 66.) 1099 in your .emacs file, using Customize or via the Help->Options menu.
1100 (Also see question 66.)
1089 1101
1090 35: How do I control Emacs's case-sensitivity when searching/replacing? 1102 35: How do I control Emacs's case-sensitivity when searching/replacing?
1091 1103
1092 For searching, the value of the variable case-fold-search determines 1104 For searching, the value of the variable case-fold-search determines
1093 whether they are case sensitive: 1105 whether they are case sensitive:
1094 1106
1095 (setq case-fold-search nil) ; make searches case sensitive 1107 (setq case-fold-search nil) ; make searches case sensitive
1096 (setq case-fold-search t) ; make searches case insensitive 1108 (setq case-fold-search t) ; make searches case insensitive
1097 1109
1098 Similarly, for replacing the variable case-replace determines whether 1110 To change this or similar variables during an Emacs session, use
1111 M-x set-variable.
1112
1113 Similarly, for replacing, the variable case-replace determines whether
1099 replacements preserve case. 1114 replacements preserve case.
1100 1115
1101 To change the case sensitivity just for one major mode, use the major 1116 To change the case sensitivity just for one major mode, use the major
1102 mode's hook. For example: 1117 mode's hook. For example:
1103 1118
1104 (add-hook 'XXX-mode-hook 1119 (add-hook 'XXX-mode-hook
1105 (function 1120 (lambda ()
1106 (lambda () 1121 (setq case-fold-search nil)))
1107 (setq case-fold-search nil))))
1108 1122
1109 36: How do I make Emacs wrap words for me? 1123 36: How do I make Emacs wrap words for me?
1110 1124
1111 Use auto-fill mode, activated by typing "M-x auto-fill-mode". The 1125 Use auto-fill mode, activated by typing "M-x auto-fill-mode". The
1112 default maximum line width is 70, determined by the variable fill-column. 1126 default maximum line width is 70, determined by the variable fill-column.
1193 execution of arbitrary Emacs Lisp forms and does not require the client 1207 execution of arbitrary Emacs Lisp forms and does not require the client
1194 program to wait for completion. 1208 program to wait for completion.
1195 1209
1196 The alpha version of an enhanced version of gnuserv is available at 1210 The alpha version of an enhanced version of gnuserv is available at
1197 1211
1198 ftp://ftp.wellfleet.com/netman/psmith/emacs/gnuserv-2.1alpha.tar.gz 1212 ftp://ftp.splode.com/pub/users/friedman/packages/fgnuserv-1.0.tar.gz
1199 1213
1200 41: How do I make Emacs recognize my compiler's funny error messages? 1214 41: How do I make Emacs recognize my compiler's funny error messages?
1201 1215
1202 The variable compilation-error-regexp-alist helps control how Emacs 1216 The variable compilation-error-regexp-alist helps control how Emacs
1203 parses your compiler output. It is a list of triples of the form: 1217 parses your compiler output. It is a list of triples of the form:
1213 the comments included for this variable are quite useful -- the regular 1227 the comments included for this variable are quite useful -- the regular
1214 expressions required for your compiler's output may be very close to one 1228 expressions required for your compiler's output may be very close to one
1215 already provided. Once you have determined the proper regexps, use the 1229 already provided. Once you have determined the proper regexps, use the
1216 following to inform Emacs of your changes: 1230 following to inform Emacs of your changes:
1217 1231
1218 (setq compilation-error-regexp-alist 1232 (add-to-list 'compilation-error-regexp-alist
1219 (cons '(REGEXP FILE-IDX LINE-IDX) 1233 '(REGEXP FILE-IDX LINE-IDX))
1220 compilation-error-regexp-alist)) 1234
1221 1235 42: How do I indent C switch statements like this?
1222 42: How do I indent switch statements like this?
1223 1236
1224 Many people want to indent their switch statements like this: 1237 Many people want to indent their switch statements like this:
1225 1238
1226 f() 1239 f()
1227 { 1240 {
1269 1282
1270 M-x overwrite-mode (a minor mode). This toggles overwrite-mode on and 1283 M-x overwrite-mode (a minor mode). This toggles overwrite-mode on and
1271 off, so exiting from overwrite-mode is as easy as another M-x 1284 off, so exiting from overwrite-mode is as easy as another M-x
1272 overwrite-mode. 1285 overwrite-mode.
1273 1286
1274 On some workstations, the "Insert" key toggles overwrite-mode on and off. 1287 On some systems the "Insert" key toggles overwrite-mode on and off.
1275 1288
1276 45: How do I stop Emacs from beeping on a terminal? 1289 45: How do I stop Emacs from beeping on a terminal?
1277 1290
1278 Martin R. Frank <martin@cc.gatech.edu> writes: 1291 Martin R. Frank <martin@cc.gatech.edu> writes:
1279 1292
1286 ... :vb=: ... 1299 ... :vb=: ...
1287 1300
1288 And evaluate the following Lisp form: 1301 And evaluate the following Lisp form:
1289 1302
1290 (setq visible-bell t) 1303 (setq visible-bell t)
1304
1305 There is also a way to turn off _all_ effects of a bell, by defining
1306 a custom `ring-bell-function' that does nothing.
1291 1307
1292 46: How do I turn down the bell volume in Emacs running under X Windows? 1308 46: How do I turn down the bell volume in Emacs running under X Windows?
1293 1309
1294 You can adjust the bell volume and duration for all programs with the 1310 You can adjust the bell volume and duration for all programs with the
1295 shell command xset. 1311 shell command xset.
1304 b [vol [pitch [dur]]] b on 1320 b [vol [pitch [dur]]] b on
1305 1321
1306 47: How do I tell Emacs to automatically indent a new line to the 1322 47: How do I tell Emacs to automatically indent a new line to the
1307 indentation of the previous line? 1323 indentation of the previous line?
1308 1324
1309 Such behavior is automatic in Emacs 20. From the NEWS file for Emacs 1325 Such behavior is automatic in text mode in Emacs 20. From the NEWS file
1310 20.2: 1326 for Emacs 20.2:
1311 1327
1312 ** In Text mode, now only blank lines separate paragraphs. This makes 1328 ** In Text mode, now only blank lines separate paragraphs. This makes
1313 it possible to get the full benefit of Adaptive Fill mode in Text mode, 1329 it possible to get the full benefit of Adaptive Fill mode in Text mode,
1314 and other modes derived from it (such as Mail mode). TAB in Text mode 1330 and other modes derived from it (such as Mail mode). TAB in Text mode
1315 now runs the command indent-relative; this makes a practical difference 1331 now runs the command indent-relative; this makes a practical difference
1342 cursor) is located over one. To load paren automatically, include the 1358 cursor) is located over one. To load paren automatically, include the
1343 line 1359 line
1344 1360
1345 (require 'paren) 1361 (require 'paren)
1346 1362
1347 in your .emacs file. Alan Shutko <shutkoa@ugsolutions.com> reports that 1363 in your .emacs file. As of version 20.1, you must instead call
1348 as of version 20.1, you must also call show-paren-mode in your .emacs 1364 show-paren-mode in your .emacs file:
1349 file:
1350 1365
1351 (show-paren-mode 1) 1366 (show-paren-mode 1)
1367
1368 and the "require" is redundant.
1352 1369
1353 The "customize" facility will let you turn on show-paren-mode. Use M-x 1370 The "customize" facility will let you turn on show-paren-mode. Use M-x
1354 customize-group RET paren-showing RET. From within customize, you can 1371 customize-group RET paren-showing RET. From within customize, you can
1355 also go directly to the "paren-showing" group. 1372 also go directly to the "paren-showing" group.
1356 1373
1365 can train it to skip over balanced brackets and braces at the same time 1382 can train it to skip over balanced brackets and braces at the same time
1366 by modifying the syntax table.) 1383 by modifying the syntax table.)
1367 1384
1368 * Here is some Emacs Lisp that will make the % key show the matching 1385 * Here is some Emacs Lisp that will make the % key show the matching
1369 parenthesis, like in vi. In addition, if the cursor isn't over a 1386 parenthesis, like in vi. In addition, if the cursor isn't over a
1370 parenthesis, it simply inserts a % like normal. 1387 parenthesis, it simply inserts a % like normal. (`Parenthesis' actually
1388 includes and character with `open' or `close' syntax, which usually means
1389 "()[]{}".)
1371 1390
1372 ;; By an unknown contributor 1391 ;; By an unknown contributor
1373 1392
1374 (global-set-key "%" 'match-paren) 1393 (global-set-key "%" 'match-paren)
1375 1394
1388 1407
1389 50: Is there an equivalent to the `.' (dot) command of vi? 1408 50: Is there an equivalent to the `.' (dot) command of vi?
1390 1409
1391 (`.' is the redo command in vi. It redoes the last insertion/deletion.) 1410 (`.' is the redo command in vi. It redoes the last insertion/deletion.)
1392 1411
1393 The next version of 1412 In Emacs 20.3 and later, use the C-x z ("repeat") command to repeat `simple
1394 1413 commands'.
1395 No, not really, because Emacs doesn't have a special insertion mode. 1414
1396 1415 Otherwise you can type "C-x ESC ESC" (repeat-complex-command) to reinvoke
1397 You can type "C-x ESC ESC" (repeat-complex-command) to reinvoke commands 1416 commands that used the minibuffer to get arguments. In
1398 that used the minibuffer to get arguments. In repeat-complex-command you 1417 repeat-complex-command you can type M-p and M-n to scan through all the
1399 can type M-p and M-n to scan through all the different complex commands 1418 different complex commands you've typed.
1400 you've typed.
1401 1419
1402 To repeat a set of commands, use keyboard macros. (See "Keyboard Macros" 1420 To repeat a set of commands, use keyboard macros. (See "Keyboard Macros"
1403 in the on-line manual.) 1421 in the on-line manual.)
1404 1422
1405 If you're really desperate for the `.' command, use VIPER, which comes 1423 VIPER, which comes with Emacs, emulates vi, including `.'. (See question
1406 with Emacs, and which appears to support it. (See question 107.) 1424 107.)
1407 1425
1408 51: What are the valid X resource settings (i.e., stuff in .Xdefaults)? 1426 51: What are the valid X resource settings (i.e., stuff in .Xdefaults)?
1409 1427
1410 See Emacs man page, or "Resources X" in the on-line manual. 1428 See Emacs man page, or "Resources X" in the on-line manual.
1411 1429
1461 RET". 1479 RET".
1462 1480
1463 To do this to a region, use "string-rectangle" ("C-x r t"). Set the mark 1481 To do this to a region, use "string-rectangle" ("C-x r t"). Set the mark
1464 (`C-SPC') at the beginning of the first line you want to prefix, move the 1482 (`C-SPC') at the beginning of the first line you want to prefix, move the
1465 cursor to last line to be prefixed, and type "C-x r t > RET". To do this 1483 cursor to last line to be prefixed, and type "C-x r t > RET". To do this
1466 for the whole buffer, type "C-x h C-x r t > RET". 1484 for the whole buffer, type "C-x h C-x r t > RET". In Emacs 20.3 and
1485 later, this will affect only the current region if Transient Mark mode is
1486 on (see NEWS via C-h N).
1467 1487
1468 If you are trying to prefix a yanked mail message with '>', you might 1488 If you are trying to prefix a yanked mail message with '>', you might
1469 want to set the variable mail-yank-prefix. Better yet, get the Supercite 1489 want to set the variable mail-yank-prefix. Better yet, get the Supercite
1470 package (see question 105), which provides flexible citation for yanked 1490 package (see question 105), which provides flexible citation for yanked
1471 mail and news messages. 1491 mail and news messages.
1523 command dired-do-query-replace, which allows users to replace regular 1543 command dired-do-query-replace, which allows users to replace regular
1524 expressions in multiple files. 1544 expressions in multiple files.
1525 1545
1526 61: Where is the documentation for "etags"? 1546 61: Where is the documentation for "etags"?
1527 1547
1528 The "etags" man page should be in the same place as the "emacs" man page. 1548 "etags" is documented in the Tags node of the Emacs manual. The "etags"
1549 man page should be in the same place as the "emacs" man page.
1529 1550
1530 Quick command-line switch descriptions are also available. For example, 1551 Quick command-line switch descriptions are also available. For example,
1531 "etags -H". 1552 "etags -H".
1532 1553
1533 62: How do I disable backup files? 1554 62: How do I disable backup files?
1547 1568
1548 (setq initial-dired-omit-files-p t) 1569 (setq initial-dired-omit-files-p t)
1549 1570
1550 If you're tired of seeing backup files whenever you do an "ls" at the 1571 If you're tired of seeing backup files whenever you do an "ls" at the
1551 Unix shell, try GNU ls with the "-B" option. GNU ls is part of the GNU 1572 Unix shell, try GNU ls with the "-B" option. GNU ls is part of the GNU
1552 fileutils package, available at mirrors of ftp.gnu.org (see question 92). 1573 fileutils package, available at mirrors of gnudist.gnu.org (see question 92).
1553 1574
1554 To disable or change how backups are made, see "Backup Names" in the 1575 To disable or change how backups are made, see "Backup Names" in the
1555 on-line manual. 1576 on-line manual.
1556 1577
1557 63: How do I disable auto-save-mode? 1578 63: How do I disable auto-save-mode?
1636 To move a menu option from one position to another, simply evaluate 1657 To move a menu option from one position to another, simply evaluate
1637 define-key-after with the appropriate final argument. 1658 define-key-after with the appropriate final argument.
1638 1659
1639 More detailed information -- and more examples of how to create and 1660 More detailed information -- and more examples of how to create and
1640 modify menu options -- are in the Emacs Lisp Reference Manual, under 1661 modify menu options -- are in the Emacs Lisp Reference Manual, under
1641 "Keymaps." (See question 16 for information on this manual.) 1662 "Menu Keymaps." (See question 16 for information on this manual.)
1663
1664 Note that Emacs 20.3 introduced a better (`extended') format for menu
1665 items, described in the NEWS file and the Lisp Manual. The "easymenu"
1666 package provides support for defining menus conveniently with some
1667 portability amongst Emacs versions.
1642 1668
1643 65: How do I delete menus and menu options? 1669 65: How do I delete menus and menu options?
1644 1670
1645 The simplest way to remove a menu is to set its keymap to nil. For 1671 The simplest way to remove a menu is to set its keymap to nil. For
1646 example, to delete the "Words" menu (from question 64), use: 1672 example, to delete the "Words" menu (from question 64), use:
1667 1693
1668 To turn font-lock mode on within an existing buffer, use "M-x 1694 To turn font-lock mode on within an existing buffer, use "M-x
1669 font-lock-mode RET". 1695 font-lock-mode RET".
1670 1696
1671 To automatically invoke font-lock mode when a particular major mode is 1697 To automatically invoke font-lock mode when a particular major mode is
1672 invoked, set the major mode's hook. For example, to fontify all c-mode 1698 invoked, set the major mode's hook or define font-lock-global-modes as a
1673 buffers, add the following to your .emacs file: 1699 list with the mode name as an element. For example, to fontify all
1700 c-mode buffers, add the following to your .emacs file:
1674 1701
1675 (add-hook 'c-mode-hook 'turn-on-font-lock) 1702 (add-hook 'c-mode-hook 'turn-on-font-lock)
1676 1703
1677 To automatically invoke font-lock mode for all major modes, you can turn 1704 To automatically invoke font-lock mode for all major modes, you can turn
1678 on global-font-lock mode by including the following line in your .emacs 1705 on global-font-lock mode by including the following line in your .emacs
1679 file: 1706 file (or use Custom):
1680 1707
1681 (global-font-lock-mode 1) 1708 (global-font-lock-mode 1)
1682 1709
1683 This instructs Emacs to turn on font-lock mode in those buffers for which 1710 This instructs Emacs to turn on font-lock mode in those buffers for which
1684 a font-lock mode definition has been provided (in the variable 1711 a font-lock mode definition has been provided (in the variable
1685 font-lock-global-modes). If you edit a file in pie-ala-mode, and no 1712 font-lock-global-modes or via the variable font-lock-defaults-alist). If
1686 font-lock definitions have been provided for pie-ala files, then the 1713 you edit a file in pie-ala-mode, and no font-lock definitions have been
1687 above setting will have no effect on that particular buffer. 1714 provided for pie-ala files, then the above setting will have no effect on
1715 that particular buffer.
1688 1716
1689 Highlighting with font-lock mode can take quite a while, and thus 1717 Highlighting with font-lock mode can take quite a while, and thus
1690 different levels of decoration are available, from slight to gaudy. To 1718 different levels of decoration are available, from slight to gaudy. To
1691 control how decorated your buffers should become, set the value of 1719 control how decorated your buffers should become, set the value of
1692 font-lock-maximum-decoration in your .emacs file, with a nil value 1720 font-lock-maximum-decoration in your .emacs file, with a nil value
1711 1739
1712 Also see the documentation for the function font-lock-mode, available by 1740 Also see the documentation for the function font-lock-mode, available by
1713 typing C-h f font-lock-mode ("M-x describe-function RET font-lock-mode 1741 typing C-h f font-lock-mode ("M-x describe-function RET font-lock-mode
1714 RET"). 1742 RET").
1715 1743
1716 For more information on font-lock mode, take a look at the font-lock mode 1744 For more information on font-lock mode, particularly adding new patterns,
1717 FAQ, maintained by Jari Aalto <jari.aalto@ntc.nokia.com> at 1745 see the Lisp Reference Manual and the commentary in the source
1718 1746 font-lock.el, which you can find in Emacs 20 (if it is installed) using,
1719 ftp://cs.uta.fi/pub/ssjaaa/ema-font.gui 1747 say, M-x find-function font-lock-mode.
1720 1748
1721 To print buffers with the faces (i.e., colors and fonts) intact, use 1749 To print buffers with the faces (i.e., colors and fonts) intact, use
1722 "M-x ps-print-buffer-with-faces" or "M-x ps-print-region-with-faces". 1750 "M-x ps-print-buffer-with-faces" or "M-x ps-print-region-with-faces".
1723 1751
1724 67: How can I force Emacs to scroll only one line when I move past the 1752 67: How can I force Emacs to scroll only one line when I move past the
1744 When OFF, typed text is just inserted at point. 1772 When OFF, typed text is just inserted at point.
1745 1773
1746 This mode also allows you to delete (not kill) the highlighted region by 1774 This mode also allows you to delete (not kill) the highlighted region by
1747 pressing DEL. 1775 pressing DEL.
1748 1776
1749 69: How can I edit MS-DOS files using Emacs? 1777 69: How can I edit MS-DOS-style text files using Emacs?
1750 1778
1751 As of Emacs 20, detection and handling of MS-DOS (and Windows) files is 1779 As of Emacs 20, detection and handling of MS-DOS (and Windows) files is
1752 performed transparently. You can open MS-DOS files on a Unix system, edit 1780 performed transparently. You can open an MS-DOS file on a Unix system
1753 it, and save it without having to worry about the file format. 1781 (and vice versa), edit it, and save it without having to worry about the
1782 file format. To save it with a different end-of-line convention use
1783 C-x RET c to specify a new coding system such as undecided-unix.
1754 1784
1755 When editing an MS-DOS style file, a backslash (\) will appear in the 1785 When editing an MS-DOS style file, a backslash (\) will appear in the
1756 mode line. 1786 mode line.
1757 1787
1758 If you are running an earlier version of Emacs, get crypt++ from the 1788 You can avoid translation of the end-of-line conventions either by
1759 Emacs Lisp Archive (see question 90). Among other things, crypt++ 1789 visiting a file using M-x find-file-literally or by setting the variable
1790 inhibit-eol-conversion to t.
1791
1792 If you are running an earlier version of Emacs, get crypt++ from
1793 ftp://ftp.cs.umb.edu/pub/misc/crypt++.el. Among other things, crypt++
1760 transparently modifies MS-DOS files as they are loaded and saved, 1794 transparently modifies MS-DOS files as they are loaded and saved,
1761 allowing you to ignore the different conventions that Unix and MS-DOS 1795 allowing you to ignore the different conventions that Unix and MS-DOS
1762 have for delineating the end of a line. 1796 have for delineating the end of a line.
1763 1797
1764 70: How can I tell Emacs to fill paragraphs with a single space after 1798 70: How can I tell Emacs to fill paragraphs with a single space after
1767 Ulrich Mueller <ulm@vsnhd1.cern.ch> suggests adding the following two 1801 Ulrich Mueller <ulm@vsnhd1.cern.ch> suggests adding the following two
1768 lines to your .emacs file: 1802 lines to your .emacs file:
1769 1803
1770 (setq sentence-end "[.?!][]\"')}]*\\($\\|[ \t]\\)[ \t\n]*") 1804 (setq sentence-end "[.?!][]\"')}]*\\($\\|[ \t]\\)[ \t\n]*")
1771 (setq sentence-end-double-space nil) 1805 (setq sentence-end-double-space nil)
1806
1807 See "Sentences" in the online manual.
1772 1808
1773 1809
1774 Bugs/Problems 1810 Bugs/Problems
1775 1811
1776 71: Does Emacs have problems with files larger than 8 megabytes? 1812 71: Does Emacs have problems with files larger than 8 megabytes?
1806 pointers. 1842 pointers.
1807 1843
1808 72: How do I get rid of ^M or echoed commands in my shell buffer? 1844 72: How do I get rid of ^M or echoed commands in my shell buffer?
1809 1845
1810 Try typing "M-x shell-strip-ctrl-m RET" while in shell-mode to make them 1846 Try typing "M-x shell-strip-ctrl-m RET" while in shell-mode to make them
1811 go away. If that doesn't work, you have several options: 1847 go away. You might add this function to comint-output-filter-functions:
1848
1849 (add-hook 'comint-output-filter-functions 'shell-strip-ctrl-m)
1850
1851 If that doesn't work, you have several options:
1812 1852
1813 For tcsh, put this in your .cshrc (or .tcshrc) file: 1853 For tcsh, put this in your .cshrc (or .tcshrc) file:
1814 1854
1815 if ($?EMACS) then 1855 if ($?EMACS) then
1816 if ("$EMACS" == t) then 1856 if ("$EMACS" == t) then
1859 You should also check for other programs named "env" in your path (e.g., 1899 You should also check for other programs named "env" in your path (e.g.,
1860 SunOS has a program named /usr/bin/env). We don't understand why this 1900 SunOS has a program named /usr/bin/env). We don't understand why this
1861 can cause a failure and don't know a general solution for working around 1901 can cause a failure and don't know a general solution for working around
1862 the problem in this case. 1902 the problem in this case.
1863 1903
1864 The "make clean" command will remove "env" and other vital programs, so
1865 be careful when using it.
1866
1867 It has been reported that this sometimes happened when Emacs was started 1904 It has been reported that this sometimes happened when Emacs was started
1868 as an X client from an xterm window (i.e., had a controlling tty) but the 1905 as an X client from an xterm window (i.e., had a controlling tty) but the
1869 xterm was later terminated. 1906 xterm was later terminated.
1870 1907
1871 See also PROBLEMS (in the top-level directory when you unpack the Emacs 1908 See also etc/PROBLEMS for other possible causes of this message.
1872 source) for other possible causes of this message.
1873 1909
1874 74: Where is the termcap/terminfo entry for terminal type "emacs"? 1910 74: Where is the termcap/terminfo entry for terminal type "emacs"?
1875 1911
1876 The termcap entry for terminal type "emacs" is ordinarily put in the 1912 The termcap entry for terminal type "emacs" is ordinarily put in the
1877 TERMCAP environment variable of subshells. It may help in certain 1913 TERMCAP environment variable of subshells. It may help in certain
2119 2155
2120 For Unix and Unix-like systems, the easiest way is often to compile it 2156 For Unix and Unix-like systems, the easiest way is often to compile it
2121 from scratch. You will need: 2157 from scratch. You will need:
2122 2158
2123 * Emacs sources. See question 92 for a list of ftp sites that make them 2159 * Emacs sources. See question 92 for a list of ftp sites that make them
2124 available. On ftp.gnu.org, the main GNU distribution site, sources are 2160 available. On gnudist.gnu.org, the main GNU distribution site, sources are
2125 available at 2161 available at
2126 2162
2127 ftp://ftp.gnu.org/pub/gnu/emacs-20.3.tar.gz 2163 ftp://gnudist.gnu.org/pub/gnu/emacs-20.4.tar.gz
2128 2164
2129 The above will obviously change as new versions of Emacs come out. For 2165 The above will obviously change as new versions of Emacs come out. For
2130 instance, when Emacs 20.4 is released, it will most probably be 2166 instance, when Emacs 20.5 is released, it will most probably be
2131 available at 2167 available at
2132 2168
2133 ftp://ftp.gnu.org/pub/gnu/emacs-20.4.tar.gz 2169 ftp://gnudist.gnu.org/pub/gnu/emacs-20.5.tar.gz
2134 2170
2135 Again, you should use one of the mirror sites in question 92 (and 2171 Again, you should use one of the mirror sites in question 92 (and
2136 adjust the URL accordingly) so as to reduce load on ftp.gnu.org. 2172 adjust the URL accordingly) so as to reduce load on gnudist.gnu.org.
2137 2173
2138 * Gzip, the GNU compression utility. You can get gzip via anonymous ftp 2174 * Gzip, the GNU compression utility. You can get gzip via anonymous ftp
2139 at mirrors of ftp.gnu.org sites; it should compile and install without 2175 at mirrors of gnudist.gnu.org sites; it should compile and install without
2140 much trouble on most systems. Once you have retrieved the Emacs 2176 much trouble on most systems. Once you have retrieved the Emacs
2141 sources, you will probably be able to uncompress them with the command 2177 sources, you will probably be able to uncompress them with the command
2142 2178
2143 gunzip --verbose emacs-20.3.tar.gz 2179 gunzip --verbose emacs-20.4.tar.gz
2144 2180
2145 changing the Emacs version (20.3), as necessary. Once gunzip has 2181 changing the Emacs version (20.4), as necessary. Once gunzip has
2146 finished doing its job, a file by the name of "emacs-20.3.tar" should 2182 finished doing its job, a file by the name of "emacs-20.4.tar" should
2147 be in your build directory. 2183 be in your build directory.
2148 2184
2149 * Tar, the "tape archiving" program, which moves multiple files into and 2185 * Tar, the "tape archiving" program, which moves multiple files into and
2150 out of archive files, or "tarfiles." All of the files comprising the 2186 out of archive files, or "tarfiles." All of the files comprising the
2151 Emacs source come in a single tarfile, and must be extracted using tar 2187 Emacs source come in a single tarfile, and must be extracted using tar
2152 before you can build Emacs. Typically, the extraction command would 2188 before you can build Emacs. Typically, the extraction command would
2153 look like 2189 look like
2154 2190
2155 tar -xvvf emacs-20.3.tar 2191 tar -xvvf emacs-20.4.tar
2156 2192
2157 The `x' indicates that we want to extract files from this tarfile, the 2193 The `x' indicates that we want to extract files from this tarfile, the
2158 two `v's force verbose output, and the `f' tells tar to use a disk 2194 two `v's force verbose output, and the `f' tells tar to use a disk
2159 file, rather than one on tape. 2195 file, rather than one on tape.
2160 2196
2161 If you're using GNU tar (available at mirrors of ftp.gnu.org), you can 2197 If you're using GNU tar (available at mirrors of gnudist.gnu.org), you can
2162 combine this step and the previous one by using the command 2198 combine this step and the previous one by using the command
2163 2199
2164 tar -zxvvf emacs-20.3.tar.gz 2200 tar -zxvvf emacs-20.4.tar.gz
2165 2201
2166 The additional `z' at the beginning of the options list tells GNU tar 2202 The additional `z' at the beginning of the options list tells GNU tar
2167 to uncompress the file with gunzip before extracting the tarfile's 2203 to uncompress the file with gunzip before extracting the tarfile's
2168 components. 2204 components.
2169 2205
2170 At this point, the Emacs sources (all 25+ megabytes of them) should be 2206 At this point, the Emacs sources (all 25+ megabytes of them) should be
2171 sitting in a directory called "emacs-20.3". On most common Unix and 2207 sitting in a directory called "emacs-20.4". On most common Unix and
2172 Unix-like systems, you should be able to compile Emacs (with X Windows 2208 Unix-like systems, you should be able to compile Emacs (with X Windows
2173 support) with the following commands: 2209 support) with the following commands:
2174 2210
2175 cd emacs-20.3 [ change directory to emacs-20.3 ] 2211 cd emacs-20.4 [ change directory to emacs-20.4 ]
2176 ./configure [ configure Emacs for your particular system ] 2212 ./configure [ configure Emacs for your particular system ]
2177 make [ use Makefile to build components, then Emacs ] 2213 make [ use Makefile to build components, then Emacs ]
2178 2214
2179 If the "make" completes successfully, the odds are fairly good that the 2215 If the "make" completes successfully, the odds are fairly good that the
2180 build has gone well. (See question 86 if you weren't successful.) 2216 build has gone well. (See question 86 if you weren't successful.)
2181 2217
2182 To install Emacs in its default directories of /usr/local/bin (binaries), 2218 To install Emacs in its default directories of /usr/local/bin (binaries),
2183 /usr/local/share/emacs/20.xx (Lisp code and support files), and 2219 /usr/local/share/emacs/20.xx (Lisp code and support files),
2220 /usr/local/libexec/CONFIGURATION/emacs/VERSION (executable files to be
2221 run by Emacs rather than users), /usr/local/man/man1 (man pages) and
2184 /usr/local/info (Info documentation), become the super-user and type 2222 /usr/local/info (Info documentation), become the super-user and type
2185 2223
2186 make install 2224 make install
2187 2225
2188 Note that "make install" will overwrite /usr/local/bin/emacs and any 2226 Note that "make install" will overwrite /usr/local/bin/emacs and any
2194 85: How do I update Emacs to the latest version? 2232 85: How do I update Emacs to the latest version?
2195 2233
2196 Follow the instructions in question 84. 2234 Follow the instructions in question 84.
2197 2235
2198 Emacs places nearly everything in version-specific directories (e.g., 2236 Emacs places nearly everything in version-specific directories (e.g.,
2199 /usr/local/share/emacs/20.3), so the only files that can be overwritten 2237 /usr/local/share/emacs/20.4), so the only files that can be overwritten
2200 when installing a new release are /usr/local/bin/emacs and the Emacs Info 2238 when installing a new release are /usr/local/bin/emacs and the Emacs Info
2201 documentation in /usr/local/info. Back up these files before you install 2239 documentation in /usr/local/info. Back up these files before you install
2202 a new release, and you shouldn't have too much trouble. 2240 a new release, and you shouldn't have too much trouble.
2203 2241
2204 86: What should I do if I have trouble building Emacs? 2242 86: What should I do if I have trouble building Emacs?
2261 First of all, you should check to make sure that the package isn't 2299 First of all, you should check to make sure that the package isn't
2262 already available. For example, typing "M-x apropos RET wordstar RET" 2300 already available. For example, typing "M-x apropos RET wordstar RET"
2263 lists all functions and variables containing the string "wordstar". 2301 lists all functions and variables containing the string "wordstar".
2264 2302
2265 It is also possible that the package is on your system, but has not been 2303 It is also possible that the package is on your system, but has not been
2266 loaded. To see which packages are available for loading, look through 2304 loaded. To see which packages are available for loading, look through your
2267 your computer's lisp directory (see question 4). The Lisp source to most 2305 computer's lisp directory (see question 4) or use the Finder (C-h p) to
2268 most packages contains a short description of how they should be loaded, 2306 search under keywords. The Lisp source to most packages contains a
2269 invoked, and configured -- so before you use or modify a Lisp package, 2307 short description of how they should be loaded, invoked, and configured --
2270 see if the author has provided any hints in the source code. 2308 so before you use or modify a Lisp package, see if the author has provided
2309 any hints in the source code.
2271 2310
2272 If a package does not come with Emacs, check the Lisp Code Directory, 2311 If a package does not come with Emacs, check the Lisp Code Directory,
2273 maintained by Dave Brennan <brennan@hal.com>. The directory is contained 2312 maintained by Dave Brennan <brennan@hal.com>. The directory is contained
2274 in the file LCD-datafile.Z, available from the Emacs Lisp Archive (see 2313 in the file LCD-datafile.Z, available from the Emacs Lisp Archive (see
2275 question 90), and is accessed using the "lispdir" package, available from 2314 question 90), and is accessed using the "lispdir" package, available from
2280 Once you have installed lispdir.el and LCD-datafile, you can use "M-x 2319 Once you have installed lispdir.el and LCD-datafile, you can use "M-x
2281 lisp-dir-apropos" to search the listing. For example, "M-x 2320 lisp-dir-apropos" to search the listing. For example, "M-x
2282 lisp-dir-apropos RET ange-ftp RET" produces this output: 2321 lisp-dir-apropos RET ange-ftp RET" produces this output:
2283 2322
2284 GNU Emacs Lisp Code Directory Apropos -- "ange-ftp" 2323 GNU Emacs Lisp Code Directory Apropos -- "ange-ftp"
2285 "~/" refers to archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/ 2324 "~/" refers to ftp.cs.ohio-state.edu:pub/gnu/emacs/elisp-archive/
2286 2325
2287 ange-ftp (4.18) 15-Jul-1992 2326 ange-ftp (4.18) 15-Jul-1992
2288 Andy Norman, <ange@hplb.hpl.hp.com> 2327 Andy Norman, <ange@hplb.hpl.hp.com>
2289 ~/packages/ange-ftp.tar.Z 2328 ~/packages/ange-ftp.tar.Z
2290 transparent FTP Support for GNU Emacs 2329 transparent FTP Support for GNU Emacs
2317 If you find Emacs Lisp code that doesn't appear in the LCD, please submit 2356 If you find Emacs Lisp code that doesn't appear in the LCD, please submit
2318 a copy to the LCD (see question 91). 2357 a copy to the LCD (see question 91).
2319 2358
2320 You can access the Emacs Lisp Archive at the following sites: 2359 You can access the Emacs Lisp Archive at the following sites:
2321 2360
2322 ftp://archive.cis.ohio-state.edu/pub/gnu/emacs/elisp-archive/ 2361 ftp://ftp.cs.ohio-state.edu/pub/gnu/emacs/elisp-archive/
2323 ftp://calypso-2.oit.unc.edu/pub/gnu/elisp-archive/ 2362 ftp://calypso-2.oit.unc.edu/pub/gnu/elisp-archive/
2324 ftp://faui43.informatik.uni-erlangen.de/pub/gnu/elisp-archive/ 2363 ftp://faui43.informatik.uni-erlangen.de/pub/gnu/elisp-archive/
2325 ftp://ftp.cs.umn.edu/pub/elisp-archive/ 2364 ftp://ftp.cs.umn.edu/pub/elisp-archive/
2326 ftp://ftp.diku.dk/pub/elisp-archive/ 2365 ftp://ftp.diku.dk/pub/elisp-archive/
2327 ftp://ftp.uni-mainz.de/pub/gnu/elisp-archive/ 2366 ftp://ftp.uni-mainz.de/pub/gnu/elisp-archive/
2342 * Any files with names ending in ".Z", ".z", or ".gz" are 2381 * Any files with names ending in ".Z", ".z", or ".gz" are
2343 compressed, so you should use "binary" mode in FTP to retrieve 2382 compressed, so you should use "binary" mode in FTP to retrieve
2344 them. You should also use binary mode whenever you retrieve any 2383 them. You should also use binary mode whenever you retrieve any
2345 files with names ending in ".elc". 2384 files with names ending in ".elc".
2346 2385
2386 Note that the archive is apparently not being maintained at the time of
2387 writing; a volunteer to take on the task would be welcome.
2388
2389 Packages which have been posted to gnu.emacs.sources should be locatable
2390 via a service like Dejanews.
2391
2347 91: How do I submit code to the Emacs Lisp Archive? 2392 91: How do I submit code to the Emacs Lisp Archive?
2348 2393
2349 Guidelines and procedures for submission to the archive can be found in 2394 Guidelines and procedures for submission to the archive can be found in
2350 the file GUIDELINES in the archive directory (see question 90). It 2395 the file GUIDELINES in the archive directory (see question 90). It
2351 covers documentation, copyrights, packaging, submission, and the Lisp 2396 covers documentation, copyrights, packaging, submission, and the Lisp
2352 Code Directory Record. Anonymous FTP uploads are not permitted. 2397 Code Directory Record. Anonymous FTP uploads are not permitted.
2353 Instead, all submissions are mailed to elisp-archive@cis.ohio-state.edu. 2398 Instead, all submissions are mailed to elisp-archive@cis.ohio-state.edu.
2354 The lispdir.el package has a function named submit-lcd-entry which will 2399 The lispdir.el package has a function named submit-lcd-entry which will
2355 help you with this. 2400 help you with this.
2356 2401
2402 See question 90 regarding non-maintenance of the archive.
2403
2357 92: Where can I get other up-to-date GNU stuff? 2404 92: Where can I get other up-to-date GNU stuff?
2358 2405
2359 The most up-to-date official GNU software is normally kept on 2406 The most up-to-date official GNU software is normally kept on
2360 ftp.gnu.org and is available at 2407 gnudist.gnu.org and is available at
2361 2408
2362 ftp://ftp.gnu.org/pub/gnu 2409 ftp://gnudist.gnu.org/pub/gnu
2363 2410
2364 Read the files etc/DISTRIB and etc/FTP for more information. 2411 Read the files etc/DISTRIB and etc/FTP for more information.
2365 2412
2366 The following sites are all mirror images of the GNU distribution area: 2413 The following sites are all mirror images of the GNU distribution area:
2367 2414
2409 ftp://labrea.stanford.edu/pub/gnu, 2456 ftp://labrea.stanford.edu/pub/gnu,
2410 ftp://mrcnext.cso.uiuc.edu/pub/gnu, 2457 ftp://mrcnext.cso.uiuc.edu/pub/gnu,
2411 ftp://vixen.cso.uiuc.edu/gnu, 2458 ftp://vixen.cso.uiuc.edu/gnu,
2412 ftp://wuarchive.wustl.edu/systems/gnu 2459 ftp://wuarchive.wustl.edu/systems/gnu
2413 2460
2414 The directory at ftp.uu.net is a mirror of ftp.gnu.org except that files 2461 The directory at ftp.uu.net is a mirror of gnudist.gnu.org except that files
2415 larger than one megabyte are split into multiple parts. If you have 2462 larger than one megabyte are split into multiple parts. If you have
2416 trouble transferring large files, you should try that site. A file 2463 trouble transferring large files, you should try that site. A file
2417 normally named "XXX" is split into files XXX-split/part[0-9][0-9], and 2464 normally named "XXX" is split into files XXX-split/part[0-9][0-9], and
2418 there will be a file named XXX-split/README which contains the list of 2465 there will be a file named XXX-split/README which contains the list of
2419 parts (especially helpful when FTP-ing by e-mail), their checksums, and 2466 parts (especially helpful when FTP-ing by e-mail), their checksums, and
2420 reassembly instructions. 2467 reassembly instructions.
2421 2468
2422 93: What is the difference between Emacs and XEmacs (formerly "Lucid 2469 93: What is the difference between Emacs and XEmacs (formerly "Lucid
2423 Emacs")? 2470 Emacs")?
2424 2471
2425 First of all, they're both GNU Emacs. XEmacs is just as much a later 2472 XEmacs is a modified version of GNU Emacs.
2426 version of GNU Emacs as the FSF-distributed version. This FAQ refers to 2473
2427 the latest version to be distributed by the FSF as "Emacs," partly 2474 This FAQ refers to the latest version to be distributed by the FSF
2428 because the XEmacs maintainers now refer to their product using the 2475 as "Emacs," partly because the XEmacs maintainers now refer to their
2429 "XEmacs" name, and partly because there isn't any accurate way to 2476 product using the "XEmacs" name, and partly because there isn't any
2430 differentiate between the two without getting mired in paragraphs of 2477 accurate way to differentiate between the two without getting mired
2431 legalese and history. 2478 in paragraphs of legalese and history.
2432 2479
2433 XEmacs, which began life as Lucid Emacs, is based on an early version of 2480 XEmacs, which began life as Lucid Emacs, is based on an early version of
2434 Emacs 19 and Epoch, an X-aware version of Emacs 18. 2481 Emacs 19 and Epoch, an X-aware version of Emacs 18.
2435 2482
2436 Emacs (i.e., the version distributed by the FSF) has a larger installed 2483 Emacs (i.e., the version distributed by the FSF) has a larger installed
2437 base, while XEmacs can do some clever tricks with X Windows, such as 2484 base and now always contains the MULE multilingual facilities. XEmacs
2438 putting arbitrary graphics in a buffer. Emacs and XEmacs each come with 2485 can do some clever tricks with X Windows, such as putting arbitrary
2439 Lisp packages that are lacking in the other; RMS says that the FSF would 2486 graphics in a buffer; similar facilities have been implemented for Emacs,
2440 include more packages that come with XEmacs, but that the XEmacs 2487 which will be integrated after version 20.4. Emacs and XEmacs each come
2441 maintainers don't always keep track of the authors of contributed code, 2488 with some Lisp packages that are lacking or more up-to-date in the other;
2442 which makes it impossible for the FSF to have certain legal papers 2489 RMS says that the FSF would include more packages that come with XEmacs,
2443 signed. (Without these legal papers, the FSF will not distribute Lisp 2490 but that the XEmacs maintainers don't always keep track of the authors of
2444 packages with Emacs.) 2491 contributed code, which makes it impossible for the FSF to have certain
2445 2492 legal papers signed. (Without these legal papers, the FSF will not
2446 Many XEmacs features have found their way into recent versions of Emacs, 2493 distribute Lisp packages with Emacs.) The two versions have some
2447 and more features can be expected in the future, but there are still many 2494 significant differences at the Lisp programming level.
2448 differences between the two.
2449
2450 The latest version of XEmacs as of this writing is 20.4; you can get it
2451 at
2452
2453 ftp://ftp.xemacs.org/pub/xemacs/xemacs-20.4.tar.gz
2454
2455 More information about XEmacs, including a list of frequently asked
2456 questions (FAQ), is available at
2457
2458 http://www.xemacs.org/
2459 2495
2460 94: Where can I get Emacs for my PC running MS-DOS? 2496 94: Where can I get Emacs for my PC running MS-DOS?
2461 2497
2462 A pre-built binary distribution of Emacs is available from the Simtel 2498 A pre-built binary distribution of Emacs is available from the Simtel
2463 archives. This version apparently works under MS-DOS and Windows (3.x, 2499 archives. This version works under MS-DOS and Windows (3.x, 9x, and NT) and
2464 95, and NT) and supports long file names. More information is availble 2500 supports long file names under Windows 9x. More information is available
2465 from: 2501 from:
2466 2502
2467 ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/emacs.README 2503 ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp/v2gnu/emacs.README
2468 2504
2469 And the binary itself is available in the files 2505 And the binary itself is available in the files
2478 Zaretskii <eliz@is.elta.co.il> and Darrel Hankerson 2514 Zaretskii <eliz@is.elta.co.il> and Darrel Hankerson
2479 <hankedr@dms.auburn.edu>, you will need the following: 2515 <hankedr@dms.auburn.edu>, you will need the following:
2480 2516
2481 Compiler: djgpp version 1.12 maint 1 or later. Djgpp 2.0 or later is 2517 Compiler: djgpp version 1.12 maint 1 or later. Djgpp 2.0 or later is
2482 recommended, since 1.x is being phased out. Djgpp 2 supports 2518 recommended, since 1.x is being phased out. Djgpp 2 supports
2483 long filenames under Windows 95. 2519 long filenames under Windows 9x.
2484 2520
2485 You can get the latest release of djgpp by retrieving 2521 You can get the latest release of djgpp by retrieving
2486 all of the files in 2522 all of the files in
2487 2523
2488 ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp 2524 ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp
2502 2538
2503 16-bit utilities can be found in GNUish: 2539 16-bit utilities can be found in GNUish:
2504 2540
2505 ftp://ftp.simtel.net/pub/simtelnet/gnu/gnuish 2541 ftp://ftp.simtel.net/pub/simtelnet/gnu/gnuish
2506 2542
2507 The files INSTALL and PROBLEMS in the top-level directory of the Emacs 2543 The files INSTALL and etc/PROBLEMS in the Emacs source contains some
2508 source contains some additional information regarding Emacs under MS-DOS. 2544 additional information regarding Emacs under MS-DOS.
2509 2545
2510 For a list of other MS-DOS implementations of Emacs (and Emacs 2546 For a list of other MS-DOS implementations of Emacs (and Emacs
2511 look-alikes), consult the list of "Emacs implementations and literature," 2547 look-alikes), consult the list of "Emacs implementations and literature,"
2512 available at 2548 available at
2513 2549
2514 ftp://rtfm.mit.edu/pub/usenet/comp.emacs/ 2550 ftp://rtfm.mit.edu/pub/usenet/comp.emacs/
2515 2551
2516 Note that while many of these programs look similar to Emacs, they often 2552 Note that while many of these programs look similar to Emacs, they often
2517 lack certain features, such as the Emacs Lisp extension language. 2553 lack certain features, particularly as the Emacs Lisp extension language.
2518 2554
2519 95: Where can I get Emacs for Microsoft Windows, Windows '95, or Windows 2555 95: Where can I get Emacs for Microsoft Windows, Windows 9x, or Windows
2520 NT? 2556 NT?
2521 2557
2522 For information on Emacs for Windows 95 and NT, read the FAQ produced by 2558 GNU Emacs has been fully ported to Windows NT and Windows 95/98.
2523 Geoff Voelker <voelker@cs.washington.edu>, available at 2559 If you have MSVC 4.0 or greater, then you can compile GNU Emacs
2560 directly from the source distribution. First read the file
2561 nt/README, and then the file nt/INSTALL, for step by step
2562 instructions on how to compile and install GNU Emacs on your system.
2563
2564 You can also download precompiled distributions of GNU Emacs from:
2565
2566 ftp://ftp.cs.washington.edu/pub/ntemacs
2567
2568 If you need the gunzip and tar utilities for unpacking distributions,
2569 you can download precompiled versions from:
2570
2571 ftp://ftp.cs.washington.edu/pub/ntemacs/utilities
2572
2573 For more information on configuring your favorite package to run with
2574 GNU Emacs on Windows NT/95/98, see the following FAQ:
2524 2575
2525 http://www.cs.washington.edu/homes/voelker/ntemacs.html 2576 http://www.cs.washington.edu/homes/voelker/ntemacs.html
2526 2577 ftp://ftp.cs.washington.edu/pub/ntemacs/docs/ntemacs.html
2527 For Windows 3.1, see question 94. 2578
2579 If you are running Windows 3.11, and if you compile GNU Emacs for MSDOS
2580 with the tools listed in the previous question, it will run under
2581 Microsoft Windows in a DOS box.
2528 2582
2529 96: Where can I get Emacs for my PC running OS/2? 2583 96: Where can I get Emacs for my PC running OS/2?
2530 2584
2531 Emacs 19.33 is ported for emx on OS/2 2.0 or 2.1, and is available at: 2585 Emacs 19.33 is ported for emx on OS/2 2.0 or 2.1, and is available at:
2532 2586
2556 menus, and multiple frames. You can get it from 2610 menus, and multiple frames. You can get it from
2557 2611
2558 ftp://next-ftp.peak.org/pub/next/apps/emacs/Emacs_for_NeXTstep.4.20a1.NIHS.b.tar.gz 2612 ftp://next-ftp.peak.org/pub/next/apps/emacs/Emacs_for_NeXTstep.4.20a1.NIHS.b.tar.gz
2559 2613
2560 100: Where can I get Emacs for my Apple computer? 2614 100: Where can I get Emacs for my Apple computer?
2615
2616
2617 There used to be a boycott of Apple because of its "look and feel"
2618 lawsuit. The lawsuit failed, and the boycott is over.
2619 Currently the GNU project treats Apple like other computer companies.
2620
2621 Since the Mac operating system is very different from Unix and GNU,
2622 support for it would be a big job. And this job would be tangential
2623 to the GNU project's goals. Meanwhile, we don't have the resources
2624 to do all we want to do on supporting Emacs for GNU-like systems.
2625 So if we had to do work on support for the Macintosh, that would
2626 directly harm the GNU project.
2627
2628 Of course, the same is true for MSDOS and Windows NT. We decided to
2629 incorporate support for those systems because the code was very modular,
2630 because volunteers not only wrote all the code but also investigate
2631 all the bugs reported on those systems, and because we hoped that we
2632 will be able to raise funds for GNU using these versions, and in this
2633 way these ports will make up for the effort that they took. (We still
2634 hope so, but it has not happened yet.)
2561 2635
2562 An unofficial port of GNU Emacs 18.59 to the Macintosh is available at a 2636 An unofficial port of GNU Emacs 18.59 to the Macintosh is available at a
2563 number of ftp sites, the home being 2637 number of ftp sites, the home being
2564 2638
2565 ftp://ftp.cs.cornell.edu/pub/parmet/Emacs-1.17.sit.bin 2639 ftp://ftp.cs.cornell.edu/pub/parmet/Emacs-1.17.sit.bin
2595 2669
2596 103: What is the IP address of XXX.YYY.ZZZ? 2670 103: What is the IP address of XXX.YYY.ZZZ?
2597 2671
2598 If you are on a Unix machine, try using the "nslookup" command, included 2672 If you are on a Unix machine, try using the "nslookup" command, included
2599 in the Berkeley BIND package. For example, to find the IP address of 2673 in the Berkeley BIND package. For example, to find the IP address of
2600 "ftp.gnu.org", you would type 2674 "gnudist.gnu.org", you would type
2601 2675
2602 nslookup ftp.gnu.org 2676 nslookup gnudist.gnu.org
2603 2677
2604 Your computer should then provide the IP address of that computer. 2678 Your computer should then provide the IP address of that computer.
2605 2679
2606 If your site's nameserver is deficient, you can use IP addresses to FTP 2680 If your site's nameserver is deficient, you can use IP addresses to FTP
2607 files. You can get this information by 2681 files. You can get this information by
2653 106: Calc -- poor man's Mathematica within Emacs 2727 106: Calc -- poor man's Mathematica within Emacs
2654 2728
2655 Author: Dave Gillespie <daveg@csvax.cs.caltech.edu> 2729 Author: Dave Gillespie <daveg@csvax.cs.caltech.edu>
2656 Latest version: 2.02f 2730 Latest version: 2.02f
2657 Anonymous FTP: 2731 Anonymous FTP:
2658 ftp://ftp.gnu.org/pub/gnu/calc-2.02f.tar.gz 2732 ftp://gnudist.gnu.org/pub/gnu/calc-2.02f.tar.gz
2659 NOTE: Unlike Wolfram Research, Dave has never threatened to sue 2733 NOTE: Unlike Wolfram Research, Dave has never threatened to sue
2660 anyone for having a program with a similar command language to 2734 anyone for having a program with a similar command language to
2661 Calc. :-) 2735 Calc. :-)
2662 2736
2663 107: VIPER -- vi emulation for Emacs 2737 107: VIPER -- vi emulation for Emacs
2672 better than the one distributed with Emacs: 2746 better than the one distributed with Emacs:
2673 2747
2674 Author: Aamod Sane <sane@cs.uiuc.edu> 2748 Author: Aamod Sane <sane@cs.uiuc.edu>
2675 Latest version: 4.3 2749 Latest version: 4.3
2676 Anonymous FTP: 2750 Anonymous FTP:
2677 ftp://archive.cis.ohio-state.edu/pub/gnu/emacs/elisp-archive/modes/vip-mode.tar.Z 2751 ftp://ftp.cs.ohio-state.edu/pub/gnu/emacs/elisp-archive/modes/vip-mode.tar.Z
2678 2752
2679 108: AUC TeX -- enhanced LaTeX mode with debugging facilities 2753 108: AUC TeX -- enhanced LaTeX mode with debugging facilities
2680 2754
2681 Authors: Kresten Krab Thorup <krab@iesd.auc.dk> 2755 Authors: Kresten Krab Thorup <krab@iesd.auc.dk>
2682 and Per Abrahamsen <abraham@iesd.auc.dk> 2756 and Per Abrahamsen <abraham@iesd.auc.dk>
2741 113: Mailcrypt -- PGP interface within Emacs mail and news 2815 113: Mailcrypt -- PGP interface within Emacs mail and news
2742 2816
2743 Authors: Patrick J. LoPresti <patl@lcs.mit.edu> and 2817 Authors: Patrick J. LoPresti <patl@lcs.mit.edu> and
2744 Jin S. Choi <jin@atype.com> 2818 Jin S. Choi <jin@atype.com>
2745 Maintainer: Len Budney <lbudney@pobox.com> 2819 Maintainer: Len Budney <lbudney@pobox.com>
2746 Latest version: 3.4 2820 Latest version: 3.5b6
2747 Anonymous FTP: 2821 Anonymous FTP:
2748 http://www.nb.net/~lbudney/linux/software/mailcrypt/mailcrypt-3.5b6.tar.gz 2822 http://www.nb.net/~lbudney/linux/software/mailcrypt/mailcrypt-3.5b6.tar.gz
2749 World Wide Web: 2823 World Wide Web:
2750 http://www.nb.net/~lbudney/linux/software/mailcrypt.html 2824 http://www.nb.net/~lbudney/linux/software/mailcrypt.html
2751 2825
2782 following "trick": First bind the key interactively, then immediately 2856 following "trick": First bind the key interactively, then immediately
2783 type "C-x ESC ESC C-a C-k C-g". Now, the command needed to bind the key 2857 type "C-x ESC ESC C-a C-k C-g". Now, the command needed to bind the key
2784 is in the kill ring, and can be yanked into your .emacs file. If the key 2858 is in the kill ring, and can be yanked into your .emacs file. If the key
2785 binding is global, no changes to the command are required. For example, 2859 binding is global, no changes to the command are required. For example,
2786 2860
2787 (global-set-key (quote [f1]) (quote help-for-help)) 2861 (global-set-key [f1] 'help-for-help)
2788 2862
2789 can be placed directly into the .emacs file. If the key binding is 2863 can be placed directly into the .emacs file. If the key binding is
2790 local, the command is used in conjunction with the "add-hook" command. 2864 local, the command is used in conjunction with the "add-hook" command.
2791 For example, in tex-mode, a local binding might be 2865 For example, in tex-mode, a local binding might be
2792 2866
2793 (add-hook 'tex-mode-hook 2867 (add-hook 'tex-mode-hook
2794 (function (lambda () 2868 (lambda ()
2795 (local-set-key (quote [f1]) (quote help-for-help)))) 2869 (local-set-key [f1] 'help-for-help)))
2796 2870
2797 NOTE: * Control characters in key sequences, in the form yanked from the 2871 NOTE: * Control characters in key sequences, in the form yanked from the
2798 kill ring are given in their graphic form -- i.e., CTRL is shown 2872 kill ring are given in their graphic form -- i.e., CTRL is shown
2799 as `^', TAB as a set of spaces (usually 8), etc. You may want to 2873 as `^', TAB as a set of spaces (usually 8), etc. You may want to
2800 convert these into their vector or string forms. 2874 convert these into their vector or string forms.
2809 * Aside from commands and "lambda lists," a vector or string also 2883 * Aside from commands and "lambda lists," a vector or string also
2810 can be bound to a key and thus treated as a macro. For example: 2884 can be bound to a key and thus treated as a macro. For example:
2811 2885
2812 (global-set-key [f10] [?\C-x?\e?\e?\C-a?\C-k?\C-g]) ;; or 2886 (global-set-key [f10] [?\C-x?\e?\e?\C-a?\C-k?\C-g]) ;; or
2813 (global-set-key [f10] "\C-x\e\e\C-a\C-k\C-g") 2887 (global-set-key [f10] "\C-x\e\e\C-a\C-k\C-g")
2888
2889 * The "kbd" macro is convenient for converting a key description in
2890 the form used in documentation or printed by C-h c (except that
2891 function key symbols must be enclosed in angle brackets). For
2892 example:
2893
2894 (global-set-key (kbd "<f1>") 'help-for-help)
2895 (global-set-key (kbd "C-h") 'help-for-help)
2896 (local-set-key (kbd "DEL") 'scroll-down)
2814 2897
2815 117: Why does Emacs say "Key sequence XXX uses invalid prefix characters"? 2898 117: Why does Emacs say "Key sequence XXX uses invalid prefix characters"?
2816 2899
2817 Usually, one of two things has happened. In one case, the control 2900 Usually, one of two things has happened. In one case, the control
2818 character in the key sequence has been misspecified (e.g. "C-f" used 2901 character in the key sequence has been misspecified (e.g. "C-f" used
2845 (cond ((string-match "\\`vt220" (or (getenv "TERM") "")) 2928 (cond ((string-match "\\`vt220" (or (getenv "TERM") ""))
2846 ;; Make vt220's "Do" key behave like M-x: 2929 ;; Make vt220's "Do" key behave like M-x:
2847 (global-set-key [do] 'execute-extended-command)) 2930 (global-set-key [do] 'execute-extended-command))
2848 )))) 2931 ))))
2849 2932
2850 For information on what Emacs does every time it is started, see the 2933 For information on what Emacs does every time it is started, see
2851 lisp/startup.el file. 2934 "Starting Up Emacs" in the Lisp Reference Manual.
2852 2935
2853 119: How do I use function keys under X Windows? 2936 119: How do I use function keys under X Windows?
2854 2937
2855 With Emacs 19, functions keys under X are bound like any other key. See 2938 With Emacs 19, functions keys under X are bound like any other key. See
2856 question 116 for details. 2939 question 116 for details.
3115 "C-", "M-", "H-", "s-", "A-", and "S-" to the symbol name. Here is how 3198 "C-", "M-", "H-", "s-", "A-", and "S-" to the symbol name. Here is how
3116 to make "Hyper-Meta-RIGHT" move forward a word: 3199 to make "Hyper-Meta-RIGHT" move forward a word:
3117 3200
3118 (global-set-key [H-M-right] 'forward-word) 3201 (global-set-key [H-M-right] 'forward-word)
3119 3202
3203 In recent Emacs versions this may also be written as:
3204
3205 (global-set-key [(hyper meta right)] 'forward-word)
3206
3120 NOTE: * Not all modifiers are permitted in all situations. Hyper, Super, 3207 NOTE: * Not all modifiers are permitted in all situations. Hyper, Super,
3121 and Alt are available only under X (provided there are such 3208 and Alt are available only under X (provided there are such
3122 keys). Non-ASCII keys and mouse events (e.g. "C-=" and 3209 keys). Non-ASCII keys and mouse events (e.g. "C-=" and
3123 "mouse-1") also fall under this category. 3210 "mouse-1") also fall under this category.
3124 3211
3181 3268
3182 Using Emacs with Alternate Character Sets 3269 Using Emacs with Alternate Character Sets
3183 3270
3184 134: How do I make Emacs display 8-bit characters? 3271 134: How do I make Emacs display 8-bit characters?
3185 3272
3186 Emacs 19 has built-in support for 8-bit characters. Here is an excerpt 3273 Emacs 19 introduced built-in support for 8-bit characters. Emacs 20 can
3187 from the "European Display" page of the on-line manual: 3274 operate similarly in Unibyte mode or else in Multibyte mode. See the
3188 3275 "International" node in the online manual, specifically "Single-Byte
3189 Some European languages use accented letters and other special symbols. 3276 European Support".
3190 The ISO 8859 Latin-1 character set defines character codes for many
3191 European languages in the range 160 to 255.
3192
3193 Emacs can display those characters according to Latin-1, provided the
3194 terminal or font in use supports them. The "M-x
3195 standard-display-european" command toggles European character display
3196 mode. With a numeric argument, "M-x standard-display-european" enables
3197 European character display if and only if the argument is positive.
3198
3199 Some operating systems let you specify the language you are using by
3200 setting a locale. Emacs handles one common special case of this: if
3201 your locale name for character types contains the string "8859-1" or
3202 "88591", Emacs automatically enables European character display mode
3203 when it starts up.
3204 3277
3205 135: How do I input 8-bit characters? 3278 135: How do I input 8-bit characters?
3206 3279
3207 Again, from the "European Display" page of the on-line manual: 3280 Again, see the "International" node of the on-line manual.
3208
3209 If you enter non-ASCII ISO Latin-1 characters often, you might find ISO
3210 Accents mode convenient. When this minor mode is enabled, the
3211 characters ``', `'', `"', `^', `/' and `~' modify the following letter
3212 by adding the corresponding diacritical mark to it, if possible. To
3213 enable or disable ISO Accents mode, use the command "M-x
3214 iso-accents-mode". This command affects only the current buffer.
3215
3216 To enter one of those six special characters, type the character,
3217 followed by a space. Some of those characters have a corresponding
3218 "dead key" accent character in the ISO Latin-1 character set; to enter
3219 that character, type the corresponding ASCII character twice. For
3220 example, `''' enters the Latin-1 character acute-accent (character code
3221 0264).
3222 3281
3223 136: Where can I get an Emacs that handles kanji, Chinese, or other 3282 136: Where can I get an Emacs that handles kanji, Chinese, or other
3224 character sets? 3283 character sets?
3225 3284
3226 Emacs 20 now includes many of the features of MULE, the Multilingual 3285 Emacs 20 now includes many of the features of MULE, the Multilingual
3278 3337
3279 (setq mail-archive-file-name (expand-file-name "~/outgoing")) 3338 (setq mail-archive-file-name (expand-file-name "~/outgoing"))
3280 3339
3281 The output file will be in Unix mail format, which can be read directly 3340 The output file will be in Unix mail format, which can be read directly
3282 by VM, but not always by Rmail. See question 141. 3341 by VM, but not always by Rmail. See question 141.
3342
3343 For Gnus, see the `Archived Messages node of the Gnus manual.
3283 3344
3284 If you use mh-e, add an "FCC:" or "BCC:" field to your components file. 3345 If you use mh-e, add an "FCC:" or "BCC:" field to your components file.
3285 3346
3286 It does not work to put "set record filename" in the .mailrc file. 3347 It does not work to put "set record filename" in the .mailrc file.
3287 3348
3379 3440
3380 http://bmrc.berkeley.edu/~trey/emacs/mime.html 3441 http://bmrc.berkeley.edu/~trey/emacs/mime.html
3381 3442
3382 Version 6.x of VM supports MIME. See question 104. 3443 Version 6.x of VM supports MIME. See question 104.
3383 3444
3445 MIME support has been added in the development version of Gnus which will
3446 be included with a future version of Emacs.
3447
3384 147: How do I make Emacs automatically start my mail/news reader? 3448 147: How do I make Emacs automatically start my mail/news reader?
3385 3449
3386 To start Emacs in Gnus: 3450 To start Emacs in Gnus:
3387 3451
3388 emacs -f gnus 3452 emacs -f gnus
3428 3492
3429 Underlining appears like this: 3493 Underlining appears like this:
3430 3494
3431 _^Hu_^Hn_^Hd_^He_^Hr_^Hl_^Hi_^Hn_^Hi_^Hn_^Hg 3495 _^Hu_^Hn_^Hd_^He_^Hr_^Hl_^Hi_^Hn_^Hi_^Hn_^Hg
3432 3496
3433 Per Abrahamsen <amanda@iesd.auc.dk> suggests using the following code, 3497 Use Gnus' "Overstrike" function from the Article -> Washing menu (or type
3434 which uses the underline face to turn such text into true underlining: 3498 "W o"). You can do this for all articles with:
3435 3499
3436 (defun gnus-article-prepare-overstrike () 3500 (add-hook 'gnus-article-prepare-hook 'gnus-article-treat-overstrike)
3437 ;; Prepare article for overstrike commands.
3438 (save-excursion
3439 (set-buffer gnus-article-buffer)
3440 (let ((buffer-read-only nil))
3441 (goto-char (point-min))
3442 (while (search-forward "\b" nil t)
3443 (let ((next (following-char))
3444 (previous (char-after (- (point) 2))))
3445 (cond ((eq next previous)
3446 (delete-region (- (point) 2) (point))
3447 (put-text-property (point) (1+ (point))
3448 'face 'bold))
3449 ((eq next ?_)
3450 (delete-region (1- (point)) (1+ (point)))
3451 (put-text-property (1- (point)) (point)
3452 'face 'underline))
3453 ((eq previous ?_)
3454 (delete-region (- (point) 2) (point))
3455 (put-text-property (point) (1+ (point))
3456 'face 'underline))))))))
3457
3458 (add-hook 'gnus-article-prepare-hook 'gnus-article-prepare-overstrike)
3459 3501
3460 If you prefer to do away with underlining altogether, you can 3502 If you prefer to do away with underlining altogether, you can
3461 destructively remove it with M-x ununderline-region; do this 3503 destructively remove it with M-x ununderline-region; do this
3462 automatically via 3504 automatically via
3463 3505
3464 (add-hook 'gnus-article-prepare-hook 3506 (add-hook 'gnus-article-prepare-hook
3465 '(lambda () (ununderline-region (point-min) (point-max)))) 3507 (lambda () (ununderline-region (point-min) (point-max))))
3508
3509 See the Gnus manual for more information about this and similar methods
3510 for treating article contents.
3466 3511
3467 151: How do I save all the items of a multi-part posting in Gnus? 3512 151: How do I save all the items of a multi-part posting in Gnus?
3468 3513
3469 Use gnus-uu. Type C-c C-v C-h in the Gnus summary buffer to see a list 3514 Use gnus-uu. Type C-c C-v C-h in the Gnus summary buffer to see a list
3470 of available commands. 3515 of available commands.
3535 on its own. The C News folks have sped up inews, too, so speed should 3580 on its own. The C News folks have sped up inews, too, so speed should
3536 look better to most folks as that update propagates around. 3581 look better to most folks as that update propagates around.
3537 3582
3538 158: Where can I find out more about Gnus? 3583 158: Where can I find out more about Gnus?
3539 3584
3540 Look for the Gnus FAQ, available at 3585 Visit http://www.gnus.org/, which has a pointer to the current Gnus FAQ and
3541 3586 more information. The relevant newsgroup is gnu.emacs.gnus.
3542 http://www.miranova.com/~steve/gnus-faq.html
3543 3587
3544 ------------------------------------------------------------ 3588 ------------------------------------------------------------
3589 Modified, with permission, for the Emacs 20.4 distribution by Dave Love.
3590
3545 Copyright 1994-1998 Reuven M. Lerner 3591 Copyright 1994-1998 Reuven M. Lerner
3546 Copyright 1992-1993 Steven Byrnes 3592 Copyright 1992-1993 Steven Byrnes
3547 Copyright 1990-1992 Joseph Brian Wells 3593 Copyright 1990-1992 Joseph Brian Wells
3548 3594
3549 This list of frequently asked questions about GNU Emacs with answers 3595 This list of frequently asked questions about GNU Emacs with answers