This commit is contained in:
gferg 2001-03-25 22:02:23 +00:00
parent f50eba91c5
commit 34f2dc452b
1 changed files with 35 additions and 42 deletions

View File

@ -3,11 +3,9 @@
<article>
<title>Emacs Beginner's HOWTO</title>
<author>
Jeremy D. Zawodny, <htmlurl url="mailto:jzawodn@wcnet.org" name="jzawodn@wcnet.org">
Jeremy D. Zawodny: <htmlurl url="mailto:Jeremy@Zawodny.com" name="Jeremy@Zawodny.com">
</author>
<date>
v1.7, 14 October 1999
</date>
<date>v1.12, 2001-25-03</date>
<abstract>
@ -27,7 +25,7 @@ version of this document is usually available from <htmlurl url =
<sect1>Copyright
<p>Copyright &copy; 1998 - 1999 Jeremy D. Zawodny. Permission to
<p>Copyright &copy; 1998 - 2001 Jeremy D. Zawodny. Permission to
distribute and modify this document is granted under the GNU General
Public License. An on-line copy is available at <htmlurl url =
"http://www.gnu.org/copyleft/gpl.html" name =
@ -415,7 +413,7 @@ Keystrokes Function Description
-------------------------------------------------------------------
C-x C-s save-buffer Save the current buffer to disk
C-x u undo Undo the last operation
C-c C-f find-file Open a file from disk
C-x C-f find-file Open a file from disk
C-s isearch-forward Search forward for a string
C-r isearch-backward Search backward for a string
replace-string Search & replace for a string
@ -526,8 +524,8 @@ form text like a README file. It understands how to identify words and
paragraphs and generally makes sure that it does what I expect when I
use the normal navigation keystrokes.
<p>When I'm writing text for human consumpiton, I typically want it
to look good. It should be properly word-wrapped to a reasonble value
<p>When I'm writing text for human consumption, I typically want it
to look good. It should be properly word-wrapped to a reasonable value
and so on. To enable word wrapping I just turn on the
<tt>auto-fill</tt> minor mode. This mode tries to do the Right Thing
when I'm typing along and hit the end of the line. The fact that it is
@ -582,7 +580,7 @@ automatically adding comments to your code, creating Makefiles,
updating Change Logs and so on.
<p>When you add all these modes together and consider the maturity and
stability of the Emacs code, it compares quite nicely to commerically
stability of the Emacs code, it compares quite nicely to commercially
marketed Integrated Development Environments (IDEs) for languages like
C++ and Java. And, of course, it's free.
@ -609,7 +607,7 @@ history and why there are two modes (the docs don't say), but it would
appear that <tt>perl-mode</tt> was the original mode for editing Perl
code in Emacs. It seems to have fewer features than
<tt>cperl-mode</tt> and is lacking the ability to recognize some of
Perl's fancier langugage constructs.
Perl's fancier language constructs.
<p>Personally, I use and recommend <tt>cperl-mode</tt> which seems to
be quite actively maintained and has just about every feature I could
@ -671,7 +669,7 @@ while. If you have <bf>GNU ispell</bf> installed, you can type <tt>M-x
ispell</tt> and spell-check the current buffer. If ispell finds words
that it doesn't know, it prompts you with a list of possible
replacements and lets you select one (or none) of them. It's
functionally equivelant to the spell-checkers in many popular non-free
functionally equivalent to the spell-checkers in many popular non-free
software packages.
</sect2>
@ -694,7 +692,7 @@ fashioned way.
<p>When you're writing documents in TeX, it's often helpful to get
Emacs to add some color and highlight the backslashes, braces and
other charcters. <tt>tex-mode</tt> takes care of that for you.
other characters. <tt>tex-mode</tt> takes care of that for you.
<p>Though I don't write much directly in TeX anymore, when I did this
mode proved to be quite helpful in making my TeX source a bit more
@ -814,7 +812,7 @@ find it documented in the Emacs documentation.
<p>Virtually all Emacs customization is done via Lisp code. You can
modify variables which influence the way Emacs operates or you can add
new functions to Emacs (or override existing functions--replacing them
with your own.
with your own).
<sect1>Temporary Customization
@ -822,7 +820,7 @@ with your own.
to do it in a way that is temporary. If you do something horribly
wrong, you can just <tt>C-x C-c</tt> to exit emacs and run it
again. Once you've figured out what changes you'd like to make
permenant, you can add them to your very own <tt>.emacs</tt> file so
permanent, you can add them to your very own <tt>.emacs</tt> file so
that they take effect every time you start Emacs. This is discussed in
the next section.
@ -838,7 +836,7 @@ of a variable in Emacs. The list code to do this looks like this:
<p>Where <tt>variable-name</tt> is the name of the variable and
<tt>new-value</tt> is the value you'd like to give the variable. (In
Lisp-speak, you're binding a variable to a value.) The <tt>setq</tt>
function in lisp is analagous to the assignment operators (ususally
function in lisp is analogous to the assignment operators (usually
<tt>=</tt>) in other programming languages.
<p><bf>NOTE:</bf> I'm glossing over many details here for the sake of
@ -855,8 +853,8 @@ feel free to look them up in an Emacs Lisp reference.
<p>The variable <tt>transient-mark-mode</tt> controls whether or not a
region becomes highlighted when I mark it. In many GUI applications,
if you click and drag the mouse to select a range of text it becomes
hilighted in reverse video or some other color. Emacs will do the same
thing it the <tt>transient-mark-mode</tt> varible is set (to a non-nil
hi-lighted in reverse video or some other color. Emacs will do the same
thing it the <tt>transient-mark-mode</tt> variable is set (to a non-nil
value).
<p>A <em>WHAT</em> value?
@ -888,11 +886,11 @@ set the value to something absurd, you could type:
(setq fill-column 20)
</verb>
<p>But that won't actaully do anything. You need to tell Emacs to
<p>But that won't actually do anything. You need to tell Emacs to
<bf>evaluate</bf> the expression you typed. To do so, put the point
(cursor) at the end of the expression end then type <tt>C-x C-e</tt>,
which calls the function <tt>eval-last-sexp</tt> in case you
care. When you do that, noice that <tt>20</tt> (or whatever value you
care. When you do that, notice that <tt>20</tt> (or whatever value you
used) is echoed back to you in the mini-buffer at the bottom of the
screen. That's just the return value from the expression you
evaluated.
@ -929,7 +927,7 @@ pair contains a regular expression and an Emacs mode name. If a file
you open matches the regular expression (in this case, the string
<tt>README</tt>) Emacs starts the mode you specified.
<p>The funny syntax above is because we're actaully adding another
<p>The funny syntax above is because we're actually adding another
pair to that mode list. You wouldn't want to just assign to
<tt>auto-mode-alist</tt> without making sure the values that it
already contains aren't lost.
@ -964,7 +962,7 @@ more software products don't let you do that.
<p>In case you haven't already guessed, every time you start Emacs, it
looks for a file named <tt>.emacs</tt> in your home directory. Your
<tt>.emacs</tt> file is where you should put any Lisp code that you
want run automatiaclly and that includes the sort of customization
want run automatically and that includes the sort of customization
we've been dealing with here.
<p>Another example from my <tt>.emacs</tt> file:
@ -993,8 +991,8 @@ file in order to make the mode or package work in a particular way.
<sect1>The Customize Package
<p>As Emacs has grown in popularity and continuted to evolved, someone
eventaully said ``there has to be a better way to let novice users
<p>As Emacs has grown in popularity and continued to evolved, someone
eventually said ``there has to be a better way to let novice users
customize their Emacs.'' And <tt>customize</tt> was born.
<p>Customize provides a more intuitive method of customizing parts of
@ -1018,7 +1016,7 @@ about it.</em>.
<p>Like any well behaved X application, Emacs respects your X
resources. That means you can control the initial colors, geometry,
and other X specfic things just as you could with an <tt>xterm</tt>,
and other X specific things just as you could with an <tt>xterm</tt>,
<tt>nxterm</tt>, or whatever.
<p>Here's the relevant bit of my <tt>~/.Xdefaults</tt> file:
@ -1108,9 +1106,9 @@ name="http://www.gnus.org/">.
</sect1>
<sect1>BBDB (A rollodex)
<sect1>BBDB (A rolodex)
<p>BBDB is an Insidious Big Brother Database, a rollodex-like program
<p>BBDB is an Insidious Big Brother Database, a rolodex-like program
for Emacs that works with most of the popular Emacs Mail packages (VM
and GNUS included).
@ -1159,11 +1157,6 @@ books also contain a chapter or two about Emacs (and <tt>vi</tt>).
<p>Publisher: O'Reilly &amp; Associates - <htmlurl
url="http://www.ora.com/" name="http://www.ora.com/">
<p>You can buy it at a discount from Amazon.com via their Associates
program: <htmlurl
url="http://www.amazon.com/exec/obidos/ASIN/1565921526/jeremydzawodny"
name="http://www.amazon.com/exec/obidos/ASIN/1565921526/">
<p><bf>Commentary:</bf> This is probably the best book to start
with. After you've read the HOWTO and looked through the FAQ this book
serves as a comprehensive and very approachable tutorial.
@ -1177,11 +1170,6 @@ serves as a comprehensive and very approachable tutorial.
<p>Publisher: O'Reilly &amp; Associates - <htmlurl
url="http://www.ora.com/" name="http://www.ora.com/">
<p>You can buy it at a discount from Amazon.com via their Associates
program: <htmlurl
url="http://www.amazon.com/exec/obidos/ASIN/1565922611/jeremydzawodny/"
name="http://www.amazon.com/exec/obidos/ASIN/1565922611/">
<p><bf>Commentary:</bf> After you've used Emacs for a while and have
decided that you'd like to try writing your own mode or maybe try out
some advanced customization, this is the book for you. While it
@ -1207,11 +1195,6 @@ environment.
the GNU FTP server: <htmlurl url="ftp://prep.ai.mit.edu/gnu/emacs/"
name="ftp://prep.ai.mit.edu/gnu/emacs/">.
<p>You can buy a nicely printed version from Amazon.com via their
Associates program: <htmlurl
url="http://www.amazon.com/exec/obidos/ASIN/1882114418/jeremydzawodny/"
name="http://www.amazon.com/exec/obidos/ASIN/1882114418/jeremydzawodny/">.
<p><bf>Commentary:</bf> This a good introductory manual for Emacs
Lisp--even if you're not a heavy-duty programmer.
@ -1271,12 +1254,18 @@ are:
<sect1>Mailing Lists
<p>There is a mailing list for GNU Emacs which is hosted by the Free
Software Foundation. See the web site <htmlurl
url="http://mail.gnu.org/mailman/listinfo/help-gnu-emacs"
name="http://mail.gnu.org/mailman/listinfo/help-gnu-emacs"> for more
information.
<p>The only mailing list devoted to Emacs that I know of right now is
the NT-Emacs list. It is a list for folks who are using the Micro$oft
Windows version of Emacs. See the NT-Emacs FAQ <htmlurl
url="http://www.cs.washington.edu/homes/voelker/ntemacs.html"
name="http://www.cs.washington.edu/homes/voelker/ntemacs.html"> for
more. information.
more information.
</sect1>
@ -1321,6 +1310,9 @@ document.
<itemize>
<item>Craig Lyons <htmlurl name = "Craig.Lyons@compaq.com"
url="mailto:Craig.Lyons@compaq.com">
<item>Robert Vollmert <htmlurl name = "rvollmer@gmx.net"
url="mailto:rvollmer@gmx.net" >
@ -1358,3 +1350,4 @@ url="mailto:smoke@casema.net">
</sect>
</article>