;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;;_* Commentary:
;;; ange-ftp.el --- transparent FTP support for GNU Emacs
-;;; Copyright (C) 1989,90,91,92,93,94,95 Free Software Foundation, Inc.
-;;;
+;; Copyright (C) 1989,90,91,92,93,94,95 Free Software Foundation, Inc.
+
;; Author: Andy Norman (ange@hplb.hpl.hp.com)
;; Keywords: comm
-;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; This program is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; A copy of the GNU General Public License can be obtained from this
-;;; program's author (send electronic mail to ange@hplb.hpl.hp.com) or from
-;;; the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA
-;;; 02139, USA.
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;;
-;;; This package attempts to make accessing files and directories using FTP
-;;; from within GNU Emacs as simple and transparent as possible. A subset of
-;;; the common file-handling routines are extended to interact with FTP.
-
-;;; Usage:
-;;;
-;;; Some of the common GNU Emacs file-handling operations have been made
-;;; FTP-smart. If one of these routines is given a filename that matches
-;;; '/user@host:name' then it will spawn an FTP process connecting to machine
-;;; 'host' as account 'user' and perform its operation on the file 'name'.
-;;;
-;;; For example: if find-file is given a filename of:
-;;;
-;;; /ange@anorman:/tmp/notes
-;;;
-;;; then ange-ftp spawns an FTP process, connect to the host 'anorman' as
-;;; user 'ange', get the file '/tmp/notes' and pop up a buffer containing the
-;;; contents of that file as if it were on the local filesystem. If ange-ftp
-;;; needs a password to connect then it reads one in the echo area.
-
-;;; Extended filename syntax:
-;;;
-;;; The default extended filename syntax is '/user@host:name', where the
-;;; 'user@' part may be omitted. This syntax can be customised to a certain
-;;; extent by changing ange-ftp-name-format. There are limitations.
-;;;
-;;; If the user part is omitted then ange-ftp generates a default user
-;;; instead whose value depends on the variable ange-ftp-default-user.
-
-;;; Passwords:
-;;;
-;;; A password is required for each host/user pair. Ange-ftp reads passwords
-;;; as needed. You can also specify a password with ange-ftp-set-passwd, or
-;;; in a *valid* ~/.netrc file.
-
-;;; Passwords for user "anonymous":
-;;;
-;;; Passwords for the user "anonymous" (or "ftp") are handled
-;;; specially. The variable `ange-ftp-generate-anonymous-password'
-;;; controls what happens: if the value of this variable is a string,
-;;; then this is used as the password; if non-nil (the default), then
-;;; the value of `user-mail-address' is used; if nil then the user
-;;; is prompted for a password as normal.
-
-;;; "Dumb" UNIX hosts:
-;;;
-;;; The FTP servers on some UNIX machines have problems if the 'ls' command is
-;;; used.
-;;;
-;;; The routine ange-ftp-add-dumb-unix-host can be called to tell ange-ftp to
-;;; limit itself to the DIR command and not 'ls' for a given UNIX host. Note
-;;; that this change will take effect for the current GNU Emacs session only.
-;;; See below for a discussion of non-UNIX hosts. If a large number of
-;;; machines with similar hostnames have this problem then it is easier to set
-;;; the value of ange-ftp-dumb-unix-host-regexp in your .emacs file. ange-ftp
-;;; is unable to automatically recognize dumb unix hosts.
-
-;;; File name completion:
-;;;
-;;; Full file-name completion is supported on UNIX, VMS, CMS, and MTS hosts.
-;;; To do filename completion, ange-ftp needs a listing from the remote host.
-;;; Therefore, for very slow connections, it might not save any time.
-
-;;; FTP processes:
-;;;
-;;; When ange-ftp starts up an FTP process, it leaves it running for speed
-;;; purposes. Some FTP servers will close the connection after a period of
-;;; time, but ange-ftp should be able to quietly reconnect the next time that
-;;; the process is needed.
-;;;
-;;; Killing the "*ftp user@host*" buffer also kills the ftp process.
-;;; This should not cause ange-ftp any grief.
-
-;;; Binary file transfers:
-;;;
-;;; By default ange-ftp transfers files in ASCII mode. If a file being
-;;; transferred matches the value of ange-ftp-binary-file-name-regexp then
-;;; binary mode is used for that transfer.
-
-;;; Account passwords:
-;;;
-;;; Some FTP servers require an additional password which is sent by the
-;;; ACCOUNT command. ange-ftp partially supports this by allowing the user to
-;;; specify an account password by either calling ange-ftp-set-account, or by
-;;; specifying an account token in the .netrc file. If the account password
-;;; is set by either of these methods then ange-ftp will issue an ACCOUNT
-;;; command upon starting the FTP process.
-
-;;; Preloading:
-;;;
-;;; ange-ftp can be preloaded, but must be put in the site-init.el file and
-;;; not the site-load.el file in order for the documentation strings for the
-;;; functions being overloaded to be available.
-
-;;; Status reports:
-;;;
-;;; Most ange-ftp commands that talk to the FTP process output a status
-;;; message on what they are doing. In addition, ange-ftp can take advantage
-;;; of the FTP client's HASH command to display the status of transferring
-;;; files and listing directories. See the documentation for the variables
-;;; ange-ftp-{ascii,binary}-hash-mark-size, ange-ftp-send-hash and
-;;; ange-ftp-process-verbose for more details.
-
-;;; Gateways:
-;;;
-;;; Sometimes it is necessary for the FTP process to be run on a different
-;;; machine than the machine running GNU Emacs. This can happen when the
-;;; local machine has restrictions on what hosts it can access.
-;;;
-;;; ange-ftp has support for running the ftp process on a different (gateway)
-;;; machine. The way it works is as follows:
-;;;
-;;; 1) Set the variable 'ange-ftp-gateway-host' to the name of a machine
-;;; that doesn't have the access restrictions.
-;;;
-;;; 2) Set the variable 'ange-ftp-local-host-regexp' to a regular expression
-;;; that matches hosts that can be contacted from running a local ftp
-;;; process, but fails to match hosts that can't be accessed locally. For
-;;; example:
-;;;
-;;; "\\.hp\\.com$\\|^[^.]*$"
-;;;
-;;; will match all hosts that are in the .hp.com domain, or don't have an
-;;; explicit domain in their name, but will fail to match hosts with
-;;; explicit domains or that are specified by their ip address.
-;;;
-;;; 3) Using NFS and symlinks, make sure that there is a shared directory with
-;;; the *same* name between the local machine and the gateway machine.
-;;; This directory is necessary for temporary files created by ange-ftp.
-;;;
-;;; 4) Set the variable 'ange-ftp-gateway-tmp-name-template' to the name of
-;;; this directory plus an identifying filename prefix. For example:
-;;;
-;;; "/nfs/hplose/ange/ange-ftp"
-;;;
-;;; where /nfs/hplose/ange is a directory that is shared between the
-;;; gateway machine and the local machine.
-;;;
-;;; The simplest way of getting a ftp process running on the gateway machine
-;;; is if you can spawn a remote shell using either 'rsh' or 'remsh'. If you
-;;; can't do this for some reason such as security then points 7 onwards will
-;;; discuss an alternative approach.
-;;;
-;;; 5) Set the variable ange-ftp-gateway-program to the name of the remote
-;;; shell process such as 'remsh' or 'rsh' if the default isn't correct.
-;;;
-;;; 6) Set the variable ange-ftp-gateway-program-interactive to nil if it
-;;; isn't already. This tells ange-ftp that you are using a remote shell
-;;; rather than logging in using telnet or rlogin.
-;;;
-;;; That should be all you need to allow ange-ftp to spawn a ftp process on
-;;; the gateway machine. If you have to use telnet or rlogin to get to the
-;;; gateway machine then follow the instructions below.
-;;;
-;;; 7) Set the variable ange-ftp-gateway-program to the name of the program
-;;; that lets you log onto the gateway machine. This may be something like
-;;; telnet or rlogin.
-;;;
-;;; 8) Set the variable ange-ftp-gateway-prompt-pattern to a regular
-;;; expression that matches the prompt you get when you login to the
-;;; gateway machine. Be very specific here; this regexp must not match
-;;; *anything* in your login banner except this prompt.
-;;; shell-prompt-pattern is far too general as it appears to match some
-;;; login banners from Sun machines. For example:
-;;;
-;;; "^$*$ *"
-;;;
-;;; 9) Set the variable ange-ftp-gateway-program-interactive to 't' to let
-;;; ange-ftp know that it has to "hand-hold" the login to the gateway
-;;; machine.
-;;;
-;;; 10) Set the variable ange-ftp-gateway-setup-term-command to a UNIX command
-;;; that will put the pty connected to the gateway machine into a
-;;; no-echoing mode, and will strip off carriage-returns from output from
-;;; the gateway machine. For example:
-;;;
-;;; "stty -onlcr -echo"
-;;;
-;;; will work on HP-UX machines, whereas:
-;;;
-;;; "stty -echo nl"
-;;;
-;;; appears to work for some Sun machines.
-;;;
-;;; That's all there is to it.
-
-;;; Smart gateways:
-;;;
-;;; If you have a "smart" ftp program that allows you to issue commands like
-;;; "USER foo@bar" which do nice proxy things, then look at the variables
-;;; ange-ftp-smart-gateway and ange-ftp-smart-gateway-port.
-;;;
-;;; Otherwise, if there is an alternate ftp program that implements proxy in
-;;; a transparent way (i.e. w/o specifying the proxy host), that will
-;;; connect you directly to the desired destination host:
-;;; Set ange-ftp-gateway-ftp-program-name to that program's name.
-;;; Set ange-ftp-local-host-regexp to a value as stated earlier on.
-;;; Leave ange-ftp-gateway-host set to nil.
-;;; Set ange-ftp-smart-gateway to t.
-
-;;; Tips for using ange-ftp:
-;;;
-;;; 1. For dired to work on a host which marks symlinks with a trailing @ in
-;;; an ls -alF listing, you need to (setq dired-ls-F-marks-symlinks t).
-;;; Most UNIX systems do not do this, but ULTRIX does. If you think that
-;;; there is a chance you might connect to an ULTRIX machine (such as
-;;; prep.ai.mit.edu), then set this variable accordingly. This will have
-;;; the side effect that dired will have problems with symlinks whose names
-;;; end in an @. If you get yourself into this situation then editing
-;;; dired's ls-switches to remove "F", will temporarily fix things.
-;;;
-;;; 2. If you know that you are connecting to a certain non-UNIX machine
-;;; frequently, and ange-ftp seems to be unable to guess its host-type,
-;;; then setting the appropriate host-type regexp
-;;; (ange-ftp-vms-host-regexp, ange-ftp-mts-host-regexp, or
-;;; ange-ftp-cms-host-regexp) accordingly should help. Also, please report
-;;; ange-ftp's inability to recognize the host-type as a bug.
-;;;
-;;; 3. For slow connections, you might get "listing unreadable" error
-;;; messages, or get an empty buffer for a file that you know has something
-;;; in it. The solution is to increase the value of ange-ftp-retry-time.
-;;; Its default value is 5 which is plenty for reasonable connections.
-;;; However, for some transatlantic connections I set this to 20.
-;;;
-;;; 4. Beware of compressing files on non-UNIX hosts. Ange-ftp will do it by
-;;; copying the file to the local machine, compressing it there, and then
-;;; sending it back. Binary file transfers between machines of different
-;;; architectures can be a risky business. Test things out first on some
-;;; test files. See "Bugs" below. Also, note that ange-ftp copies files by
-;;; moving them through the local machine. Again, be careful when doing
-;;; this with binary files on non-Unix machines.
-;;;
-;;; 5. Beware that dired over ftp will use your setting of dired-no-confirm
-;;; (list of dired commands for which confirmation is not asked). You
-;;; might want to reconsider your setting of this variable, because you
-;;; might want confirmation for more commands on remote direds than on
-;;; local direds. For example, I strongly recommend that you not include
-;;; compress and uncompress in this list. If there is enough demand it
-;;; might be a good idea to have an alist ange-ftp-dired-no-confirm of
-;;; pairs ( TYPE . LIST ), where TYPE is an operating system type and LIST
-;;; is a list of commands for which confirmation would be suppressed. Then
-;;; remote dired listings would take their (buffer-local) value of
-;;; dired-no-confirm from this alist. Who votes for this?
-
-;;; ---------------------------------------------------------------------
-;;; Non-UNIX support:
-;;; ---------------------------------------------------------------------
-
-;;; VMS support:
-;;;
-;;; Ange-ftp has full support for VMS hosts. It
-;;; should be able to automatically recognize any VMS machine. However, if it
-;;; fails to do this, you can use the command ange-ftp-add-vms-host. As well,
-;;; you can set the variable ange-ftp-vms-host-regexp in your .emacs file. We
-;;; would be grateful if you would report any failures to automatically
-;;; recognize a VMS host as a bug.
-;;;
-;;; Filename Syntax:
-;;;
-;;; For ease of *implementation*, the user enters the VMS filename syntax in a
-;;; UNIX-y way. For example:
-;;; PUB$:[ANONYMOUS.SDSCPUB.NEXT]README.TXT;1
-;;; would be entered as:
-;;; /PUB$$:/ANONYMOUS/SDSCPUB/NEXT/README.TXT;1
-;;; i.e. to log in as anonymous on ymir.claremont.edu and grab the file:
-;;; [.CSV.POLICY]RULES.MEM
-;;; you would type:
-;;; C-x C-f /anonymous@ymir.claremont.edu:CSV/POLICY/RULES.MEM
-;;;
-;;; A legal VMS filename is of the form: FILE.TYPE;##
-;;; where FILE can be up to 39 characters
-;;; TYPE can be up to 39 characters
-;;; ## is a version number (an integer between 1 and 32,767)
-;;; Valid characters in FILE and TYPE are A-Z 0-9 _ - $
-;;; $ cannot begin a filename, and - cannot be used as the first or last
-;;; character.
-;;;
-;;; Tips:
-;;; 1. Although VMS is not case sensitive, EMACS running under UNIX is.
-;;; Therefore, to access a VMS file, you must enter the filename with upper
-;;; case letters.
-;;; 2. To access the latest version of file under VMS, you use the filename
-;;; without the ";" and version number. You should always edit the latest
-;;; version of a file. If you want to edit an earlier version, copy it to a
-;;; new file first. This has nothing to do with ange-ftp, but is simply
-;;; good VMS operating practice. Therefore, to edit FILE.TXT;3 (say 3 is
-;;; latest version), do C-x C-f /ymir.claremont.edu:FILE.TXT. If you
-;;; inadvertently do C-x C-f /ymir.claremont.edu:FILE.TXT;3, you will find
-;;; that VMS will not allow you to save the file because it will refuse to
-;;; overwrite FILE.TXT;3, but instead will want to create FILE.TXT;4, and
-;;; attach the buffer to this file. To get out of this situation, M-x
-;;; write-file /ymir.claremont.edu:FILE.TXT will attach the buffer to
-;;; latest version of the file. For this reason, in dired "f"
-;;; (dired-find-file), always loads the file sans version, whereas "v",
-;;; (dired-view-file), always loads the explicit version number. The
-;;; reasoning being that it reasonable to view old versions of a file, but
-;;; not to edit them.
-;;; 3. EMACS has a feature in which it does environment variable substitution
-;;; in filenames. Therefore, to enter a $ in a filename, you must quote it
-;;; by typing $$.
-
-;;; MTS support:
-;;;
-;;; Ange-ftp has full support for hosts running
-;;; the Michigan terminal system. It should be able to automatically
-;;; recognize any MTS machine. However, if it fails to do this, you can use
-;;; the command ange-ftp-add-mts-host. As well, you can set the variable
-;;; ange-ftp-mts-host-regexp in your .emacs file. We would be grateful if you
-;;; would report any failures to automatically recognize a MTS host as a bug.
-;;;
-;;; Filename syntax:
-;;;
-;;; MTS filenames are entered in a UNIX-y way. For example, if your account
-;;; was YYYY, the file FILE in the account XXXX: on mtsg.ubc.ca would be
-;;; entered as
-;;; /YYYY@mtsg.ubc.ca:/XXXX:/FILE
-;;; In other words, MTS accounts are treated as UNIX directories. Of course,
-;;; to access a file in another account, you must have access permission for
-;;; it. If FILE were in your own account, then you could enter it in a
-;;; relative name fashion as
-;;; /YYYY@mtsg.ubc.ca:FILE
-;;; MTS filenames can be up to 12 characters. Like UNIX, the structure of the
-;;; filename does not contain a TYPE (i.e. it can have as many "."'s as you
-;;; like.) MTS filenames are always in upper case, and hence be sure to enter
-;;; them as such! MTS is not case sensitive, but an EMACS running under UNIX
-;;; is.
-
-;;; CMS support:
-;;;
-;;; Ange-ftp has full support for hosts running
-;;; CMS. It should be able to automatically recognize any CMS machine.
-;;; However, if it fails to do this, you can use the command
-;;; ange-ftp-add-cms-host. As well, you can set the variable
-;;; ange-ftp-cms-host-regexp in your .emacs file. We would be grateful if you
-;;; would report any failures to automatically recognize a CMS host as a bug.
-;;;
-;;; Filename syntax:
-;;;
-;;; CMS filenames are entered in a UNIX-y way. In otherwords, minidisks are
-;;; treated as UNIX directories. For example to access the file READ.ME in
-;;; minidisk *.311 on cuvmb.cc.columbia.edu, you would enter
-;;; /anonymous@cuvmb.cc.columbia.edu:/*.311/READ.ME
-;;; If *.301 is the default minidisk for this account, you could access
-;;; FOO.BAR on this minidisk as
-;;; /anonymous@cuvmb.cc.columbia.edu:FOO.BAR
-;;; CMS filenames are of the form FILE.TYPE, where both FILE and TYPE can be
-;;; up to 8 characters. Again, beware that CMS filenames are always upper
-;;; case, and hence must be entered as such.
-;;;
-;;; Tips:
-;;; 1. CMS machines, with the exception of anonymous accounts, nearly always
-;;; need an account password. To have ange-ftp send an account password,
-;;; you can either include it in your .netrc file, or use
-;;; ange-ftp-set-account.
-;;; 2. Ange-ftp cannot send "write passwords" for a minidisk. Hopefully, we
-;;; can fix this.
-;;;
-;;; ------------------------------------------------------------------
-;;; Bugs:
-;;; ------------------------------------------------------------------
-;;;
-;;; 1. Umask problems:
-;;; Be warned that files created by using ange-ftp will take account of the
-;;; umask of the ftp daemon process rather than the umask of the creating
-;;; user. This is particularly important when logging in as the root user.
-;;; The way that I tighten up the ftp daemon's umask under HP-UX is to make
-;;; sure that the umask is changed to 027 before I spawn /etc/inetd. I
-;;; suspect that there is something similar on other systems.
-;;;
-;;; 2. Some combinations of FTP clients and servers break and get out of sync
-;;; when asked to list a non-existent directory. Some of the ai.mit.edu
-;;; machines cause this problem for some FTP clients. Using
-;;; ange-ftp-kill-ftp-process can restart the ftp process, which
-;;; should get things back in sync.
-;;;
-;;; 3. Ange-ftp does not check to make sure that when creating a new file,
-;;; you provide a valid filename for the remote operating system.
-;;; If you do not, then the remote FTP server will most likely
-;;; translate your filename in some way. This may cause ange-ftp to
-;;; get confused about what exactly is the name of the file. The
-;;; most common causes of this are using lower case filenames on systems
-;;; which support only upper case, and using filenames which are too
-;;; long.
-;;;
-;;; 4. Null (blank) passwords confuse both ange-ftp and some FTP daemons.
-;;;
-;;; 5. Ange-ftp likes to use pty's to talk to its FTP processes. If GNU Emacs
-;;; for some reason creates a FTP process that only talks via pipes then
-;;; ange-ftp won't be getting the information it requires at the time that
-;;; it wants it since pipes flush at different times to pty's. One
-;;; disgusting way around this problem is to talk to the FTP process via
-;;; rlogin which does the 'right' things with pty's.
-;;;
-;;; 6. For CMS support, we send too many cd's. Since cd's are cheap, I haven't
-;;; worried about this too much. Eventually, we should have some caching
-;;; of the current minidisk.
-;;;
-;;; 7. Some CMS machines do not assign a default minidisk when you ftp them as
-;;; anonymous. It is then necessary to guess a valid minidisk name, and cd
-;;; to it. This is (understandably) beyond ange-ftp.
-;;;
-;;; 8. Remote to remote copying of files on non-Unix machines can be risky.
-;;; Depending on the variable ange-ftp-binary-file-name-regexp, ange-ftp
-;;; will use binary mode for the copy. Between systems of different
-;;; architecture, this still may not be enough to guarantee the integrity
-;;; of binary files. Binary file transfers from VMS machines are
-;;; particularly problematical. Should ange-ftp-binary-file-name-regexp be
-;;; an alist of OS type, regexp pairs?
-;;;
-;;; 9. The code to do compression of files over ftp is not as careful as it
-;;; should be. It deletes the old remote version of the file, before
-;;; actually checking if the local to remote transfer of the compressed
-;;; file succeeds. Of course to delete the original version of the file
-;;; after transferring the compressed version back is also dangerous,
-;;; because some OS's have severe restrictions on the length of filenames,
-;;; and when the compressed version is copied back the "-Z" or ".Z" may be
-;;; truncated. Then, ange-ftp would delete the only remaining version of
-;;; the file. Maybe ange-ftp should make backups when it compresses files
-;;; (of course, the backup "~" could also be truncated off, sigh...).
-;;; Suggestions?
-;;;
-
-;;; 10. If a dir listing is attempted for an empty directory on (at least
-;;; some) VMS hosts, an ftp error is given. This is really an ftp bug, and
-;;; I don't know how to get ange-ftp work to around it.
-;;;
-;;; 11. Bombs on filenames that start with a space. Deals well with filenames
-;;; containing spaces, but beware that the remote ftpd may not like them
-;;; much.
-;;;
-;;; 12. The dired support for non-Unix-like systems does not currently work.
-;;; It needs to be reimplemented by modifying the parse-...-listing
-;;; functions to convert the directory listing to ls -l format.
-;;;
-;;; 13. The famous @ bug. As mentioned above in TIPS, ULTRIX marks symlinks
-;;; with a trailing @ in a ls -alF listing. In order to account for this
-;;; ange-ftp looks to chop trailing @'s off of symlink names when it is
-;;; parsing a listing with the F switch. This will cause ange-ftp to
-;;; incorrectly get the name of a symlink on a non-ULTRIX host if its name
-;;; ends in an @. ange-ftp will correct itself if you take F out of the
-;;; dired ls switches (C-u s will allow you to edit the switches). The
-;;; dired buffer will be automatically reverted, which will allow ange-ftp
-;;; to fix its files hashtable. A cookie to anyone who can think of a
-;;; fast, sure-fire way to recognize ULTRIX over ftp.
-
-;;; If you find any bugs or problems with this package, PLEASE either e-mail
-;;; the above author, or send a message to the ange-ftp-lovers mailing list
-;;; below. Ideas and constructive comments are especially welcome.
-
-;;; ange-ftp-lovers:
-;;;
-;;; ange-ftp has its own mailing list modestly called ange-ftp-lovers. All
-;;; users of ange-ftp are welcome to subscribe (see below) and to discuss
-;;; aspects of ange-ftp. New versions of ange-ftp are posted periodically to
-;;; the mailing list.
-;;;
-;;; To [un]subscribe to ange-ftp-lovers, or to report mailer problems with the
-;;; list, please mail one of the following addresses:
-;;;
-;;; ange-ftp-lovers-request@anorman.hpl.hp.com
-;;; or
-;;; ange-ftp-lovers-request%anorman.hpl.hp.com@hplb.hpl.hp.com
-;;;
-;;; Please don't forget the -request part.
-;;;
-;;; For mail to be posted directly to ange-ftp-lovers, send to one of the
-;;; following addresses:
-;;;
-;;; ange-ftp-lovers@anorman.hpl.hp.com
-;;; or
-;;; ange-ftp-lovers%anorman.hpl.hp.com@hplb.hpl.hp.com
-;;;
-;;; Alternatively, there is a mailing list that only gets announcements of new
-;;; ange-ftp releases. This is called ange-ftp-lovers-announce, and can be
-;;; subscribed to by e-mailing to the -request address as above. Please make
-;;; it clear in the request which mailing list you wish to join.
-
-;;; The latest version of ange-ftp can usually be obtained via anonymous ftp
-;;; from:
-;;; alpha.gnu.ai.mit.edu:ange-ftp/ange-ftp.tar.Z
-;;; or:
-;;; ugle.unit.no:/pub/gnu/emacs-lisp/ange-ftp.tar.Z
-;;; or:
-;;; archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/ange-ftp.tar.Z
-
-;;; The archives for ange-ftp-lovers can be found via anonymous ftp under:
-;;;
-;;; ftp.reed.edu:pub/mailing-lists/ange-ftp/
+
+;; This package attempts to make accessing files and directories using FTP
+;; from within GNU Emacs as simple and transparent as possible. A subset of
+;; the common file-handling routines are extended to interact with FTP.
+
+;; Usage:
+;;
+;; Some of the common GNU Emacs file-handling operations have been made
+;; FTP-smart. If one of these routines is given a filename that matches
+;; '/user@host:name' then it will spawn an FTP process connecting to machine
+;; 'host' as account 'user' and perform its operation on the file 'name'.
+;;
+;; For example: if find-file is given a filename of:
+;;
+;; /ange@anorman:/tmp/notes
+;;
+;; then ange-ftp spawns an FTP process, connect to the host 'anorman' as
+;; user 'ange', get the file '/tmp/notes' and pop up a buffer containing the
+;; contents of that file as if it were on the local filesystem. If ange-ftp
+;; needs a password to connect then it reads one in the echo area.
+
+;; Extended filename syntax:
+;;
+;; The default extended filename syntax is '/user@host:name', where the
+;; 'user@' part may be omitted. This syntax can be customised to a certain
+;; extent by changing ange-ftp-name-format. There are limitations.
+;;
+;; If the user part is omitted then ange-ftp generates a default user
+;; instead whose value depends on the variable ange-ftp-default-user.
+
+;; Passwords:
+;;
+;; A password is required for each host/user pair. Ange-ftp reads passwords
+;; as needed. You can also specify a password with ange-ftp-set-passwd, or
+;; in a *valid* ~/.netrc file.
+
+;; Passwords for user "anonymous":
+;;
+;; Passwords for the user "anonymous" (or "ftp") are handled
+;; specially. The variable `ange-ftp-generate-anonymous-password'
+;; controls what happens: if the value of this variable is a string,
+;; then this is used as the password; if non-nil (the default), then
+;; the value of `user-mail-address' is used; if nil then the user
+;; is prompted for a password as normal.
+
+;; "Dumb" UNIX hosts:
+;;
+;; The FTP servers on some UNIX machines have problems if the 'ls' command is
+;; used.
+;;
+;; The routine ange-ftp-add-dumb-unix-host can be called to tell ange-ftp to
+;; limit itself to the DIR command and not 'ls' for a given UNIX host. Note
+;; that this change will take effect for the current GNU Emacs session only.
+;; See below for a discussion of non-UNIX hosts. If a large number of
+;; machines with similar hostnames have this problem then it is easier to set
+;; the value of ange-ftp-dumb-unix-host-regexp in your .emacs file. ange-ftp
+;; is unable to automatically recognize dumb unix hosts.
+
+;; File name completion:
+;;
+;; Full file-name completion is supported on UNIX, VMS, CMS, and MTS hosts.
+;; To do filename completion, ange-ftp needs a listing from the remote host.
+;; Therefore, for very slow connections, it might not save any time.
+
+;; FTP processes:
+;;
+;; When ange-ftp starts up an FTP process, it leaves it running for speed
+;; purposes. Some FTP servers will close the connection after a period of
+;; time, but ange-ftp should be able to quietly reconnect the next time that
+;; the process is needed.
+;;
+;; Killing the "*ftp user@host*" buffer also kills the ftp process.
+;; This should not cause ange-ftp any grief.
+
+;; Binary file transfers:
+;;
+;; By default ange-ftp transfers files in ASCII mode. If a file being
+;; transferred matches the value of ange-ftp-binary-file-name-regexp then
+;; binary mode is used for that transfer.
+
+;; Account passwords:
+;;
+;; Some FTP servers require an additional password which is sent by the
+;; ACCOUNT command. ange-ftp partially supports this by allowing the user to
+;; specify an account password by either calling ange-ftp-set-account, or by
+;; specifying an account token in the .netrc file. If the account password
+;; is set by either of these methods then ange-ftp will issue an ACCOUNT
+;; command upon starting the FTP process.
+
+;; Preloading:
+;;
+;; ange-ftp can be preloaded, but must be put in the site-init.el file and
+;; not the site-load.el file in order for the documentation strings for the
+;; functions being overloaded to be available.
+
+;; Status reports:
+;;
+;; Most ange-ftp commands that talk to the FTP process output a status
+;; message on what they are doing. In addition, ange-ftp can take advantage
+;; of the FTP client's HASH command to display the status of transferring
+;; files and listing directories. See the documentation for the variables
+;; ange-ftp-{ascii,binary}-hash-mark-size, ange-ftp-send-hash and
+;; ange-ftp-process-verbose for more details.
+
+;; Gateways:
+;;
+;; Sometimes it is necessary for the FTP process to be run on a different
+;; machine than the machine running GNU Emacs. This can happen when the
+;; local machine has restrictions on what hosts it can access.
+;;
+;; ange-ftp has support for running the ftp process on a different (gateway)
+;; machine. The way it works is as follows:
+;;
+;; 1) Set the variable 'ange-ftp-gateway-host' to the name of a machine
+;; that doesn't have the access restrictions.
+;;
+;; 2) Set the variable 'ange-ftp-local-host-regexp' to a regular expression
+;; that matches hosts that can be contacted from running a local ftp
+;; process, but fails to match hosts that can't be accessed locally. For
+;; example:
+;;
+;; "\\.hp\\.com$\\|^[^.]*$"
+;;
+;; will match all hosts that are in the .hp.com domain, or don't have an
+;; explicit domain in their name, but will fail to match hosts with
+;; explicit domains or that are specified by their ip address.
+;;
+;; 3) Using NFS and symlinks, make sure that there is a shared directory with
+;; the *same* name between the local machine and the gateway machine.
+;; This directory is necessary for temporary files created by ange-ftp.
+;;
+;; 4) Set the variable 'ange-ftp-gateway-tmp-name-template' to the name of
+;; this directory plus an identifying filename prefix. For example:
+;;
+;; "/nfs/hplose/ange/ange-ftp"
+;;
+;; where /nfs/hplose/ange is a directory that is shared between the
+;; gateway machine and the local machine.
+;;
+;; The simplest way of getting a ftp process running on the gateway machine
+;; is if you can spawn a remote shell using either 'rsh' or 'remsh'. If you
+;; can't do this for some reason such as security then points 7 onwards will
+;; discuss an alternative approach.
+;;
+;; 5) Set the variable ange-ftp-gateway-program to the name of the remote
+;; shell process such as 'remsh' or 'rsh' if the default isn't correct.
+;;
+;; 6) Set the variable ange-ftp-gateway-program-interactive to nil if it
+;; isn't already. This tells ange-ftp that you are using a remote shell
+;; rather than logging in using telnet or rlogin.
+;;
+;; That should be all you need to allow ange-ftp to spawn a ftp process on
+;; the gateway machine. If you have to use telnet or rlogin to get to the
+;; gateway machine then follow the instructions below.
+;;
+;; 7) Set the variable ange-ftp-gateway-program to the name of the program
+;; that lets you log onto the gateway machine. This may be something like
+;; telnet or rlogin.
+;;
+;; 8) Set the variable ange-ftp-gateway-prompt-pattern to a regular
+;; expression that matches the prompt you get when you login to the
+;; gateway machine. Be very specific here; this regexp must not match
+;; *anything* in your login banner except this prompt.
+;; shell-prompt-pattern is far too general as it appears to match some
+;; login banners from Sun machines. For example:
+;;
+;; "^$*$ *"
+;;
+;; 9) Set the variable ange-ftp-gateway-program-interactive to 't' to let
+;; ange-ftp know that it has to "hand-hold" the login to the gateway
+;; machine.
+;;
+;; 10) Set the variable ange-ftp-gateway-setup-term-command to a UNIX command
+;; that will put the pty connected to the gateway machine into a
+;; no-echoing mode, and will strip off carriage-returns from output from
+;; the gateway machine. For example:
+;;
+;; "stty -onlcr -echo"
+;;
+;; will work on HP-UX machines, whereas:
+;;
+;; "stty -echo nl"
+;;
+;; appears to work for some Sun machines.
+;;
+;; That's all there is to it.
+
+;; Smart gateways:
+;;
+;; If you have a "smart" ftp program that allows you to issue commands like
+;; "USER foo@bar" which do nice proxy things, then look at the variables
+;; ange-ftp-smart-gateway and ange-ftp-smart-gateway-port.
+;;
+;; Otherwise, if there is an alternate ftp program that implements proxy in
+;; a transparent way (i.e. w/o specifying the proxy host), that will
+;; connect you directly to the desired destination host:
+;; Set ange-ftp-gateway-ftp-program-name to that program's name.
+;; Set ange-ftp-local-host-regexp to a value as stated earlier on.
+;; Leave ange-ftp-gateway-host set to nil.
+;; Set ange-ftp-smart-gateway to t.
+
+;; Tips for using ange-ftp:
+;;
+;; 1. For dired to work on a host which marks symlinks with a trailing @ in
+;; an ls -alF listing, you need to (setq dired-ls-F-marks-symlinks t).
+;; Most UNIX systems do not do this, but ULTRIX does. If you think that
+;; there is a chance you might connect to an ULTRIX machine (such as
+;; prep.ai.mit.edu), then set this variable accordingly. This will have
+;; the side effect that dired will have problems with symlinks whose names
+;; end in an @. If you get yourself into this situation then editing
+;; dired's ls-switches to remove "F", will temporarily fix things.
+;;
+;; 2. If you know that you are connecting to a certain non-UNIX machine
+;; frequently, and ange-ftp seems to be unable to guess its host-type,
+;; then setting the appropriate host-type regexp
+;; (ange-ftp-vms-host-regexp, ange-ftp-mts-host-regexp, or
+;; ange-ftp-cms-host-regexp) accordingly should help. Also, please report
+;; ange-ftp's inability to recognize the host-type as a bug.
+;;
+;; 3. For slow connections, you might get "listing unreadable" error
+;; messages, or get an empty buffer for a file that you know has something
+;; in it. The solution is to increase the value of ange-ftp-retry-time.
+;; Its default value is 5 which is plenty for reasonable connections.
+;; However, for some transatlantic connections I set this to 20.
+;;
+;; 4. Beware of compressing files on non-UNIX hosts. Ange-ftp will do it by
+;; copying the file to the local machine, compressing it there, and then
+;; sending it back. Binary file transfers between machines of different
+;; architectures can be a risky business. Test things out first on some
+;; test files. See "Bugs" below. Also, note that ange-ftp copies files by
+;; moving them through the local machine. Again, be careful when doing
+;; this with binary files on non-Unix machines.
+;;
+;; 5. Beware that dired over ftp will use your setting of dired-no-confirm
+;; (list of dired commands for which confirmation is not asked). You
+;; might want to reconsider your setting of this variable, because you
+;; might want confirmation for more commands on remote direds than on
+;; local direds. For example, I strongly recommend that you not include
+;; compress and uncompress in this list. If there is enough demand it
+;; might be a good idea to have an alist ange-ftp-dired-no-confirm of
+;; pairs ( TYPE . LIST ), where TYPE is an operating system type and LIST
+;; is a list of commands for which confirmation would be suppressed. Then
+;; remote dired listings would take their (buffer-local) value of
+;; dired-no-confirm from this alist. Who votes for this?
+
+;; ---------------------------------------------------------------------
+;; Non-UNIX support:
+;; ---------------------------------------------------------------------
+
+;; VMS support:
+;;
+;; Ange-ftp has full support for VMS hosts. It
+;; should be able to automatically recognize any VMS machine. However, if it
+;; fails to do this, you can use the command ange-ftp-add-vms-host. As well,
+;; you can set the variable ange-ftp-vms-host-regexp in your .emacs file. We
+;; would be grateful if you would report any failures to automatically
+;; recognize a VMS host as a bug.
+;;
+;; Filename Syntax:
+;;
+;; For ease of *implementation*, the user enters the VMS filename syntax in a
+;; UNIX-y way. For example:
+;; PUB$:[ANONYMOUS.SDSCPUB.NEXT]README.TXT;1
+;; would be entered as:
+;; /PUB$$:/ANONYMOUS/SDSCPUB/NEXT/README.TXT;1
+;; i.e. to log in as anonymous on ymir.claremont.edu and grab the file:
+;; [.CSV.POLICY]RULES.MEM
+;; you would type:
+;; C-x C-f /anonymous@ymir.claremont.edu:CSV/POLICY/RULES.MEM
+;;
+;; A legal VMS filename is of the form: FILE.TYPE;##
+;; where FILE can be up to 39 characters
+;; TYPE can be up to 39 characters
+;; ## is a version number (an integer between 1 and 32,767)
+;; Valid characters in FILE and TYPE are A-Z 0-9 _ - $
+;; $ cannot begin a filename, and - cannot be used as the first or last
+;; character.
+;;
+;; Tips:
+;; 1. Although VMS is not case sensitive, EMACS running under UNIX is.
+;; Therefore, to access a VMS file, you must enter the filename with upper
+;; case letters.
+;; 2. To access the latest version of file under VMS, you use the filename
+;; without the ";" and version number. You should always edit the latest
+;; version of a file. If you want to edit an earlier version, copy it to a
+;; new file first. This has nothing to do with ange-ftp, but is simply
+;; good VMS operating practice. Therefore, to edit FILE.TXT;3 (say 3 is
+;; latest version), do C-x C-f /ymir.claremont.edu:FILE.TXT. If you
+;; inadvertently do C-x C-f /ymir.claremont.edu:FILE.TXT;3, you will find
+;; that VMS will not allow you to save the file because it will refuse to
+;; overwrite FILE.TXT;3, but instead will want to create FILE.TXT;4, and
+;; attach the buffer to this file. To get out of this situation, M-x
+;; write-file /ymir.claremont.edu:FILE.TXT will attach the buffer to
+;; latest version of the file. For this reason, in dired "f"
+;; (dired-find-file), always loads the file sans version, whereas "v",
+;; (dired-view-file), always loads the explicit version number. The
+;; reasoning being that it reasonable to view old versions of a file, but
+;; not to edit them.
+;; 3. EMACS has a feature in which it does environment variable substitution
+;; in filenames. Therefore, to enter a $ in a filename, you must quote it
+;; by typing $$.
+
+;; MTS support:
+;;
+;; Ange-ftp has full support for hosts running
+;; the Michigan terminal system. It should be able to automatically
+;; recognize any MTS machine. However, if it fails to do this, you can use
+;; the command ange-ftp-add-mts-host. As well, you can set the variable
+;; ange-ftp-mts-host-regexp in your .emacs file. We would be grateful if you
+;; would report any failures to automatically recognize a MTS host as a bug.
+;;
+;; Filename syntax:
+;;
+;; MTS filenames are entered in a UNIX-y way. For example, if your account
+;; was YYYY, the file FILE in the account XXXX: on mtsg.ubc.ca would be
+;; entered as
+;; /YYYY@mtsg.ubc.ca:/XXXX:/FILE
+;; In other words, MTS accounts are treated as UNIX directories. Of course,
+;; to access a file in another account, you must have access permission for
+;; it. If FILE were in your own account, then you could enter it in a
+;; relative name fashion as
+;; /YYYY@mtsg.ubc.ca:FILE
+;; MTS filenames can be up to 12 characters. Like UNIX, the structure of the
+;; filename does not contain a TYPE (i.e. it can have as many "."'s as you
+;; like.) MTS filenames are always in upper case, and hence be sure to enter
+;; them as such! MTS is not case sensitive, but an EMACS running under UNIX
+;; is.
+
+;; CMS support:
+;;
+;; Ange-ftp has full support for hosts running
+;; CMS. It should be able to automatically recognize any CMS machine.
+;; However, if it fails to do this, you can use the command
+;; ange-ftp-add-cms-host. As well, you can set the variable
+;; ange-ftp-cms-host-regexp in your .emacs file. We would be grateful if you
+;; would report any failures to automatically recognize a CMS host as a bug.
+;;
+;; Filename syntax:
+;;
+;; CMS filenames are entered in a UNIX-y way. In otherwords, minidisks are
+;; treated as UNIX directories. For example to access the file READ.ME in
+;; minidisk *.311 on cuvmb.cc.columbia.edu, you would enter
+;; /anonymous@cuvmb.cc.columbia.edu:/*.311/READ.ME
+;; If *.301 is the default minidisk for this account, you could access
+;; FOO.BAR on this minidisk as
+;; /anonymous@cuvmb.cc.columbia.edu:FOO.BAR
+;; CMS filenames are of the form FILE.TYPE, where both FILE and TYPE can be
+;; up to 8 characters. Again, beware that CMS filenames are always upper
+;; case, and hence must be entered as such.
+;;
+;; Tips:
+;; 1. CMS machines, with the exception of anonymous accounts, nearly always
+;; need an account password. To have ange-ftp send an account password,
+;; you can either include it in your .netrc file, or use
+;; ange-ftp-set-account.
+;; 2. Ange-ftp cannot send "write passwords" for a minidisk. Hopefully, we
+;; can fix this.
+;;
+;; ------------------------------------------------------------------
+;; Bugs:
+;; ------------------------------------------------------------------
+;;
+;; 1. Umask problems:
+;; Be warned that files created by using ange-ftp will take account of the
+;; umask of the ftp daemon process rather than the umask of the creating
+;; user. This is particularly important when logging in as the root user.
+;; The way that I tighten up the ftp daemon's umask under HP-UX is to make
+;; sure that the umask is changed to 027 before I spawn /etc/inetd. I
+;; suspect that there is something similar on other systems.
+;;
+;; 2. Some combinations of FTP clients and servers break and get out of sync
+;; when asked to list a non-existent directory. Some of the ai.mit.edu
+;; machines cause this problem for some FTP clients. Using
+;; ange-ftp-kill-ftp-process can restart the ftp process, which
+;; should get things back in sync.
+;;
+;; 3. Ange-ftp does not check to make sure that when creating a new file,
+;; you provide a valid filename for the remote operating system.
+;; If you do not, then the remote FTP server will most likely
+;; translate your filename in some way. This may cause ange-ftp to
+;; get confused about what exactly is the name of the file. The
+;; most common causes of this are using lower case filenames on systems
+;; which support only upper case, and using filenames which are too
+;; long.
+;;
+;; 4. Null (blank) passwords confuse both ange-ftp and some FTP daemons.
+;;
+;; 5. Ange-ftp likes to use pty's to talk to its FTP processes. If GNU Emacs
+;; for some reason creates a FTP process that only talks via pipes then
+;; ange-ftp won't be getting the information it requires at the time that
+;; it wants it since pipes flush at different times to pty's. One
+;; disgusting way around this problem is to talk to the FTP process via
+;; rlogin which does the 'right' things with pty's.
+;;
+;; 6. For CMS support, we send too many cd's. Since cd's are cheap, I haven't
+;; worried about this too much. Eventually, we should have some caching
+;; of the current minidisk.
+;;
+;; 7. Some CMS machines do not assign a default minidisk when you ftp them as
+;; anonymous. It is then necessary to guess a valid minidisk name, and cd
+;; to it. This is (understandably) beyond ange-ftp.
+;;
+;; 8. Remote to remote copying of files on non-Unix machines can be risky.
+;; Depending on the variable ange-ftp-binary-file-name-regexp, ange-ftp
+;; will use binary mode for the copy. Between systems of different
+;; architecture, this still may not be enough to guarantee the integrity
+;; of binary files. Binary file transfers from VMS machines are
+;; particularly problematical. Should ange-ftp-binary-file-name-regexp be
+;; an alist of OS type, regexp pairs?
+;;
+;; 9. The code to do compression of files over ftp is not as careful as it
+;; should be. It deletes the old remote version of the file, before
+;; actually checking if the local to remote transfer of the compressed
+;; file succeeds. Of course to delete the original version of the file
+;; after transferring the compressed version back is also dangerous,
+;; because some OS's have severe restrictions on the length of filenames,
+;; and when the compressed version is copied back the "-Z" or ".Z" may be
+;; truncated. Then, ange-ftp would delete the only remaining version of
+;; the file. Maybe ange-ftp should make backups when it compresses files
+;; (of course, the backup "~" could also be truncated off, sigh...).
+;; Suggestions?
+;;
+;; 10. If a dir listing is attempted for an empty directory on (at least
+;; some) VMS hosts, an ftp error is given. This is really an ftp bug, and
+;; I don't know how to get ange-ftp work to around it.
+;;
+;; 11. Bombs on filenames that start with a space. Deals well with filenames
+;; containing spaces, but beware that the remote ftpd may not like them
+;; much.
+;;
+;; 12. The dired support for non-Unix-like systems does not currently work.
+;; It needs to be reimplemented by modifying the parse-...-listing
+;; functions to convert the directory listing to ls -l format.
+;;
+;; 13. The famous @ bug. As mentioned above in TIPS, ULTRIX marks symlinks
+;; with a trailing @ in a ls -alF listing. In order to account for this
+;; ange-ftp looks to chop trailing @'s off of symlink names when it is
+;; parsing a listing with the F switch. This will cause ange-ftp to
+;; incorrectly get the name of a symlink on a non-ULTRIX host if its name
+;; ends in an @. ange-ftp will correct itself if you take F out of the
+;; dired ls switches (C-u s will allow you to edit the switches). The
+;; dired buffer will be automatically reverted, which will allow ange-ftp
+;; to fix its files hashtable. A cookie to anyone who can think of a
+;; fast, sure-fire way to recognize ULTRIX over ftp.
+
+;; If you find any bugs or problems with this package, PLEASE either e-mail
+;; the above author, or send a message to the ange-ftp-lovers mailing list
+;; below. Ideas and constructive comments are especially welcome.
+
+;; ange-ftp-lovers:
+;;
+;; ange-ftp has its own mailing list modestly called ange-ftp-lovers. All
+;; users of ange-ftp are welcome to subscribe (see below) and to discuss
+;; aspects of ange-ftp. New versions of ange-ftp are posted periodically to
+;; the mailing list.
+;;
+;; To [un]subscribe to ange-ftp-lovers, or to report mailer problems with the
+;; list, please mail one of the following addresses:
+;;
+;; ange-ftp-lovers-request@anorman.hpl.hp.com
+;; or
+;; ange-ftp-lovers-request%anorman.hpl.hp.com@hplb.hpl.hp.com
+;;
+;; Please don't forget the -request part.
+;;
+;; For mail to be posted directly to ange-ftp-lovers, send to one of the
+;; following addresses:
+;;
+;; ange-ftp-lovers@anorman.hpl.hp.com
+;; or
+;; ange-ftp-lovers%anorman.hpl.hp.com@hplb.hpl.hp.com
+;;
+;; Alternatively, there is a mailing list that only gets announcements of new
+;; ange-ftp releases. This is called ange-ftp-lovers-announce, and can be
+;; subscribed to by e-mailing to the -request address as above. Please make
+;; it clear in the request which mailing list you wish to join.
+
+;; The latest version of ange-ftp can usually be obtained via anonymous ftp
+;; from:
+;; alpha.gnu.ai.mit.edu:ange-ftp/ange-ftp.tar.Z
+;; or:
+;; ugle.unit.no:/pub/gnu/emacs-lisp/ange-ftp.tar.Z
+;; or:
+;; archive.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/ange-ftp.tar.Z
+
+;; The archives for ange-ftp-lovers can be found via anonymous ftp under:
+;;
+;; ftp.reed.edu:pub/mailing-lists/ange-ftp/
\f
-;;; -----------------------------------------------------------
-;;; Technical information on this package:
-;;; -----------------------------------------------------------
-
-;;; ange-ftp works by putting a handler on file-name-handler-alist
-;;; which is called by many primitives, and a few non-primitives,
-;;; whenever they see a file name of the appropriate sort.
-
-;;; Checklist for adding non-UNIX support for TYPE
-;;;
-;;; The following functions may need TYPE versions:
-;;; (not all functions will be needed for every OS)
-;;;
-;;; ange-ftp-fix-name-for-TYPE
-;;; ange-ftp-fix-dir-name-for-TYPE
-;;; ange-ftp-TYPE-host
-;;; ange-ftp-TYPE-add-host
-;;; ange-ftp-parse-TYPE-listing
-;;; ange-ftp-TYPE-delete-file-entry
-;;; ange-ftp-TYPE-add-file-entry
-;;; ange-ftp-TYPE-file-name-as-directory
-;;; ange-ftp-TYPE-make-compressed-filename
-;;; ange-ftp-TYPE-file-name-sans-versions
-;;;
-;;; Variables:
-;;;
-;;; ange-ftp-TYPE-host-regexp
-;;; May need to add TYPE to ange-ftp-dumb-host-types
-;;;
-;;; Check the following functions for OS dependent coding:
-;;;
-;;; ange-ftp-host-type
-;;; ange-ftp-guess-host-type
-;;; ange-ftp-allow-child-lookup
-
-;;; Host type conventions:
-;;;
-;;; The function ange-ftp-host-type and the variable ange-ftp-dired-host-type
-;;; (mostly) follow the following conventions for remote host types. At
-;;; least, I think that future code should try to follow these conventions,
-;;; and the current code should eventually be made compliant.
-;;;
-;;; nil = local host type, whatever that is (probably unix).
-;;; Think nil as in "not a remote host". This value is used by
-;;; ange-ftp-dired-host-type for local buffers.
-;;;
-;;; t = a remote host of unknown type. Think t is in true, it's remote.
-;;; Currently, 'unix is used as the default remote host type.
-;;; Maybe we should use t.
-;;;
-;;; 'type = a remote host of TYPE type.
-;;;
-;;; 'type:list = a remote host of TYPE type, using a specialized ftp listing
-;;; program called list. This is currently only used for Unix
-;;; dl (descriptive listings), when ange-ftp-dired-host-type
-;;; is set to 'unix:dl.
-
-;;; Bug report codes:
-;;;
-;;; Because of their naive faith in this code, there are certain situations
-;;; which the writers of this program believe could never happen. However,
-;;; being realists they have put calls to `error' in the program at these
-;;; points. These errors provide a code, which is an integer, greater than 1.
-;;; To aid debugging. the error codes, and the functions in which they reside
-;;; are listed below.
-;;;
-;;; 1: See ange-ftp-ls
-;;;
+;; -----------------------------------------------------------
+;; Technical information on this package:
+;; -----------------------------------------------------------
+
+;; ange-ftp works by putting a handler on file-name-handler-alist
+;; which is called by many primitives, and a few non-primitives,
+;; whenever they see a file name of the appropriate sort.
+
+;; Checklist for adding non-UNIX support for TYPE
+;;
+;; The following functions may need TYPE versions:
+;; (not all functions will be needed for every OS)
+;;
+;; ange-ftp-fix-name-for-TYPE
+;; ange-ftp-fix-dir-name-for-TYPE
+;; ange-ftp-TYPE-host
+;; ange-ftp-TYPE-add-host
+;; ange-ftp-parse-TYPE-listing
+;; ange-ftp-TYPE-delete-file-entry
+;; ange-ftp-TYPE-add-file-entry
+;; ange-ftp-TYPE-file-name-as-directory
+;; ange-ftp-TYPE-make-compressed-filename
+;; ange-ftp-TYPE-file-name-sans-versions
+;;
+;; Variables:
+;;
+;; ange-ftp-TYPE-host-regexp
+;; May need to add TYPE to ange-ftp-dumb-host-types
+;;
+;; Check the following functions for OS dependent coding:
+;;
+;; ange-ftp-host-type
+;; ange-ftp-guess-host-type
+;; ange-ftp-allow-child-lookup
+
+;; Host type conventions:
+;;
+;; The function ange-ftp-host-type and the variable ange-ftp-dired-host-type
+;; (mostly) follow the following conventions for remote host types. At
+;; least, I think that future code should try to follow these conventions,
+;; and the current code should eventually be made compliant.
+;;
+;; nil = local host type, whatever that is (probably unix).
+;; Think nil as in "not a remote host". This value is used by
+;; ange-ftp-dired-host-type for local buffers.
+;;
+;; t = a remote host of unknown type. Think t is in true, it's remote.
+;; Currently, 'unix is used as the default remote host type.
+;; Maybe we should use t.
+;;
+;; 'type = a remote host of TYPE type.
+;;
+;; 'type:list = a remote host of TYPE type, using a specialized ftp listing
+;; program called list. This is currently only used for Unix
+;; dl (descriptive listings), when ange-ftp-dired-host-type
+;; is set to 'unix:dl.
+
+;; Bug report codes:
+;;
+;; Because of their naive faith in this code, there are certain situations
+;; which the writers of this program believe could never happen. However,
+;; being realists they have put calls to `error' in the program at these
+;; points. These errors provide a code, which is an integer, greater than 1.
+;; To aid debugging. the error codes, and the functions in which they reside
+;; are listed below.
+;;
+;; 1: See ange-ftp-ls
+;;
\f
-;;; -----------------------------------------------------------
-;;; Hall of fame:
-;;; -----------------------------------------------------------
-;;;
-;;; Thanks to Roland McGrath for improving the filename syntax handling,
-;;; for suggesting many enhancements and for numerous cleanups to the code.
-;;;
-;;; Thanks to Jamie Zawinski for bugfixes and for ideas such as gateways.
-;;;
-;;; Thanks to Ken Laprade for improved .netrc parsing, password reading, and
-;;; dired / shell auto-loading.
-;;;
-;;; Thanks to Sebastian Kremer for dired support and for many ideas and
-;;; bugfixes.
-;;;
-;;; Thanks to Joe Wells for bugfixes, the original non-UNIX system support,
-;;; VOS support, and hostname completion.
-;;;
-;;; Thanks to Nakagawa Takayuki for many good ideas, filename-completion, help
-;;; with file-name expansion, efficiency worries, stylistic concerns and many
-;;; bugfixes.
-;;;
-;;; Thanks to Sandy Rutherford who re-wrote most of ange-ftp to support VMS,
-;;; MTS, CMS and UNIX-dls. Sandy also added dired-support for non-UNIX OS and
-;;; auto-recognition of the host type.
-;;;
-;;; Thanks to Dave Smith who wrote the info file for ange-ftp.
-;;;
-;;; Finally, thanks to Keith Waclena, Mark D. Baushke, Terence Kelleher, Ping
-;;; Zhou, Edward Vielmetti, Jack Repenning, Mike Balenger, Todd Kaufmann,
-;;; Kjetil Svarstad, Tom Wurgler, Linus Tolke, Niko Makila, Carl Edman, Bill
-;;; Trost, Dave Brennan, Dan Jacobson, Andy Scott, Steve Anderson, Sanjay
-;;; Mathur, the folks on the ange-ftp-lovers mailing list and many others
-;;; whose names I've forgotten who have helped to debug and fix problems with
-;;; ange-ftp.el.
+;; -----------------------------------------------------------
+;; Hall of fame:
+;; -----------------------------------------------------------
+;;
+;; Thanks to Roland McGrath for improving the filename syntax handling,
+;; for suggesting many enhancements and for numerous cleanups to the code.
+;;
+;; Thanks to Jamie Zawinski for bugfixes and for ideas such as gateways.
+;;
+;; Thanks to Ken Laprade for improved .netrc parsing, password reading, and
+;; dired / shell auto-loading.
+;;
+;; Thanks to Sebastian Kremer for dired support and for many ideas and
+;; bugfixes.
+;;
+;; Thanks to Joe Wells for bugfixes, the original non-UNIX system support,
+;; VOS support, and hostname completion.
+;;
+;; Thanks to Nakagawa Takayuki for many good ideas, filename-completion, help
+;; with file-name expansion, efficiency worries, stylistic concerns and many
+;; bugfixes.
+;;
+;; Thanks to Sandy Rutherford who re-wrote most of ange-ftp to support VMS,
+;; MTS, CMS and UNIX-dls. Sandy also added dired-support for non-UNIX OS and
+;; auto-recognition of the host type.
+;;
+;; Thanks to Dave Smith who wrote the info file for ange-ftp.
+;;
+;; Finally, thanks to Keith Waclena, Mark D. Baushke, Terence Kelleher, Ping
+;; Zhou, Edward Vielmetti, Jack Repenning, Mike Balenger, Todd Kaufmann,
+;; Kjetil Svarstad, Tom Wurgler, Linus Tolke, Niko Makila, Carl Edman, Bill
+;; Trost, Dave Brennan, Dan Jacobson, Andy Scott, Steve Anderson, Sanjay
+;; Mathur, the folks on the ange-ftp-lovers mailing list and many others
+;; whose names I've forgotten who have helped to debug and fix problems with
+;; ange-ftp.el.
\f
-
;;; Code:
+
(require 'comint)
;;;; ------------------------------------------------------------
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; arc-mode.el --- simple editing of archives
-;;; Copyright (C) 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Morten Welinder (terra@diku.dk)
;; Keywords: archives msdog editing major-mode
;; Favourite-brand-of-beer: None, I hate beer.
-;;; This file is part of GNU Emacs.
-;;;
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; NAMING: "arc" is short for "archive" and does not refer specifically
;; to files whose name end in ".arc"
;;
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; autoinsert.el --- automatic mode-dependent insertion of text into new files
+
;; Copyright (C) 1985, 1986, 1987, 1994, 1995 Free Software Foundation, Inc.
;; Author: Charlie Martin <crm@cs.duke.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;;
-;;; For those who are annoyed by the mouse pointer obscuring text,
-;;; this mode moves the mouse pointer - either just a little out of
-;;; the way, or all the way to the corner of the frame.
-;;; To use, load or evaluate this file and type M-x mouse-avoidance-mode .
-;;; To set up permanently, put the following in your .emacs:
-;;;
-;;; (if window-system (mouse-avoidance-mode 'animate))
-;;;
-;;; The 'animate can be 'jump or 'banish or 'exile or 'protean if you prefer.
-;;; See the documentation for function `mouse-avoidance-mode' for
-;;; details of the different modes.
-;;;
-;;; For added silliness, make the animatee animate...
-;;; put something similar to the following into your .emacs:
-;;;
-;;; (if window-system
-;;; (mouse-avoidance-set-pointer-shape
-;;; (eval (nth (random 4)
-;;; '(x-pointer-man x-pointer-spider
-;;; x-pointer-gobbler x-pointer-gumby)))))
-;;;
-;;; For completely random pointer shape, replace the setq above with:
-;;; (setq x-pointer-shape (mouse-avoidance-random-shape))
-;;;
-;;; Bugs / Warnings / To-Do:
-;;;
-;;; - Using this code does slow emacs down. "banish" mode shouldn't
-;;; be too bad, and on my workstation even "animate" is reasonable.
-;;;
-;;; - It ought to find out where any overlapping frames are and avoid them,
-;;; rather than always raising the frame.
-
-;;; Credits:
-;;; This code was helped by all those who contributed suggestions,
-;;; fixes, and additions
-;;; Joe Harrington (and his advisor), for the original inspiration.
-;;; Ken Manheimer, for dreaming up the Protean mode.
-;;; Richard Stallman, for the awful cat-and-mouse pun, among other things.
-;;; Mike Williams, Denis Howe, Bill Benedetto, Chris Moore, Don Morris,
-;;; Simon Marshall, and M.S. Ashton, for their feedback.
-;;;
+
+;; For those who are annoyed by the mouse pointer obscuring text,
+;; this mode moves the mouse pointer - either just a little out of
+;; the way, or all the way to the corner of the frame.
+;; To use, load or evaluate this file and type M-x mouse-avoidance-mode .
+;; To set up permanently, put the following in your .emacs:
+;;
+;; (if window-system (mouse-avoidance-mode 'animate))
+;;
+;; The 'animate can be 'jump or 'banish or 'exile or 'protean if you prefer.
+;; See the documentation for function `mouse-avoidance-mode' for
+;; details of the different modes.
+;;
+;; For added silliness, make the animatee animate...
+;; put something similar to the following into your .emacs:
+;;
+;; (if window-system
+;; (mouse-avoidance-set-pointer-shape
+;; (eval (nth (random 4)
+;; '(x-pointer-man x-pointer-spider
+;; x-pointer-gobbler x-pointer-gumby)))))
+;;
+;; For completely random pointer shape, replace the setq above with:
+;; (setq x-pointer-shape (mouse-avoidance-random-shape))
+;;
+;; Bugs / Warnings / To-Do:
+;;
+;; - Using this code does slow emacs down. "banish" mode shouldn't
+;; be too bad, and on my workstation even "animate" is reasonable.
+;;
+;; - It ought to find out where any overlapping frames are and avoid them,
+;; rather than always raising the frame.
+
+;; Credits:
+;; This code was helped by all those who contributed suggestions,
+;; fixes, and additions
+;; Joe Harrington (and his advisor), for the original inspiration.
+;; Ken Manheimer, for dreaming up the Protean mode.
+;; Richard Stallman, for the awful cat-and-mouse pun, among other things.
+;; Mike Williams, Denis Howe, Bill Benedetto, Chris Moore, Don Morris,
+;; Simon Marshall, and M.S. Ashton, for their feedback.
+
;;; Code:
(provide 'avoid)
;; Author's Update Number: see variable `bookmark-version'.
;; Keywords: bookmarks, placeholders, annotations
-;;; Summary:
-;; This package is for setting "bookmarks" in files. A bookmark
-;; associates a string with a location in a certain file. Thus, you
-;; can navigate your way to that location by providing the string.
-;; See the "User Variables" section for customizations.
-
-;;; Copyright info:
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Commentary:
+
+;; This package is for setting "bookmarks" in files. A bookmark
+;; associates a string with a location in a certain file. Thus, you
+;; can navigate your way to that location by providing the string.
+;; See the "User Variables" section for customizations.
;; Thanks to David Bremner <bremner@cs.sfu.ca> for thinking of and
;; then implementing the bookmark-current-bookmark idea. He even
;; FAVORITE CHINESE RESTAURANT:
;; Boy, that's a tough one. Probably Hong Min, or maybe Emperor's
;; Choice (both in Chicago's Chinatown). Well, both. How about you?
-
-\f
-(require 'pp)
-
\f
;;;; Code:
+(require 'pp)
+
(defconst bookmark-version "2.6.20"
"Version number of bookmark.el. This is not related to the version
of Emacs bookmark comes with; it is used solely by bookmark's
;;; browse-url.el --- ask a WWW browser to load a URL
+
;; Copyright 1995 Free Software Foundation, Inc.
;; Author: Denis Howe <dbh@doc.ic.ac.uk>
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published
-;; by the Free Software Foundation; either version 2, or (at your
-;; option) any later version.
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;; GNU Emacs is distributed in the hope that it will be useful, but
-;; WITHOUT ANY WARRANTY; without even the implied warranty of
-;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-;; General Public License for more details.
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING. If not, write to the
-;; Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Commentary:
;; The latest version of this package should be available from
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; interface to selectively inlining functions.
-;;; This only happens when source-code optimization is turned on.
+;; interface to selectively inlining functions.
+;; This only happens when source-code optimization is turned on.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; This collection of functions implements the creation of LaTeX calendars
;; based on the user's holiday choices and diary file.
-;;; TO DO
-;;;
-;;; (*) Add holidays and diary entries to daily calendar.
-;;;
-;;; (*) Add diary entries to weekly calendar functions.
-;;;
-;;; (*) Make calendar styles for A4 paper.
-;;;
-;;; (*) Make daily and monthly styles Filofax paper.
-;;;
-;;; (*) Improve the LaTeX command that produces the boxes in the monthly
-;;; calendar to eliminate slight gap--what causes it?!
+;; TO DO
+;;
+;; (*) Add holidays and diary entries to daily calendar.
+;;
+;; (*) Add diary entries to weekly calendar functions.
+;;
+;; (*) Make calendar styles for A4 paper.
+;;
+;; (*) Make daily and monthly styles Filofax paper.
+;;
+;; (*) Improve the LaTeX command that produces the boxes in the monthly
+;; calendar to eliminate slight gap--what causes it?!
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; calendar.el --- Calendar functions. -*-byte-compile-dynamic: t;-*-
+;;; calendar.el --- Calendar functions.
-;;; Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995 Free Software
-;;; Foundation, Inc.
+;; Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995 Free
+;; Software Foundation, Inc.
;; Author: Edward M. Reingold <reingold@cs.uiuc.edu>
;; Keywords: calendar
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
(provide 'calendar)
+;;; Local variables:
+;;; byte-compile-dynamic: t
+;;; End:
+
;;; calendar.el ends here
;;; diary-lib.el --- diary functions.
-;; Copyright (C) 1989, 1990, 1992, 1993, 1994, 1995 Free Software Foundation,
-;; Inc.
+;; Copyright (C) 1989, 1990, 1992, 1993, 1994, 1995 Free Software
+;; Foundation, Inc.
;; Author: Edward M. Reingold <reingold@cs.uiuc.edu>
;; Keywords: calendar
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; holidays.el --- holiday functions for the calendar package
-;;; Copyright (C) 1989, 1990, 1992, 1993, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1989, 1990, 1992, 1993, 1994 Free Software Foundation, Inc.
;; Author: Edward M. Reingold <reingold@cs.uiuc.edu>
;; Keywords: holidays, calendar
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This is a customisation of comint-mode (see comint.el)
-;;;
-;;; Written by Olin Shivers (olin.shivers@cs.cmu.edu). With bits and pieces
-;;; lifted from scheme.el, shell.el, clisp.el, newclisp.el, cobol.el, et al..
-;;; 8/88
-;;;
-;;; Please send me bug reports, bug fixes, and extensions, so that I can
-;;; merge them into the master source.
-;;;
-;;; The changelog is at the end of this file.
-;;;
-;;; NOTE: MIT Cscheme, when invoked with the -emacs flag, has a special user
-;;; interface that communicates process state back to the superior emacs by
-;;; outputting special control sequences. The gnumacs package, xscheme.el, has
-;;; lots and lots of special purpose code to read these control sequences, and
-;;; so is very tightly integrated with the cscheme process. The cscheme
-;;; interrupt handler and debugger read single character commands in cbreak
-;;; mode; when this happens, xscheme.el switches to special keymaps that bind
-;;; the single letter command keys to emacs functions that directly send the
-;;; character to the scheme process. Cmuscheme mode does *not* provide this
-;;; functionality. If you are a cscheme user, you may prefer to use the
-;;; xscheme.el/cscheme -emacs interaction.
-;;;
-;;; Here's a summary of the pros and cons, as I see them.
-;;; xscheme: Tightly integrated with inferior cscheme process! A few commands
-;;; not in cmuscheme. But. Integration is a bit of a hack. Input
-;;; history only keeps the immediately prior input. Bizarre
-;;; keybindings.
-;;;
-;;; cmuscheme: Not tightly integrated with inferior cscheme process. But.
-;;; Carefully integrated functionality with the entire suite of
-;;; comint-derived CMU process modes. Keybindings reminiscent of
-;;; Zwei and Hemlock. Good input history. A few commands not in
-;;; xscheme.
-;;;
-;;; It's a tradeoff. Pay your money; take your choice. If you use a Scheme
-;;; that isn't Cscheme, of course, there isn't a choice. Xscheme.el is *very*
-;;; Cscheme-specific; you must use cmuscheme.el. Interested parties are
-;;; invited to port xscheme functionality on top of comint mode...
+;; This is a customisation of comint-mode (see comint.el)
+;;
+;; Written by Olin Shivers (olin.shivers@cs.cmu.edu). With bits and pieces
+;; lifted from scheme.el, shell.el, clisp.el, newclisp.el, cobol.el, et al..
+;; 8/88
+;;
+;; Please send me bug reports, bug fixes, and extensions, so that I can
+;; merge them into the master source.
+;;
+;; The changelog is at the end of this file.
+;;
+;; NOTE: MIT Cscheme, when invoked with the -emacs flag, has a special user
+;; interface that communicates process state back to the superior emacs by
+;; outputting special control sequences. The gnumacs package, xscheme.el, has
+;; lots and lots of special purpose code to read these control sequences, and
+;; so is very tightly integrated with the cscheme process. The cscheme
+;; interrupt handler and debugger read single character commands in cbreak
+;; mode; when this happens, xscheme.el switches to special keymaps that bind
+;; the single letter command keys to emacs functions that directly send the
+;; character to the scheme process. Cmuscheme mode does *not* provide this
+;; functionality. If you are a cscheme user, you may prefer to use the
+;; xscheme.el/cscheme -emacs interaction.
+;;
+;; Here's a summary of the pros and cons, as I see them.
+;; xscheme: Tightly integrated with inferior cscheme process! A few commands
+;; not in cmuscheme. But. Integration is a bit of a hack. Input
+;; history only keeps the immediately prior input. Bizarre
+;; keybindings.
+;;
+;; cmuscheme: Not tightly integrated with inferior cscheme process. But.
+;; Carefully integrated functionality with the entire suite of
+;; comint-derived CMU process modes. Keybindings reminiscent of
+;; Zwei and Hemlock. Good input history. A few commands not in
+;; xscheme.
+;;
+;; It's a tradeoff. Pay your money; take your choice. If you use a Scheme
+;; that isn't Cscheme, of course, there isn't a choice. Xscheme.el is *very*
+;; Cscheme-specific; you must use cmuscheme.el. Interested parties are
+;; invited to port xscheme functionality on top of comint mode...
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Please send me bug reports, bug fixes, and extensions, so that I can
-;;; merge them into the master source.
-;;; - Olin Shivers (shivers@cs.cmu.edu)
-;;; - Simon Marshall (simon@gnu.ai.mit.edu)
-
-;;; This file defines a general command-interpreter-in-a-buffer package
-;;; (comint mode). The idea is that you can build specific process-in-a-buffer
-;;; modes on top of comint mode -- e.g., lisp, shell, scheme, T, soar, ....
-;;; This way, all these specific packages share a common base functionality,
-;;; and a common set of bindings, which makes them easier to use (and
-;;; saves code, implementation time, etc., etc.).
-
-;;; Several packages are already defined using comint mode:
-;;; - shell.el defines a shell-in-a-buffer mode.
-;;; - cmulisp.el defines a simple lisp-in-a-buffer mode.
-;;;
-;;; - The file cmuscheme.el defines a scheme-in-a-buffer mode.
-;;; - The file tea.el tunes scheme and inferior-scheme modes for T.
-;;; - The file soar.el tunes lisp and inferior-lisp modes for Soar.
-;;; - cmutex.el defines tex and latex modes that invoke tex, latex, bibtex,
-;;; previewers, and printers from within emacs.
-;;; - background.el allows csh-like job control inside emacs.
-;;; It is pretty easy to make new derived modes for other processes.
-
-;;; For documentation on the functionality provided by comint mode, and
-;;; the hooks available for customising it, see the comments below.
-;;; For further information on the standard derived modes (shell,
-;;; inferior-lisp, inferior-scheme, ...), see the relevant source files.
-
-;;; For hints on converting existing process modes (e.g., tex-mode,
-;;; background, dbx, gdb, kermit, prolog, telnet) to use comint-mode
-;;; instead of shell-mode, see the notes at the end of this file.
+;; Please send me bug reports, bug fixes, and extensions, so that I can
+;; merge them into the master source.
+;; - Olin Shivers (shivers@cs.cmu.edu)
+;; - Simon Marshall (simon@gnu.ai.mit.edu)
+
+;; This file defines a general command-interpreter-in-a-buffer package
+;; (comint mode). The idea is that you can build specific process-in-a-buffer
+;; modes on top of comint mode -- e.g., lisp, shell, scheme, T, soar, ....
+;; This way, all these specific packages share a common base functionality,
+;; and a common set of bindings, which makes them easier to use (and
+;; saves code, implementation time, etc., etc.).
+
+;; Several packages are already defined using comint mode:
+;; - shell.el defines a shell-in-a-buffer mode.
+;; - cmulisp.el defines a simple lisp-in-a-buffer mode.
+;;
+;; - The file cmuscheme.el defines a scheme-in-a-buffer mode.
+;; - The file tea.el tunes scheme and inferior-scheme modes for T.
+;; - The file soar.el tunes lisp and inferior-lisp modes for Soar.
+;; - cmutex.el defines tex and latex modes that invoke tex, latex, bibtex,
+;; previewers, and printers from within emacs.
+;; - background.el allows csh-like job control inside emacs.
+;; It is pretty easy to make new derived modes for other processes.
+
+;; For documentation on the functionality provided by comint mode, and
+;; the hooks available for customising it, see the comments below.
+;; For further information on the standard derived modes (shell,
+;; inferior-lisp, inferior-scheme, ...), see the relevant source files.
+
+;; For hints on converting existing process modes (e.g., tex-mode,
+;; background, dbx, gdb, kermit, prolog, telnet) to use comint-mode
+;; instead of shell-mode, see the notes at the end of this file.
\f
-;;; Brief Command Documentation:
-;;;============================================================================
-;;; Comint Mode Commands: (common to all derived modes, like shell & cmulisp
-;;; mode)
-;;;
-;;; m-p comint-previous-input Cycle backwards in input history
-;;; m-n comint-next-input Cycle forwards
-;;; m-r comint-previous-matching-input Previous input matching a regexp
-;;; m-s comint-next-matching-input Next input that matches
-;;; m-c-l comint-show-output Show last batch of process output
-;;; return comint-send-input
-;;; c-d comint-delchar-or-maybe-eof Delete char unless at end of buff
-;;; c-c c-a comint-bol Beginning of line; skip prompt
-;;; c-c c-u comint-kill-input ^u
-;;; c-c c-w backward-kill-word ^w
-;;; c-c c-c comint-interrupt-subjob ^c
-;;; c-c c-z comint-stop-subjob ^z
-;;; c-c c-\ comint-quit-subjob ^\
-;;; c-c c-o comint-kill-output Delete last batch of process output
-;;; c-c c-r comint-show-output Show last batch of process output
-;;; c-c c-l comint-dynamic-list-input-ring List input history
-;;;
-;;; Not bound by default in comint-mode (some are in shell mode)
-;;; comint-run Run a program under comint-mode
-;;; send-invisible Read a line w/o echo, and send to proc
-;;; comint-dynamic-complete-filename Complete filename at point.
-;;; comint-dynamic-complete-variable Complete variable name at point.
-;;; comint-dynamic-list-filename-completions List completions in help buffer.
-;;; comint-replace-by-expanded-filename Expand and complete filename at point;
-;;; replace with expanded/completed name.
-;;; comint-replace-by-expanded-history Expand history at point;
-;;; replace with expanded name.
-;;; comint-magic-space Expand history and add (a) space(s).
-;;; comint-kill-subjob No mercy.
-;;; comint-show-maximum-output Show as much output as possible.
-;;; comint-continue-subjob Send CONT signal to buffer's process
-;;; group. Useful if you accidentally
-;;; suspend your process (with C-c C-z).
-
-;;; comint-mode-hook is the comint mode hook. Basically for your keybindings.
+;; Brief Command Documentation:
+;;============================================================================
+;; Comint Mode Commands: (common to all derived modes, like shell & cmulisp
+;; mode)
+;;
+;; m-p comint-previous-input Cycle backwards in input history
+;; m-n comint-next-input Cycle forwards
+;; m-r comint-previous-matching-input Previous input matching a regexp
+;; m-s comint-next-matching-input Next input that matches
+;; m-c-l comint-show-output Show last batch of process output
+;; return comint-send-input
+;; c-d comint-delchar-or-maybe-eof Delete char unless at end of buff
+;; c-c c-a comint-bol Beginning of line; skip prompt
+;; c-c c-u comint-kill-input ^u
+;; c-c c-w backward-kill-word ^w
+;; c-c c-c comint-interrupt-subjob ^c
+;; c-c c-z comint-stop-subjob ^z
+;; c-c c-\ comint-quit-subjob ^\
+;; c-c c-o comint-kill-output Delete last batch of process output
+;; c-c c-r comint-show-output Show last batch of process output
+;; c-c c-l comint-dynamic-list-input-ring List input history
+;;
+;; Not bound by default in comint-mode (some are in shell mode)
+;; comint-run Run a program under comint-mode
+;; send-invisible Read a line w/o echo, and send to proc
+;; comint-dynamic-complete-filename Complete filename at point.
+;; comint-dynamic-complete-variable Complete variable name at point.
+;; comint-dynamic-list-filename-completions List completions in help buffer.
+;; comint-replace-by-expanded-filename Expand and complete filename at point;
+;; replace with expanded/completed name.
+;; comint-replace-by-expanded-history Expand history at point;
+;; replace with expanded name.
+;; comint-magic-space Expand history and add (a) space(s).
+;; comint-kill-subjob No mercy.
+;; comint-show-maximum-output Show as much output as possible.
+;; comint-continue-subjob Send CONT signal to buffer's process
+;; group. Useful if you accidentally
+;; suspend your process (with C-c C-z).
+
+;; comint-mode-hook is the comint mode hook. Basically for your keybindings.
;;; Code:
(require 'ring)
\f
-;;; Buffer Local Variables:
-;;;============================================================================
-;;; Comint mode buffer local variables:
-;;; comint-prompt-regexp - string comint-bol uses to match prompt
-;;; comint-delimiter-argument-list - list For delimiters and arguments
-;;; comint-last-input-start - marker Handy if inferior always echoes
-;;; comint-last-input-end - marker For comint-kill-output command
-;;; comint-input-ring-size - integer For the input history
-;;; comint-input-ring - ring mechanism
-;;; comint-input-ring-index - number ...
-;;; comint-input-autoexpand - symbol ...
-;;; comint-input-ignoredups - boolean ...
-;;; comint-last-input-match - string ...
-;;; comint-dynamic-complete-functions - hook For the completion mechanism
-;;; comint-completion-fignore - list ...
-;;; comint-file-name-quote-list - list ...
-;;; comint-get-old-input - function Hooks for specific
-;;; comint-input-filter-functions - hook process-in-a-buffer
-;;; comint-output-filter-functions - hook function modes.
-;;; comint-input-filter - function ...
-;;; comint-input-sender - function ...
-;;; comint-eol-on-send - boolean ...
-;;; comint-process-echoes - boolean ...
-;;; comint-scroll-to-bottom-on-input - symbol For scroll behavior
-;;; comint-scroll-to-bottom-on-output - symbol ...
-;;; comint-scroll-show-maximum-output - boolean...
-;;;
-;;; Comint mode non-buffer local variables:
-;;; comint-completion-addsuffix - boolean/cons For file name completion
-;;; comint-completion-autolist - boolean behavior
-;;; comint-completion-recexact - boolean ...
+;; Buffer Local Variables:
+;;============================================================================
+;; Comint mode buffer local variables:
+;; comint-prompt-regexp - string comint-bol uses to match prompt
+;; comint-delimiter-argument-list - list For delimiters and arguments
+;; comint-last-input-start - marker Handy if inferior always echoes
+;; comint-last-input-end - marker For comint-kill-output command
+;; comint-input-ring-size - integer For the input history
+;; comint-input-ring - ring mechanism
+;; comint-input-ring-index - number ...
+;; comint-input-autoexpand - symbol ...
+;; comint-input-ignoredups - boolean ...
+;; comint-last-input-match - string ...
+;; comint-dynamic-complete-functions - hook For the completion mechanism
+;; comint-completion-fignore - list ...
+;; comint-file-name-quote-list - list ...
+;; comint-get-old-input - function Hooks for specific
+;; comint-input-filter-functions - hook process-in-a-buffer
+;; comint-output-filter-functions - hook function modes.
+;; comint-input-filter - function ...
+;; comint-input-sender - function ...
+;; comint-eol-on-send - boolean ...
+;; comint-process-echoes - boolean ...
+;; comint-scroll-to-bottom-on-input - symbol For scroll behavior
+;; comint-scroll-to-bottom-on-output - symbol ...
+;; comint-scroll-show-maximum-output - boolean...
+;;
+;; Comint mode non-buffer local variables:
+;; comint-completion-addsuffix - boolean/cons For file name completion
+;; comint-completion-autolist - boolean behavior
+;; comint-completion-recexact - boolean ...
(defvar comint-prompt-regexp "^"
"Regexp to recognise prompts in the inferior process.
"*Regexp matching prompts for passwords in the inferior process.
This is used by `comint-watch-for-password-prompt'.")
-;;; Here are the per-interpreter hooks.
+;; Here are the per-interpreter hooks.
(defvar comint-get-old-input (function comint-get-old-input-default)
"Function that returns old text in comint mode.
This function is called when return is typed while the point is in old text.
(let ((proc (get-buffer-process buffer)))
(and proc (memq (process-status proc) '(open run stop)))))
-;;; Note that this guy, unlike shell.el's make-shell, barfs if you pass it ()
-;;; for the second argument (program).
-;;;###autoload
+;; Note that this guy, unlike shell.el's make-shell, barfs if you pass it ()
+;; for the second argument (program).
+;;###autoload
(defun make-comint (name program &optional startfile &rest switches)
"Make a comint process NAME in a buffer, running PROGRAM.
The name of the buffer is made by surrounding NAME with `*'s.
(comint-exec buffer name program startfile switches)))
buffer))
-;;;###autoload
+;;###autoload
(defun comint-run (program)
"Run PROGRAM in a comint buffer and switch to it.
The buffer name is made by surrounding the file name of PROGRAM with `*'s.
(run-hooks 'comint-exec-hook)
buffer)))
-;;; This auxiliary function cranks up the process for comint-exec in
-;;; the appropriate environment.
+;; This auxiliary function cranks up the process for comint-exec in
+;; the appropriate environment.
(defun comint-exec-1 (name buffer command switches)
(let ((process-environment
"/")))
(apply 'start-process name buffer command switches)))
\f
-;;; Input history processing in a buffer
-;;; ===========================================================================
-;;; Useful input history functions, courtesy of the Ergo group.
-
-;;; Eleven commands:
-;;; comint-dynamic-list-input-ring List history in help buffer.
-;;; comint-previous-input Previous input...
-;;; comint-previous-matching-input ...matching a string.
-;;; comint-previous-matching-input-from-input ... matching the current input.
-;;; comint-next-input Next input...
-;;; comint-next-matching-input ...matching a string.
-;;; comint-next-matching-input-from-input ... matching the current input.
-;;; comint-backward-matching-input Backwards input...
-;;; comint-forward-matching-input ...matching a string.
-;;; comint-replace-by-expanded-history Expand history at point;
-;;; replace with expanded history.
-;;; comint-magic-space Expand history and insert space.
-;;;
-;;; Three functions:
-;;; comint-read-input-ring Read into comint-input-ring...
-;;; comint-write-input-ring Write to comint-input-ring-file-name.
-;;; comint-replace-by-expanded-history-before-point Workhorse function.
+;; Input history processing in a buffer
+;; ===========================================================================
+;; Useful input history functions, courtesy of the Ergo group.
+
+;; Eleven commands:
+;; comint-dynamic-list-input-ring List history in help buffer.
+;; comint-previous-input Previous input...
+;; comint-previous-matching-input ...matching a string.
+;; comint-previous-matching-input-from-input ... matching the current input.
+;; comint-next-input Next input...
+;; comint-next-matching-input ...matching a string.
+;; comint-next-matching-input-from-input ... matching the current input.
+;; comint-backward-matching-input Backwards input...
+;; comint-forward-matching-input ...matching a string.
+;; comint-replace-by-expanded-history Expand history at point;
+;; replace with expanded history.
+;; comint-magic-space Expand history and insert space.
+;;
+;; Three functions:
+;; comint-read-input-ring Read into comint-input-ring...
+;; comint-write-input-ring Write to comint-input-ring-file-name.
+;; comint-replace-by-expanded-history-before-point Workhorse function.
(defun comint-read-input-ring (&optional silent)
"Sets the buffer's `comint-input-ring' from a history file.
(mapconcat
(function (lambda (a) a)) (nthcdr n (nreverse (nthcdr m args))) " "))))
\f
-;;;
-;;; Input processing stuff
-;;;
+;;
+;; Input processing stuff
+;;
(defun comint-send-input ()
"Send input to process.
(beginning-of-line)
(if (null arg) (comint-skip-prompt)))
-;;; These three functions are for entering text you don't want echoed or
-;;; saved -- typically passwords to ftp, telnet, or somesuch.
-;;; Just enter m-x send-invisible and type in your line, or add
-;;; `comint-watch-for-password-prompt' to `comint-output-filter-functions'.
+;; These three functions are for entering text you don't want echoed or
+;; saved -- typically passwords to ftp, telnet, or somesuch.
+;; Just enter m-x send-invisible and type in your line, or add
+;; `comint-watch-for-password-prompt' to `comint-output-filter-functions'.
(defun comint-read-noecho (prompt &optional stars)
"Read a single line of text from user without echoing, and return it.
(if (string-match comint-password-prompt-regexp string)
(send-invisible nil)))
\f
-;;; Low-level process communication
+;; Low-level process communication
(defalias 'comint-send-string 'process-send-string)
(defalias 'comint-send-region 'process-send-region)
\f
-;;; Random input hackage
+;; Random input hackage
(defun comint-kill-output ()
"Kill all output from interpreter since last input.
(interactive "p")
(comint-next-prompt (- n)))
\f
-;;; Support for source-file processing commands.
-;;;============================================================================
-;;; Many command-interpreters (e.g., Lisp, Scheme, Soar) have
-;;; commands that process files of source text (e.g. loading or compiling
-;;; files). So the corresponding process-in-a-buffer modes have commands
-;;; for doing this (e.g., lisp-load-file). The functions below are useful
-;;; for defining these commands.
-;;;
-;;; Alas, these guys don't do exactly the right thing for Lisp, Scheme
-;;; and Soar, in that they don't know anything about file extensions.
-;;; So the compile/load interface gets the wrong default occasionally.
-;;; The load-file/compile-file default mechanism could be smarter -- it
-;;; doesn't know about the relationship between filename extensions and
-;;; whether the file is source or executable. If you compile foo.lisp
-;;; with compile-file, then the next load-file should use foo.bin for
-;;; the default, not foo.lisp. This is tricky to do right, particularly
-;;; because the extension for executable files varies so much (.o, .bin,
-;;; .lbin, .mo, .vo, .ao, ...).
-
-
-;;; COMINT-SOURCE-DEFAULT -- determines defaults for source-file processing
-;;; commands.
-;;;
-;;; COMINT-CHECK-SOURCE -- if FNAME is in a modified buffer, asks you if you
-;;; want to save the buffer before issuing any process requests to the command
-;;; interpreter.
-;;;
-;;; COMINT-GET-SOURCE -- used by the source-file processing commands to prompt
-;;; for the file to process.
-
-;;; (COMINT-SOURCE-DEFAULT previous-dir/file source-modes)
-;;;============================================================================
-;;; This function computes the defaults for the load-file and compile-file
-;;; commands for tea, soar, cmulisp, and cmuscheme modes.
-;;;
-;;; - PREVIOUS-DIR/FILE is a pair (directory . filename) from the last
-;;; source-file processing command. NIL if there hasn't been one yet.
-;;; - SOURCE-MODES is a list used to determine what buffers contain source
-;;; files: if the major mode of the buffer is in SOURCE-MODES, it's source.
-;;; Typically, (lisp-mode) or (scheme-mode).
-;;;
-;;; If the command is given while the cursor is inside a string, *and*
-;;; the string is an existing filename, *and* the filename is not a directory,
-;;; then the string is taken as default. This allows you to just position
-;;; your cursor over a string that's a filename and have it taken as default.
-;;;
-;;; If the command is given in a file buffer whose major mode is in
-;;; SOURCE-MODES, then the the filename is the default file, and the
-;;; file's directory is the default directory.
-;;;
-;;; If the buffer isn't a source file buffer (e.g., it's the process buffer),
-;;; then the default directory & file are what was used in the last source-file
-;;; processing command (i.e., PREVIOUS-DIR/FILE). If this is the first time
-;;; the command has been run (PREVIOUS-DIR/FILE is nil), the default directory
-;;; is the cwd, with no default file. (\"no default file\" = nil)
-;;;
-;;; SOURCE-REGEXP is typically going to be something like (tea-mode)
-;;; for T programs, (lisp-mode) for Lisp programs, (soar-mode lisp-mode)
-;;; for Soar programs, etc.
-;;;
-;;; The function returns a pair: (default-directory . default-file).
+;; Support for source-file processing commands.
+;;============================================================================
+;; Many command-interpreters (e.g., Lisp, Scheme, Soar) have
+;; commands that process files of source text (e.g. loading or compiling
+;; files). So the corresponding process-in-a-buffer modes have commands
+;; for doing this (e.g., lisp-load-file). The functions below are useful
+;; for defining these commands.
+;;
+;; Alas, these guys don't do exactly the right thing for Lisp, Scheme
+;; and Soar, in that they don't know anything about file extensions.
+;; So the compile/load interface gets the wrong default occasionally.
+;; The load-file/compile-file default mechanism could be smarter -- it
+;; doesn't know about the relationship between filename extensions and
+;; whether the file is source or executable. If you compile foo.lisp
+;; with compile-file, then the next load-file should use foo.bin for
+;; the default, not foo.lisp. This is tricky to do right, particularly
+;; because the extension for executable files varies so much (.o, .bin,
+;; .lbin, .mo, .vo, .ao, ...).
+
+
+;; COMINT-SOURCE-DEFAULT -- determines defaults for source-file processing
+;; commands.
+;;
+;; COMINT-CHECK-SOURCE -- if FNAME is in a modified buffer, asks you if you
+;; want to save the buffer before issuing any process requests to the command
+;; interpreter.
+;;
+;; COMINT-GET-SOURCE -- used by the source-file processing commands to prompt
+;; for the file to process.
+
+;; (COMINT-SOURCE-DEFAULT previous-dir/file source-modes)
+;;============================================================================
+;; This function computes the defaults for the load-file and compile-file
+;; commands for tea, soar, cmulisp, and cmuscheme modes.
+;;
+;; - PREVIOUS-DIR/FILE is a pair (directory . filename) from the last
+;; source-file processing command. NIL if there hasn't been one yet.
+;; - SOURCE-MODES is a list used to determine what buffers contain source
+;; files: if the major mode of the buffer is in SOURCE-MODES, it's source.
+;; Typically, (lisp-mode) or (scheme-mode).
+;;
+;; If the command is given while the cursor is inside a string, *and*
+;; the string is an existing filename, *and* the filename is not a directory,
+;; then the string is taken as default. This allows you to just position
+;; your cursor over a string that's a filename and have it taken as default.
+;;
+;; If the command is given in a file buffer whose major mode is in
+;; SOURCE-MODES, then the the filename is the default file, and the
+;; file's directory is the default directory.
+;;
+;; If the buffer isn't a source file buffer (e.g., it's the process buffer),
+;; then the default directory & file are what was used in the last source-file
+;; processing command (i.e., PREVIOUS-DIR/FILE). If this is the first time
+;; the command has been run (PREVIOUS-DIR/FILE is nil), the default directory
+;; is the cwd, with no default file. (\"no default file\" = nil)
+;;
+;; SOURCE-REGEXP is typically going to be something like (tea-mode)
+;; for T programs, (lisp-mode) for Lisp programs, (soar-mode lisp-mode)
+;; for Soar programs, etc.
+;;
+;; The function returns a pair: (default-directory . default-file).
(defun comint-source-default (previous-dir/file source-modes)
(cond ((and buffer-file-name (memq major-mode source-modes))
(cons default-directory nil))))
-;;; (COMINT-CHECK-SOURCE fname)
-;;;============================================================================
-;;; Prior to loading or compiling (or otherwise processing) a file (in the CMU
-;;; process-in-a-buffer modes), this function can be called on the filename.
-;;; If the file is loaded into a buffer, and the buffer is modified, the user
-;;; is queried to see if he wants to save the buffer before proceeding with
-;;; the load or compile.
+;; (COMINT-CHECK-SOURCE fname)
+;;============================================================================
+;; Prior to loading or compiling (or otherwise processing) a file (in the CMU
+;; process-in-a-buffer modes), this function can be called on the filename.
+;; If the file is loaded into a buffer, and the buffer is modified, the user
+;; is queried to see if he wants to save the buffer before proceeding with
+;; the load or compile.
(defun comint-check-source (fname)
(let ((buff (get-file-buffer fname)))
(set-buffer old-buffer)))))
-;;; (COMINT-GET-SOURCE prompt prev-dir/file source-modes mustmatch-p)
-;;;============================================================================
-;;; COMINT-GET-SOURCE is used to prompt for filenames in command-interpreter
-;;; commands that process source files (like loading or compiling a file).
-;;; It prompts for the filename, provides a default, if there is one,
-;;; and returns the result filename.
-;;;
-;;; See COMINT-SOURCE-DEFAULT for more on determining defaults.
-;;;
-;;; PROMPT is the prompt string. PREV-DIR/FILE is the (directory . file) pair
-;;; from the last source processing command. SOURCE-MODES is a list of major
-;;; modes used to determine what file buffers contain source files. (These
-;;; two arguments are used for determining defaults). If MUSTMATCH-P is true,
-;;; then the filename reader will only accept a file that exists.
-;;;
-;;; A typical use:
-;;; (interactive (comint-get-source "Compile file: " prev-lisp-dir/file
-;;; '(lisp-mode) t))
-
-;;; This is pretty stupid about strings. It decides we're in a string
-;;; if there's a quote on both sides of point on the current line.
+;; (COMINT-GET-SOURCE prompt prev-dir/file source-modes mustmatch-p)
+;;============================================================================
+;; COMINT-GET-SOURCE is used to prompt for filenames in command-interpreter
+;; commands that process source files (like loading or compiling a file).
+;; It prompts for the filename, provides a default, if there is one,
+;; and returns the result filename.
+;;
+;; See COMINT-SOURCE-DEFAULT for more on determining defaults.
+;;
+;; PROMPT is the prompt string. PREV-DIR/FILE is the (directory . file) pair
+;; from the last source processing command. SOURCE-MODES is a list of major
+;; modes used to determine what file buffers contain source files. (These
+;; two arguments are used for determining defaults). If MUSTMATCH-P is true,
+;; then the filename reader will only accept a file that exists.
+;;
+;; A typical use:
+;; (interactive (comint-get-source "Compile file: " prev-lisp-dir/file
+;; '(lisp-mode) t))
+
+;; This is pretty stupid about strings. It decides we're in a string
+;; if there's a quote on both sides of point on the current line.
(defun comint-extract-string ()
"Return string around POINT that starts the current line, or nil."
(save-excursion
mustmatch-p)))
(list (expand-file-name (substitute-in-file-name ans)))))
-;;; I am somewhat divided on this string-default feature. It seems
-;;; to violate the principle-of-least-astonishment, in that it makes
-;;; the default harder to predict, so you actually have to look and see
-;;; what the default really is before choosing it. This can trip you up.
-;;; On the other hand, it can be useful, I guess. I would appreciate feedback
-;;; on this.
-;;; -Olin
+;; I am somewhat divided on this string-default feature. It seems
+;; to violate the principle-of-least-astonishment, in that it makes
+;; the default harder to predict, so you actually have to look and see
+;; what the default really is before choosing it. This can trip you up.
+;; On the other hand, it can be useful, I guess. I would appreciate feedback
+;; on this.
+;; -Olin
\f
-;;; Simple process query facility.
-;;; ===========================================================================
-;;; This function is for commands that want to send a query to the process
-;;; and show the response to the user. For example, a command to get the
-;;; arglist for a Common Lisp function might send a "(arglist 'foo)" query
-;;; to an inferior Common Lisp process.
-;;;
-;;; This simple facility just sends strings to the inferior process and pops
-;;; up a window for the process buffer so you can see what the process
-;;; responds with. We don't do anything fancy like try to intercept what the
-;;; process responds with and put it in a pop-up window or on the message
-;;; line. We just display the buffer. Low tech. Simple. Works good.
-
-;;; Send to the inferior process PROC the string STR. Pop-up but do not select
-;;; a window for the inferior process so that its response can be seen.
+;; Simple process query facility.
+;; ===========================================================================
+;; This function is for commands that want to send a query to the process
+;; and show the response to the user. For example, a command to get the
+;; arglist for a Common Lisp function might send a "(arglist 'foo)" query
+;; to an inferior Common Lisp process.
+;;
+;; This simple facility just sends strings to the inferior process and pops
+;; up a window for the process buffer so you can see what the process
+;; responds with. We don't do anything fancy like try to intercept what the
+;; process responds with and put it in a pop-up window or on the message
+;; line. We just display the buffer. Low tech. Simple. Works good.
+
+;; Send to the inferior process PROC the string STR. Pop-up but do not select
+;; a window for the inferior process so that its response can be seen.
(defun comint-proc-query (proc str)
(let* ((proc-buf (process-buffer proc))
(proc-mark (process-mark proc)))
(set-window-point proc-win opoint)))))))
\f
-;;; Filename/command/history completion in a buffer
-;;; ===========================================================================
-;;; Useful completion functions, courtesy of the Ergo group.
-
-;;; Six commands:
-;;; comint-dynamic-complete Complete or expand command, filename,
-;;; history at point.
-;;; comint-dynamic-complete-filename Complete filename at point.
-;;; comint-dynamic-list-filename-completions List completions in help buffer.
-;;; comint-replace-by-expanded-filename Expand and complete filename at point;
-;;; replace with expanded/completed name.
-;;; comint-dynamic-simple-complete Complete stub given candidates.
-
-;;; These are not installed in the comint-mode keymap. But they are
-;;; available for people who want them. Shell-mode installs them:
-;;; (define-key shell-mode-map "\t" 'comint-dynamic-complete)
-;;; (define-key shell-mode-map "\M-?"
-;;; 'comint-dynamic-list-filename-completions)))
-;;;
-;;; Commands like this are fine things to put in load hooks if you
-;;; want them present in specific modes.
+;; Filename/command/history completion in a buffer
+;; ===========================================================================
+;; Useful completion functions, courtesy of the Ergo group.
+
+;; Six commands:
+;; comint-dynamic-complete Complete or expand command, filename,
+;; history at point.
+;; comint-dynamic-complete-filename Complete filename at point.
+;; comint-dynamic-list-filename-completions List completions in help buffer.
+;; comint-replace-by-expanded-filename Expand and complete filename at point;
+;; replace with expanded/completed name.
+;; comint-dynamic-simple-complete Complete stub given candidates.
+
+;; These are not installed in the comint-mode keymap. But they are
+;; available for people who want them. Shell-mode installs them:
+;; (define-key shell-mode-map "\t" 'comint-dynamic-complete)
+;; (define-key shell-mode-map "\M-?"
+;; 'comint-dynamic-list-filename-completions)))
+;;
+;; Commands like this are fine things to put in load hooks if you
+;; want them present in specific modes.
(defvar comint-completion-autolist nil
"*If non-nil, automatically list possibilities on partial completion.
(set-window-configuration conf)
(setq unread-command-events (listify-key-sequence key)))))))
\f
-;;; Converting process modes to use comint mode
-;;; ===========================================================================
-;;; The code in the Emacs 19 distribution has all been modified to use comint
-;;; where needed. However, there are `third-party' packages out there that
-;;; still use the old shell mode. Here's a guide to conversion.
-;;;
-;;; Renaming variables
-;;; Most of the work is renaming variables and functions. These are the common
-;;; ones:
-;;; Local variables:
-;;; last-input-start comint-last-input-start
-;;; last-input-end comint-last-input-end
-;;; shell-prompt-pattern comint-prompt-regexp
-;;; shell-set-directory-error-hook <no equivalent>
-;;; Miscellaneous:
-;;; shell-set-directory <unnecessary>
-;;; shell-mode-map comint-mode-map
-;;; Commands:
-;;; shell-send-input comint-send-input
-;;; shell-send-eof comint-delchar-or-maybe-eof
-;;; kill-shell-input comint-kill-input
-;;; interrupt-shell-subjob comint-interrupt-subjob
-;;; stop-shell-subjob comint-stop-subjob
-;;; quit-shell-subjob comint-quit-subjob
-;;; kill-shell-subjob comint-kill-subjob
-;;; kill-output-from-shell comint-kill-output
-;;; show-output-from-shell comint-show-output
-;;; copy-last-shell-input Use comint-previous-input/comint-next-input
-;;;
-;;; SHELL-SET-DIRECTORY is gone, its functionality taken over by
-;;; SHELL-DIRECTORY-TRACKER, the shell mode's comint-input-filter-functions.
-;;; Comint mode does not provide functionality equivalent to
-;;; shell-set-directory-error-hook; it is gone.
-;;;
-;;; comint-last-input-start is provided for modes which want to munge
-;;; the buffer after input is sent, perhaps because the inferior
-;;; insists on echoing the input. The LAST-INPUT-START variable in
-;;; the old shell package was used to implement a history mechanism,
-;;; but you should think twice before using comint-last-input-start
-;;; for this; the input history ring often does the job better.
-;;;
-;;; If you are implementing some process-in-a-buffer mode, called foo-mode, do
-;;; *not* create the comint-mode local variables in your foo-mode function.
-;;; This is not modular. Instead, call comint-mode, and let *it* create the
-;;; necessary comint-specific local variables. Then create the
-;;; foo-mode-specific local variables in foo-mode. Set the buffer's keymap to
-;;; be foo-mode-map, and its mode to be foo-mode. Set the comint-mode hooks
-;;; (comint-{prompt-regexp, input-filter, input-filter-functions,
-;;; get-old-input) that need to be different from the defaults. Call
-;;; foo-mode-hook, and you're done. Don't run the comint-mode hook yourself;
-;;; comint-mode will take care of it. The following example, from shell.el,
-;;; is typical:
-;;;
-;;; (defvar shell-mode-map '())
-;;; (cond ((not shell-mode-map)
-;;; (setq shell-mode-map (copy-keymap comint-mode-map))
-;;; (define-key shell-mode-map "\C-c\C-f" 'shell-forward-command)
-;;; (define-key shell-mode-map "\C-c\C-b" 'shell-backward-command)
-;;; (define-key shell-mode-map "\t" 'comint-dynamic-complete)
-;;; (define-key shell-mode-map "\M-?"
-;;; 'comint-dynamic-list-filename-completions)))
-;;;
-;;; (defun shell-mode ()
-;;; (interactive)
-;;; (comint-mode)
-;;; (setq comint-prompt-regexp shell-prompt-pattern)
-;;; (setq major-mode 'shell-mode)
-;;; (setq mode-name "Shell")
-;;; (use-local-map shell-mode-map)
-;;; (make-local-variable 'shell-directory-stack)
-;;; (setq shell-directory-stack nil)
-;;; (add-hook 'comint-input-filter-functions 'shell-directory-tracker)
-;;; (run-hooks 'shell-mode-hook))
-;;;
-;;;
-;;; Note that make-comint is different from make-shell in that it
-;;; doesn't have a default program argument. If you give make-shell
-;;; a program name of NIL, it cleverly chooses one of explicit-shell-name,
-;;; $ESHELL, $SHELL, or /bin/sh. If you give make-comint a program argument
-;;; of NIL, it barfs. Adjust your code accordingly...
-;;;
-;;; Completion for comint-mode users
-;;;
-;;; For modes that use comint-mode, comint-dynamic-complete-functions is the
-;;; hook to add completion functions to. Functions on this list should return
-;;; non-nil if completion occurs (i.e., further completion should not occur).
-;;; You could use comint-dynamic-simple-complete to do the bulk of the
-;;; completion job.
+;; Converting process modes to use comint mode
+;; ===========================================================================
+;; The code in the Emacs 19 distribution has all been modified to use comint
+;; where needed. However, there are `third-party' packages out there that
+;; still use the old shell mode. Here's a guide to conversion.
+;;
+;; Renaming variables
+;; Most of the work is renaming variables and functions. These are the common
+;; ones:
+;; Local variables:
+;; last-input-start comint-last-input-start
+;; last-input-end comint-last-input-end
+;; shell-prompt-pattern comint-prompt-regexp
+;; shell-set-directory-error-hook <no equivalent>
+;; Miscellaneous:
+;; shell-set-directory <unnecessary>
+;; shell-mode-map comint-mode-map
+;; Commands:
+;; shell-send-input comint-send-input
+;; shell-send-eof comint-delchar-or-maybe-eof
+;; kill-shell-input comint-kill-input
+;; interrupt-shell-subjob comint-interrupt-subjob
+;; stop-shell-subjob comint-stop-subjob
+;; quit-shell-subjob comint-quit-subjob
+;; kill-shell-subjob comint-kill-subjob
+;; kill-output-from-shell comint-kill-output
+;; show-output-from-shell comint-show-output
+;; copy-last-shell-input Use comint-previous-input/comint-next-input
+;;
+;; SHELL-SET-DIRECTORY is gone, its functionality taken over by
+;; SHELL-DIRECTORY-TRACKER, the shell mode's comint-input-filter-functions.
+;; Comint mode does not provide functionality equivalent to
+;; shell-set-directory-error-hook; it is gone.
+;;
+;; comint-last-input-start is provided for modes which want to munge
+;; the buffer after input is sent, perhaps because the inferior
+;; insists on echoing the input. The LAST-INPUT-START variable in
+;; the old shell package was used to implement a history mechanism,
+;; but you should think twice before using comint-last-input-start
+;; for this; the input history ring often does the job better.
+;;
+;; If you are implementing some process-in-a-buffer mode, called foo-mode, do
+;; *not* create the comint-mode local variables in your foo-mode function.
+;; This is not modular. Instead, call comint-mode, and let *it* create the
+;; necessary comint-specific local variables. Then create the
+;; foo-mode-specific local variables in foo-mode. Set the buffer's keymap to
+;; be foo-mode-map, and its mode to be foo-mode. Set the comint-mode hooks
+;; (comint-{prompt-regexp, input-filter, input-filter-functions,
+;; get-old-input) that need to be different from the defaults. Call
+;; foo-mode-hook, and you're done. Don't run the comint-mode hook yourself;
+;; comint-mode will take care of it. The following example, from shell.el,
+;; is typical:
+;;
+;; (defvar shell-mode-map '())
+;; (cond ((not shell-mode-map)
+;; (setq shell-mode-map (copy-keymap comint-mode-map))
+;; (define-key shell-mode-map "\C-c\C-f" 'shell-forward-command)
+;; (define-key shell-mode-map "\C-c\C-b" 'shell-backward-command)
+;; (define-key shell-mode-map "\t" 'comint-dynamic-complete)
+;; (define-key shell-mode-map "\M-?"
+;; 'comint-dynamic-list-filename-completions)))
+;;
+;; (defun shell-mode ()
+;; (interactive)
+;; (comint-mode)
+;; (setq comint-prompt-regexp shell-prompt-pattern)
+;; (setq major-mode 'shell-mode)
+;; (setq mode-name "Shell")
+;; (use-local-map shell-mode-map)
+;; (make-local-variable 'shell-directory-stack)
+;; (setq shell-directory-stack nil)
+;; (add-hook 'comint-input-filter-functions 'shell-directory-tracker)
+;; (run-hooks 'shell-mode-hook))
+;;
+;;
+;; Note that make-comint is different from make-shell in that it
+;; doesn't have a default program argument. If you give make-shell
+;; a program name of NIL, it cleverly chooses one of explicit-shell-name,
+;; $ESHELL, $SHELL, or /bin/sh. If you give make-comint a program argument
+;; of NIL, it barfs. Adjust your code accordingly...
+;;
+;; Completion for comint-mode users
+;;
+;; For modes that use comint-mode, comint-dynamic-complete-functions is the
+;; hook to add completion functions to. Functions on this list should return
+;; non-nil if completion occurs (i.e., further completion should not occur).
+;; You could use comint-dynamic-simple-complete to do the bulk of the
+;; completion job.
\f
(provide 'comint)
-;;; comint.el ends here
+;; comint.el ends here
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; completion.el --- dynamic word-completion code
+
;; Copyright (C) 1990, 1993, 1995 Free Software Foundation, Inc.
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;;
-;;; What to put in .emacs
-;;;-----------------------
-;;; (load "completion")
-;;; (initialize-completions)
+
+;; What to put in .emacs
+;;-----------------------
+;; (load "completion")
+;; (initialize-completions)
\f
-;;;---------------------------------------------------------------------------
-;;; Documentation [Slightly out of date]
-;;;---------------------------------------------------------------------------
-;;; (also check the documentation string of the functions)
-;;;
-;;; Introduction
-;;;---------------
-;;;
-;;; After you type a few characters, pressing the "complete" key inserts
-;;; the rest of the word you are likely to type.
-;;;
-;;; This watches all the words that you type and remembers them. When
-;;; typing a new word, pressing "complete" (meta-return) "completes" the
-;;; word by inserting the most recently used word that begins with the
-;;; same characters. If you press meta-return repeatedly, it cycles
-;;; through all the words it knows about.
-;;;
-;;; If you like the completion then just continue typing, it is as if you
-;;; entered the text by hand. If you want the inserted extra characters
-;;; to go away, type control-w or delete. More options are described below.
-;;;
-;;; The guesses are made in the order of the most recently "used". Typing
-;;; in a word and then typing a separator character (such as a space) "uses"
-;;; the word. So does moving a cursor over the word. If no words are found,
-;;; it uses an extended version of the dabbrev style completion.
-;;;
-;;; You automatically save the completions you use to a file between
-;;; sessions.
-;;;
-;;; Completion enables programmers to enter longer, more descriptive
-;;; variable names while typing fewer keystrokes than they normally would.
-;;;
-;;;
-;;; Full documentation
-;;;---------------------
-;;;
-;;; A "word" is any string containing characters with either word or symbol
-;;; syntax. [E.G. Any alphanumeric string with hyphens, underscores, etc.]
-;;; Unless you change the constants, you must type at least three characters
-;;; for the word to be recognized. Only words longer than 6 characters are
-;;; saved.
-;;;
-;;; When you load this file, completion will be on. I suggest you use the
-;;; compiled version (because it is noticeably faster).
-;;;
-;;; M-X completion-mode toggles whether or not new words are added to the
-;;; database by changing the value of enable-completion.
-;;;
-;;; SAVING/LOADING COMPLETIONS
-;;; Completions are automatically saved from one session to another
-;;; (unless save-completions-flag or enable-completion is nil).
-;;; Loading this file (or calling initialize-completions) causes EMACS
-;;; to load a completions database for a saved completions file
-;;; (default: ~/.completions). When you exit, EMACS saves a copy of the
-;;; completions that you
-;;; often use. When you next start, EMACS loads in the saved completion file.
-;;;
-;;; The number of completions saved depends loosely on
-;;; *saved-completions-decay-factor*. Completions that have never been
-;;; inserted via "complete" are not saved. You are encouraged to experiment
-;;; with different functions (see compute-completion-min-num-uses).
-;;;
-;;; Some completions are permanent and are always saved out. These
-;;; completions have their num-uses slot set to T. Use
-;;; add-permanent-completion to do this
-;;;
-;;; Completions are saved only if enable-completion is T. The number of old
-;;; versions kept of the saved completions file is controlled by
-;;; completions-file-versions-kept.
-;;;
-;;; COMPLETE KEY OPTIONS
-;;; The complete function takes a numeric arguments.
-;;; control-u :: leave the point at the beginning of the completion rather
-;;; than the middle.
-;;; a number :: rotate through the possible completions by that amount
-;;; `-' :: same as -1 (insert previous completion)
-;;;
-;;; HOW THE DATABASE IS MAINTAINED
-;;; <write>
-;;;
-;;; UPDATING THE DATABASE MANUALLY
-;;; m-x kill-completion
-;;; kills the completion at point.
-;;; m-x add-completion
-;;; m-x add-permanent-completion
-;;;
-;;; UPDATING THE DATABASE FROM A SOURCE CODE FILE
-;;; m-x add-completions-from-buffer
-;;; Parses all the definition names from a C or LISP mode buffer and
-;;; adds them to the completion database.
-;;;
-;;; m-x add-completions-from-lisp-file
-;;; Parses all the definition names from a C or Lisp mode file and
-;;; adds them to the completion database.
-;;;
-;;; UPDATING THE DATABASE FROM A TAGS TABLE
-;;; m-x add-completions-from-tags-table
-;;; Adds completions from the current tags-table-buffer.
-;;;
-;;; HOW A COMPLETION IS FOUND
-;;; <write>
-;;;
-;;; STRING CASING
-;;; Completion is string case independent if case-fold-search has its
-;;; normal default of T. Also when the completion is inserted the case of the
-;;; entry is coerced appropriately.
-;;; [E.G. APP --> APPROPRIATELY app --> appropriately
-;;; App --> Appropriately]
-;;;
-;;; INITIALIZATION
-;;; The form `(initialize-completions)' initializes the completion system by
-;;; trying to load in the user's completions. After the first cal, further
-;;; calls have no effect so one should be careful not to put the form in a
-;;; site's standard site-init file.
-;;;
-;;;---------------------------------------------------------------------------
-;;;
-;;;
+;;---------------------------------------------------------------------------
+;; Documentation [Slightly out of date]
+;;---------------------------------------------------------------------------
+;; (also check the documentation string of the functions)
+;;
+;; Introduction
+;;---------------
+;;
+;; After you type a few characters, pressing the "complete" key inserts
+;; the rest of the word you are likely to type.
+;;
+;; This watches all the words that you type and remembers them. When
+;; typing a new word, pressing "complete" (meta-return) "completes" the
+;; word by inserting the most recently used word that begins with the
+;; same characters. If you press meta-return repeatedly, it cycles
+;; through all the words it knows about.
+;;
+;; If you like the completion then just continue typing, it is as if you
+;; entered the text by hand. If you want the inserted extra characters
+;; to go away, type control-w or delete. More options are described below.
+;;
+;; The guesses are made in the order of the most recently "used". Typing
+;; in a word and then typing a separator character (such as a space) "uses"
+;; the word. So does moving a cursor over the word. If no words are found,
+;; it uses an extended version of the dabbrev style completion.
+;;
+;; You automatically save the completions you use to a file between
+;; sessions.
+;;
+;; Completion enables programmers to enter longer, more descriptive
+;; variable names while typing fewer keystrokes than they normally would.
+;;
+;;
+;; Full documentation
+;;---------------------
+;;
+;; A "word" is any string containing characters with either word or symbol
+;; syntax. [E.G. Any alphanumeric string with hyphens, underscores, etc.]
+;; Unless you change the constants, you must type at least three characters
+;; for the word to be recognized. Only words longer than 6 characters are
+;; saved.
+;;
+;; When you load this file, completion will be on. I suggest you use the
+;; compiled version (because it is noticeably faster).
+;;
+;; M-X completion-mode toggles whether or not new words are added to the
+;; database by changing the value of enable-completion.
+;;
+;; SAVING/LOADING COMPLETIONS
+;; Completions are automatically saved from one session to another
+;; (unless save-completions-flag or enable-completion is nil).
+;; Loading this file (or calling initialize-completions) causes EMACS
+;; to load a completions database for a saved completions file
+;; (default: ~/.completions). When you exit, EMACS saves a copy of the
+;; completions that you
+;; often use. When you next start, EMACS loads in the saved completion file.
+;;
+;; The number of completions saved depends loosely on
+;; *saved-completions-decay-factor*. Completions that have never been
+;; inserted via "complete" are not saved. You are encouraged to experiment
+;; with different functions (see compute-completion-min-num-uses).
+;;
+;; Some completions are permanent and are always saved out. These
+;; completions have their num-uses slot set to T. Use
+;; add-permanent-completion to do this
+;;
+;; Completions are saved only if enable-completion is T. The number of old
+;; versions kept of the saved completions file is controlled by
+;; completions-file-versions-kept.
+;;
+;; COMPLETE KEY OPTIONS
+;; The complete function takes a numeric arguments.
+;; control-u :: leave the point at the beginning of the completion rather
+;; than the middle.
+;; a number :: rotate through the possible completions by that amount
+;; `-' :: same as -1 (insert previous completion)
+;;
+;; HOW THE DATABASE IS MAINTAINED
+;; <write>
+;;
+;; UPDATING THE DATABASE MANUALLY
+;; m-x kill-completion
+;; kills the completion at point.
+;; m-x add-completion
+;; m-x add-permanent-completion
+;;
+;; UPDATING THE DATABASE FROM A SOURCE CODE FILE
+;; m-x add-completions-from-buffer
+;; Parses all the definition names from a C or LISP mode buffer and
+;; adds them to the completion database.
+;;
+;; m-x add-completions-from-lisp-file
+;; Parses all the definition names from a C or Lisp mode file and
+;; adds them to the completion database.
+;;
+;; UPDATING THE DATABASE FROM A TAGS TABLE
+;; m-x add-completions-from-tags-table
+;; Adds completions from the current tags-table-buffer.
+;;
+;; HOW A COMPLETION IS FOUND
+;; <write>
+;;
+;; STRING CASING
+;; Completion is string case independent if case-fold-search has its
+;; normal default of T. Also when the completion is inserted the case of the
+;; entry is coerced appropriately.
+;; [E.G. APP --> APPROPRIATELY app --> appropriately
+;; App --> Appropriately]
+;;
+;; INITIALIZATION
+;; The form `(initialize-completions)' initializes the completion system by
+;; trying to load in the user's completions. After the first cal, further
+;; calls have no effect so one should be careful not to put the form in a
+;; site's standard site-init file.
+;;
+;;---------------------------------------------------------------------------
+;;
+;;
\f
-;;;---------------------------------------------------------------------------
-;;; Functions you might like to call
-;;;---------------------------------------------------------------------------
-;;;
-;;; add-completion string &optional num-uses
-;;; Adds a new string to the database
-;;;
-;;; add-permanent-completion string
-;;; Adds a new string to the database with num-uses = T
-;;;
-
-;;; kill-completion string
-;;; Kills the completion from the database.
-;;;
-;;; clear-all-completions
-;;; Clears the database
-;;;
-;;; list-all-completions
-;;; Returns a list of all completions.
-;;;
-;;;
-;;; next-completion string &optional index
-;;; Returns a completion entry that starts with string.
-;;;
-;;; find-exact-completion string
-;;; Returns a completion entry that exactly matches string.
-;;;
-;;; complete
-;;; Inserts a completion at point
-;;;
-;;; initialize-completions
-;;; Loads the completions file and sets up so that exiting emacs will
-;;; save them.
-;;;
-;;; save-completions-to-file &optional filename
-;;; load-completions-from-file &optional filename
-;;;
-;;;-----------------------------------------------
-;;; Other functions
-;;;-----------------------------------------------
-;;;
-;;; get-completion-list string
-;;;
-;;; These things are for manipulating the structure
-;;; make-completion string num-uses
-;;; completion-num-uses completion
-;;; completion-string completion
-;;; set-completion-num-uses completion num-uses
-;;; set-completion-string completion string
-;;;
-;;;
+;;---------------------------------------------------------------------------
+;; Functions you might like to call
+;;---------------------------------------------------------------------------
+;;
+;; add-completion string &optional num-uses
+;; Adds a new string to the database
+;;
+;; add-permanent-completion string
+;; Adds a new string to the database with num-uses = T
+;;
+
+;; kill-completion string
+;; Kills the completion from the database.
+;;
+;; clear-all-completions
+;; Clears the database
+;;
+;; list-all-completions
+;; Returns a list of all completions.
+;;
+;;
+;; next-completion string &optional index
+;; Returns a completion entry that starts with string.
+;;
+;; find-exact-completion string
+;; Returns a completion entry that exactly matches string.
+;;
+;; complete
+;; Inserts a completion at point
+;;
+;; initialize-completions
+;; Loads the completions file and sets up so that exiting emacs will
+;; save them.
+;;
+;; save-completions-to-file &optional filename
+;; load-completions-from-file &optional filename
+;;
+;;-----------------------------------------------
+;; Other functions
+;;-----------------------------------------------
+;;
+;; get-completion-list string
+;;
+;; These things are for manipulating the structure
+;; make-completion string num-uses
+;; completion-num-uses completion
+;; completion-string completion
+;; set-completion-num-uses completion num-uses
+;; set-completion-string completion string
+;;
+;;
\f
-;;;-----------------------------------------------
-;;; To Do :: (anybody ?)
-;;;-----------------------------------------------
-;;;
-;;; Implement Lookup and keyboard interface in C
-;;; Add package prefix smarts (for Common Lisp)
-;;; Add autoprompting of possible completions after every keystroke (fast
-;;; terminals only !)
-;;; Add doc. to texinfo
-;;;
-;;;
-;;;-----------------------------------------------
-;;; Change Log:
-;;;-----------------------------------------------
-;;; Sometime in '84 Brewster implemented a somewhat buggy version for
-;;; Symbolics LISPMs.
-;;; Jan. '85 Jim became enamored of the idea and implemented a faster,
-;;; more robust version.
-;;; With input from many users at TMC, (rose, craig, and gls come to mind),
-;;; the current style of interface was developed.
-;;; 9/87, Jim and Brewster took terminals home. Yuck. After
-;;; complaining for a while Brewster implemented a subset of the current
-;;; LISPM version for GNU Emacs.
-;;; 8/88 After complaining for a while (and with sufficient
-;;; promised rewards), Jim reimplemented a version of GNU completion
-;;; superior to that of the LISPM version.
-;;;
-;;;-----------------------------------------------
-;;; Acknowledgements
-;;;-----------------------------------------------
-;;; Cliff Lasser (cal@think.com), Kevin Herbert (kph@cisco.com),
-;;; eero@media-lab, kgk@cs.brown.edu, jla@ai.mit.edu,
-;;;
-;;;-----------------------------------------------
-;;; Change Log
-;;;-----------------------------------------------
-;;; From version 9 to 10
-;;; - Allowance for non-integral *completion-version* nos.
-;;; - Fix cmpl-apply-as-top-level for keyboard macros
-;;; - Fix broken completion merging (in save-completions-to-file)
-;;; - More misc. fixes for version 19.0 of emacs
-;;;
-;;; From Version 8 to 9
-;;; - Ported to version 19.0 of emacs (backcompatible with version 18)
-;;; - Added add-completions-from-tags-table (with thanks to eero@media-lab)
-;;;
-;;; From Version 7 to 8
-;;; - Misc. changes to comments
-;;; - new completion key bindings: c-x o, M->, M-<, c-a, c-e
-;;; - cdabbrev now checks all the visible window buffers and the "other buffer"
-;;; - `%' is now a symbol character rather than a separator (except in C mode)
-;;;
-;;; From Version 6 to 7
-;;; - Fixed bug with saving out .completion file the first time
-;;;
-;;; From Version 5 to 6
-;;; - removed statistics recording
-;;; - reworked advise to handle autoloads
-;;; - Fixed fortran mode support
-;;; - Added new cursor motion triggers
-;;;
-;;; From Version 4 to 5
-;;; - doesn't bother saving if nothing has changed
-;;; - auto-save if haven't used for a 1/2 hour
-;;; - save period extended to two weeks
-;;; - minor fix to capitalization code
-;;; - added *completion-auto-save-period* to variables recorded.
-;;; - added reenter protection to cmpl-record-statistics-filter
-;;; - added backup protection to save-completions-to-file (prevents
-;;; problems with disk full errors)
+;;-----------------------------------------------
+;; To Do :: (anybody ?)
+;;-----------------------------------------------
+;;
+;; Implement Lookup and keyboard interface in C
+;; Add package prefix smarts (for Common Lisp)
+;; Add autoprompting of possible completions after every keystroke (fast
+;; terminals only !)
+;; Add doc. to texinfo
+;;
+;;
+;;-----------------------------------------------
+;; Change Log:
+;;-----------------------------------------------
+;; Sometime in '84 Brewster implemented a somewhat buggy version for
+;; Symbolics LISPMs.
+;; Jan. '85 Jim became enamored of the idea and implemented a faster,
+;; more robust version.
+;; With input from many users at TMC, (rose, craig, and gls come to mind),
+;; the current style of interface was developed.
+;; 9/87, Jim and Brewster took terminals home. Yuck. After
+;; complaining for a while Brewster implemented a subset of the current
+;; LISPM version for GNU Emacs.
+;; 8/88 After complaining for a while (and with sufficient
+;; promised rewards), Jim reimplemented a version of GNU completion
+;; superior to that of the LISPM version.
+;;
+;;-----------------------------------------------
+;; Acknowledgements
+;;-----------------------------------------------
+;; Cliff Lasser (cal@think.com), Kevin Herbert (kph@cisco.com),
+;; eero@media-lab, kgk@cs.brown.edu, jla@ai.mit.edu,
+;;
+;;-----------------------------------------------
+;; Change Log
+;;-----------------------------------------------
+;; From version 9 to 10
+;; - Allowance for non-integral *completion-version* nos.
+;; - Fix cmpl-apply-as-top-level for keyboard macros
+;; - Fix broken completion merging (in save-completions-to-file)
+;; - More misc. fixes for version 19.0 of emacs
+;;
+;; From Version 8 to 9
+;; - Ported to version 19.0 of emacs (backcompatible with version 18)
+;; - Added add-completions-from-tags-table (with thanks to eero@media-lab)
+;;
+;; From Version 7 to 8
+;; - Misc. changes to comments
+;; - new completion key bindings: c-x o, M->, M-<, c-a, c-e
+;; - cdabbrev now checks all the visible window buffers and the "other buffer"
+;; - `%' is now a symbol character rather than a separator (except in C mode)
+;;
+;; From Version 6 to 7
+;; - Fixed bug with saving out .completion file the first time
+;;
+;; From Version 5 to 6
+;; - removed statistics recording
+;; - reworked advise to handle autoloads
+;; - Fixed fortran mode support
+;; - Added new cursor motion triggers
+;;
+;; From Version 4 to 5
+;; - doesn't bother saving if nothing has changed
+;; - auto-save if haven't used for a 1/2 hour
+;; - save period extended to two weeks
+;; - minor fix to capitalization code
+;; - added *completion-auto-save-period* to variables recorded.
+;; - added reenter protection to cmpl-record-statistics-filter
+;; - added backup protection to save-completions-to-file (prevents
+;; problems with disk full errors)
\f
;;; Code:
-;;;---------------------------------------------------------------------------
-;;; User changeable parameters
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; User changeable parameters
+;;---------------------------------------------------------------------------
(defvar enable-completion t
"*Non-nil means enable recording and saving of completions.
Definitions from visited files which have these modes
are automatically added to the completion database.")
-;;;(defvar *record-cmpl-statistics-p* nil
-;;; "*If non-nil, record completion statistics.")
+;;(defvar *record-cmpl-statistics-p* nil
+;; "*If non-nil, record completion statistics.")
-;;;(defvar *completion-auto-save-period* 1800
-;;; "*The period in seconds to wait for emacs to be idle before autosaving
-;;;the completions. Default is a 1/2 hour.")
+;;(defvar *completion-auto-save-period* 1800
+;; "*The period in seconds to wait for emacs to be idle before autosaving
+;;the completions. Default is a 1/2 hour.")
(defconst completion-min-length nil ;; defined below in eval-when
"*The minimum length of a stored completion.
(completion-eval-when)
-;;;---------------------------------------------------------------------------
-;;; Internal Variables
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; Internal Variables
+;;---------------------------------------------------------------------------
(defvar cmpl-initialized-p nil
"Set to t when the completion system is initialized.
(defvar completion-string)
\f
-;;;---------------------------------------------------------------------------
-;;; Low level tools
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; Low level tools
+;;---------------------------------------------------------------------------
-;;;-----------------------------------------------
-;;; Misc.
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Misc.
+;;-----------------------------------------------
(defun minibuffer-window-selected-p ()
"True iff the current window is the minibuffer."
(defmacro cmpl-read-time-eval (form)
form)
-;;;-----------------------------------------------
-;;; String case coercion
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; String case coercion
+;;-----------------------------------------------
(defun cmpl-string-case-type (string)
"Returns :capitalized, :up, :down, :mixed, or :neither."
(t ':neither))))
))
-;;; Tests -
-;;; (cmpl-string-case-type "123ABCDEF456") --> :up
-;;; (cmpl-string-case-type "123abcdef456") --> :down
-;;; (cmpl-string-case-type "123aBcDeF456") --> :mixed
-;;; (cmpl-string-case-type "123456") --> :neither
-;;; (cmpl-string-case-type "Abcde123") --> :capitalized
+;; Tests -
+;; (cmpl-string-case-type "123ABCDEF456") --> :up
+;; (cmpl-string-case-type "123abcdef456") --> :down
+;; (cmpl-string-case-type "123aBcDeF456") --> :mixed
+;; (cmpl-string-case-type "123456") --> :neither
+;; (cmpl-string-case-type "Abcde123") --> :capitalized
(defun cmpl-coerce-string-case (string case-type)
(cond ((eq case-type ':down) (downcase string))
string-to-coerce)
)))
-;;; Tests -
-;;; (cmpl-merge-string-cases "AbCdEf456" "abc") --> AbCdEf456
-;;; (cmpl-merge-string-cases "abcdef456" "ABC") --> ABCDEF456
-;;; (cmpl-merge-string-cases "ABCDEF456" "Abc") --> Abcdef456
-;;; (cmpl-merge-string-cases "ABCDEF456" "abc") --> abcdef456
+;; Tests -
+;; (cmpl-merge-string-cases "AbCdEf456" "abc") --> AbCdEf456
+;; (cmpl-merge-string-cases "abcdef456" "ABC") --> ABCDEF456
+;; (cmpl-merge-string-cases "ABCDEF456" "Abc") --> Abcdef456
+;; (cmpl-merge-string-cases "ABCDEF456" "abc") --> abcdef456
\f
(defun cmpl-hours-since-origin ()
(+ (* (/ (car time) 3600.0) (lsh 1 16))
(/ (nth 2 time) 3600.0)))))
\f
-;;;---------------------------------------------------------------------------
-;;; "Symbol" parsing functions
-;;;---------------------------------------------------------------------------
-;;; The functions symbol-before-point, symbol-under-point, etc. quickly return
-;;; an appropriate symbol string. The strategy is to temporarily change
-;;; the syntax table to enable fast symbol searching. There are three classes
-;;; of syntax in these "symbol" syntax tables ::
-;;;
-;;; syntax (?_) - "symbol" chars (e.g. alphanumerics)
-;;; syntax (?w) - symbol chars to ignore at end of words (e.g. period).
-;;; syntax (? ) - everything else
-;;;
-;;; Thus by judicious use of scan-sexps and forward-word, we can get
-;;; the word we want relatively fast and without consing.
-;;;
-;;; Why do we need a separate category for "symbol chars to ignore at ends" ?
-;;; For example, in LISP we want starting :'s trimmed
-;;; so keyword argument specifiers also define the keyword completion. And,
-;;; for example, in C we want `.' appearing in a structure ref. to
-;;; be kept intact in order to store the whole structure ref.; however, if
-;;; it appears at the end of a symbol it should be discarded because it is
-;;; probably used as a period.
-
-;;; Here is the default completion syntax ::
-;;; Symbol chars :: A-Z a-z 0-9 @ / \ * + ~ $ < > %
-;;; Symbol chars to ignore at ends :: _ : . -
-;;; Separator chars. :: <tab> <space> ! ^ & ( ) = ` | { } [ ] ; " ' #
-;;; , ? <Everything else>
-
-;;; Mode specific differences and notes ::
-;;; LISP diffs ->
-;;; Symbol chars :: ! & ? = ^
-;;;
-;;; C diffs ->
-;;; Separator chars :: + * / : %
-;;; A note on the hyphen (`-'). Perhaps the hyphen should also be a separator
-;;; char., however, we wanted to have completion symbols include pointer
-;;; references. For example, "foo->bar" is a symbol as far as completion is
-;;; concerned.
-;;;
-;;; FORTRAN diffs ->
-;;; Separator chars :: + - * / :
-;;;
-;;; Pathname diffs ->
-;;; Symbol chars :: .
-;;; Of course there is no pathname "mode" and in fact we have not implemented
-;;; this table. However, if there was such a mode, this is what it would look
-;;; like.
-
-;;;-----------------------------------------------
-;;; Table definitions
-;;;-----------------------------------------------
+;;---------------------------------------------------------------------------
+;; "Symbol" parsing functions
+;;---------------------------------------------------------------------------
+;; The functions symbol-before-point, symbol-under-point, etc. quickly return
+;; an appropriate symbol string. The strategy is to temporarily change
+;; the syntax table to enable fast symbol searching. There are three classes
+;; of syntax in these "symbol" syntax tables ::
+;;
+;; syntax (?_) - "symbol" chars (e.g. alphanumerics)
+;; syntax (?w) - symbol chars to ignore at end of words (e.g. period).
+;; syntax (? ) - everything else
+;;
+;; Thus by judicious use of scan-sexps and forward-word, we can get
+;; the word we want relatively fast and without consing.
+;;
+;; Why do we need a separate category for "symbol chars to ignore at ends" ?
+;; For example, in LISP we want starting :'s trimmed
+;; so keyword argument specifiers also define the keyword completion. And,
+;; for example, in C we want `.' appearing in a structure ref. to
+;; be kept intact in order to store the whole structure ref.; however, if
+;; it appears at the end of a symbol it should be discarded because it is
+;; probably used as a period.
+
+;; Here is the default completion syntax ::
+;; Symbol chars :: A-Z a-z 0-9 @ / \ * + ~ $ < > %
+;; Symbol chars to ignore at ends :: _ : . -
+;; Separator chars. :: <tab> <space> ! ^ & ( ) = ` | { } [ ] ; " ' #
+;; , ? <Everything else>
+
+;; Mode specific differences and notes ::
+;; LISP diffs ->
+;; Symbol chars :: ! & ? = ^
+;;
+;; C diffs ->
+;; Separator chars :: + * / : %
+;; A note on the hyphen (`-'). Perhaps the hyphen should also be a separator
+;; char., however, we wanted to have completion symbols include pointer
+;; references. For example, "foo->bar" is a symbol as far as completion is
+;; concerned.
+;;
+;; FORTRAN diffs ->
+;; Separator chars :: + - * / :
+;;
+;; Pathname diffs ->
+;; Symbol chars :: .
+;; Of course there is no pathname "mode" and in fact we have not implemented
+;; this table. However, if there was such a mode, this is what it would look
+;; like.
+
+;;-----------------------------------------------
+;; Table definitions
+;;-----------------------------------------------
(defun cmpl-make-standard-completion-syntax-table ()
(let ((table (make-syntax-table)) ;; default syntax is whitespace
"This variable holds the current completion syntax table.")
(make-variable-buffer-local 'cmpl-syntax-table)
-;;;-----------------------------------------------
-;;; Installing the appropriate mode tables
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Installing the appropriate mode tables
+;;-----------------------------------------------
(add-hook 'lisp-mode-hook
'(lambda ()
(setq cmpl-syntax-table cmpl-fortran-syntax-table)
(completion-setup-fortran-mode)))
-;;;-----------------------------------------------
-;;; Symbol functions
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Symbol functions
+;;-----------------------------------------------
(defvar cmpl-symbol-start nil
"Holds first character of symbol, after any completion symbol function.")
(defvar cmpl-symbol-end nil
"Holds last character of symbol, after any completion symbol function.")
-;;; These are temp. vars. we use to avoid using let.
-;;; Why ? Small speed improvement.
+;; These are temp. vars. we use to avoid using let.
+;; Why ? Small speed improvement.
(defvar cmpl-saved-syntax nil)
(defvar cmpl-saved-point nil)
(buffer-substring cmpl-symbol-start cmpl-symbol-end)))))
(set-syntax-table cmpl-saved-syntax)))
-;;; tests for symbol-under-point
-;;; `^' indicates cursor pos. where value is returned
-;;; simple-word-test
-;;; ^^^^^^^^^^^^^^^^ --> simple-word-test
-;;; _harder_word_test_
-;;; ^^^^^^^^^^^^^^^^^^ --> harder_word_test
-;;; .___.______.
-;;; --> nil
-;;; /foo/bar/quux.hello
-;;; ^^^^^^^^^^^^^^^^^^^ --> /foo/bar/quux.hello
-;;;
+;; tests for symbol-under-point
+;; `^' indicates cursor pos. where value is returned
+;; simple-word-test
+;; ^^^^^^^^^^^^^^^^ --> simple-word-test
+;; _harder_word_test_
+;; ^^^^^^^^^^^^^^^^^^ --> harder_word_test
+;; .___.______.
+;; --> nil
+;; /foo/bar/quux.hello
+;; ^^^^^^^^^^^^^^^^^^^ --> /foo/bar/quux.hello
+;;
(defun symbol-before-point ()
"Returns a string of the symbol immediately before point.
(buffer-substring cmpl-symbol-start cmpl-symbol-end)))))
(set-syntax-table cmpl-saved-syntax)))
-;;; tests for symbol-before-point
-;;; `^' indicates cursor pos. where value is returned
-;;; simple-word-test
-;;; ^ --> nil
-;;; ^ --> nil
-;;; ^ --> simple-w
-;;; ^ --> simple-word-test
-;;; _harder_word_test_
-;;; ^ --> harder_word_test
-;;; ^ --> harder_word_test
-;;; ^ --> harder
-;;; .___....
-;;; --> nil
+;; tests for symbol-before-point
+;; `^' indicates cursor pos. where value is returned
+;; simple-word-test
+;; ^ --> nil
+;; ^ --> nil
+;; ^ --> simple-w
+;; ^ --> simple-word-test
+;; _harder_word_test_
+;; ^ --> harder_word_test
+;; ^ --> harder_word_test
+;; ^ --> harder
+;; .___....
+;; --> nil
(defun symbol-under-or-before-point ()
- ;;; This could be made slightly faster but it is better to avoid
- ;;; copying all the code.
- ;;; However, it is only used by the completion string prompter.
- ;;; If it comes into common use, it could be rewritten.
+ ;; This could be made slightly faster but it is better to avoid
+ ;; copying all the code.
+ ;; However, it is only used by the completion string prompter.
+ ;; If it comes into common use, it could be rewritten.
(cond ((memq (progn
(setq cmpl-saved-syntax (syntax-table))
(unwind-protect
;; Restore syntax table.
(set-syntax-table cmpl-saved-syntax)))
-;;; tests for symbol-before-point-for-complete
-;;; `^' indicates cursor pos. where value is returned
-;;; simple-word-test
-;;; ^ --> nil
-;;; ^ --> nil
-;;; ^ --> simple-w
-;;; ^ --> simple-word-test
-;;; _harder_word_test_
-;;; ^ --> harder_word_test
-;;; ^ --> harder_word_test_
-;;; ^ --> harder_
-;;; .___....
-;;; --> nil
+;; tests for symbol-before-point-for-complete
+;; `^' indicates cursor pos. where value is returned
+;; simple-word-test
+;; ^ --> nil
+;; ^ --> nil
+;; ^ --> simple-w
+;; ^ --> simple-word-test
+;; _harder_word_test_
+;; ^ --> harder_word_test
+;; ^ --> harder_word_test_
+;; ^ --> harder_
+;; .___....
+;; --> nil
\f
-;;;---------------------------------------------------------------------------
-;;; Statistics Recording
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; Statistics Recording
+;;---------------------------------------------------------------------------
-;;; Note that the guts of this has been turned off. The guts
-;;; are in completion-stats.el.
+;; Note that the guts of this has been turned off. The guts
+;; are in completion-stats.el.
-;;;-----------------------------------------------
-;;; Conditionalizing code on *record-cmpl-statistics-p*
-;;;-----------------------------------------------
-;;; All statistics code outside this block should use this
+;;-----------------------------------------------
+;; Conditionalizing code on *record-cmpl-statistics-p*
+;;-----------------------------------------------
+;; All statistics code outside this block should use this
(defmacro cmpl-statistics-block (&rest body))
-;;; "Only executes body if we are recording statistics."
-;;; (list 'cond
-;;; (list* '*record-cmpl-statistics-p* body)
-;;; ))
+;; "Only executes body if we are recording statistics."
+;; (list 'cond
+;; (list* '*record-cmpl-statistics-p* body)
+;; ))
-;;;-----------------------------------------------
-;;; Completion Sources
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Completion Sources
+;;-----------------------------------------------
;; ID numbers
(defconst cmpl-source-unknown 0)
\f
-;;;---------------------------------------------------------------------------
-;;; Completion Method #2: dabbrev-expand style
-;;;---------------------------------------------------------------------------
-;;;
-;;; This method is used if there are no useful stored completions. It is
-;;; based on dabbrev-expand with these differences :
-;;; 1) Faster (we don't use regexps)
-;;; 2) case coercion handled correctly
-;;; This is called cdabbrev to differentiate it.
-;;; We simply search backwards through the file looking for words which
-;;; start with the same letters we are trying to complete.
-;;;
+;;---------------------------------------------------------------------------
+;; Completion Method #2: dabbrev-expand style
+;;---------------------------------------------------------------------------
+;;
+;; This method is used if there are no useful stored completions. It is
+;; based on dabbrev-expand with these differences :
+;; 1) Faster (we don't use regexps)
+;; 2) case coercion handled correctly
+;; This is called cdabbrev to differentiate it.
+;; We simply search backwards through the file looking for words which
+;; start with the same letters we are trying to complete.
+;;
(defvar cdabbrev-completions-tried nil)
-;;; "A list of all the cdabbrev completions since the last reset.")
+;; "A list of all the cdabbrev completions since the last reset.")
(defvar cdabbrev-current-point 0)
-;;; "The current point position the cdabbrev search is at.")
+;; "The current point position the cdabbrev search is at.")
(defvar cdabbrev-current-window nil)
-;;; "The current window we are looking for cdabbrevs in. T if looking in
-;;; (other-buffer), NIL if no more cdabbrevs.")
+;; "The current window we are looking for cdabbrevs in. T if looking in
+;; (other-buffer), NIL if no more cdabbrevs.")
(defvar cdabbrev-wrapped-p nil)
-;;; "T if the cdabbrev search has wrapped around the file.")
+;; "T if the cdabbrev search has wrapped around the file.")
(defvar cdabbrev-abbrev-string "")
(defvar cdabbrev-start-point 0)
(defvar cdabbrev-stop-point)
-;;; Test strings for cdabbrev
-;;; cdat-upcase ;;same namestring
-;;; CDAT-UPCASE ;;ok
-;;; cdat2 ;;too short
-;;; cdat-1-2-3-4 ;;ok
-;;; a-cdat-1 ;;doesn't start correctly
-;;; cdat-simple ;;ok
+;; Test strings for cdabbrev
+;; cdat-upcase ;;same namestring
+;; CDAT-UPCASE ;;ok
+;; cdat2 ;;too short
+;; cdat-1-2-3-4 ;;ok
+;; a-cdat-1 ;;doesn't start correctly
+;; cdat-simple ;;ok
(defun reset-cdabbrev (abbrev-string &optional initial-completions-tried)
(t (reset-cdabbrev-window)
(next-cdabbrev))))))
-;;; The following must be eval'd in the minibuffer ::
-;;; (reset-cdabbrev "cdat")
-;;; (next-cdabbrev) --> "cdat-simple"
-;;; (next-cdabbrev) --> "cdat-1-2-3-4"
-;;; (next-cdabbrev) --> "CDAT-UPCASE"
-;;; (next-cdabbrev) --> "cdat-wrapping"
-;;; (next-cdabbrev) --> "cdat_start_sym"
-;;; (next-cdabbrev) --> nil
-;;; (next-cdabbrev) --> nil
-;;; (next-cdabbrev) --> nil
+;; The following must be eval'd in the minibuffer ::
+;; (reset-cdabbrev "cdat")
+;; (next-cdabbrev) --> "cdat-simple"
+;; (next-cdabbrev) --> "cdat-1-2-3-4"
+;; (next-cdabbrev) --> "CDAT-UPCASE"
+;; (next-cdabbrev) --> "cdat-wrapping"
+;; (next-cdabbrev) --> "cdat_start_sym"
+;; (next-cdabbrev) --> nil
+;; (next-cdabbrev) --> nil
+;; (next-cdabbrev) --> nil
-;;; _cdat_start_sym
-;;; cdat-wrapping
+;; _cdat_start_sym
+;; cdat-wrapping
\f
-;;;---------------------------------------------------------------------------
-;;; Completion Database
-;;;---------------------------------------------------------------------------
-
-;;; We use two storage modes for the two search types ::
-;;; 1) Prefix {cmpl-prefix-obarray} for looking up possible completions
-;;; Used by search-completion-next
-;;; the value of the symbol is nil or a cons of head and tail pointers
-;;; 2) Interning {cmpl-obarray} to see if it's in the database
-;;; Used by find-exact-completion, completion-in-database-p
-;;; The value of the symbol is the completion entry
-
-;;; bad things may happen if this length is changed due to the way
-;;; GNU implements obarrays
+;;---------------------------------------------------------------------------
+;; Completion Database
+;;---------------------------------------------------------------------------
+
+;; We use two storage modes for the two search types ::
+;; 1) Prefix {cmpl-prefix-obarray} for looking up possible completions
+;; Used by search-completion-next
+;; the value of the symbol is nil or a cons of head and tail pointers
+;; 2) Interning {cmpl-obarray} to see if it's in the database
+;; Used by find-exact-completion, completion-in-database-p
+;; The value of the symbol is the completion entry
+
+;; bad things may happen if this length is changed due to the way
+;; GNU implements obarrays
(defconst cmpl-obarray-length 511)
(defvar cmpl-prefix-obarray (make-vector cmpl-obarray-length 0)
"An obarray used to store the downcased completions.
Each symbol is bound to a single completion entry.")
-;;;-----------------------------------------------
-;;; Completion Entry Structure Definition
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Completion Entry Structure Definition
+;;-----------------------------------------------
-;;; A completion entry is a LIST of string, prefix-symbol num-uses, and
-;;; last-use-time (the time the completion was last used)
-;;; last-use-time is T if the string should be kept permanently
-;;; num-uses is incremented every time the completion is used.
+;; A completion entry is a LIST of string, prefix-symbol num-uses, and
+;; last-use-time (the time the completion was last used)
+;; last-use-time is T if the string should be kept permanently
+;; num-uses is incremented every time the completion is used.
-;;; We chose lists because (car foo) is faster than (aref foo 0) and the
-;;; creation time is about the same.
+;; We chose lists because (car foo) is faster than (aref foo 0) and the
+;; creation time is about the same.
-;;; READER MACROS
+;; READER MACROS
(defmacro completion-string (completion-entry)
(list 'car completion-entry))
(defmacro completion-source (completion-entry)
(list 'nth 3 completion-entry))
-;;; WRITER MACROS
+;; WRITER MACROS
(defmacro set-completion-string (completion-entry string)
(list 'setcar completion-entry string))
(defmacro set-completion-last-use-time (completion-entry last-use-time)
(list 'setcar (list 'cdr (list 'cdr completion-entry)) last-use-time))
-;;; CONSTRUCTOR
+;; CONSTRUCTOR
(defun make-completion (string)
"Returns a list of a completion entry."
(list (list string 0 nil current-completion-source)))
\f
-;;;-----------------------------------------------
-;;; Prefix symbol entry definition
-;;;-----------------------------------------------
-;;; A cons of (head . tail)
+;;-----------------------------------------------
+;; Prefix symbol entry definition
+;;-----------------------------------------------
+;; A cons of (head . tail)
-;;; READER Macros
+;; READER Macros
(defmacro cmpl-prefix-entry-head (prefix-entry)
(list 'car prefix-entry))
(defmacro cmpl-prefix-entry-tail (prefix-entry)
(list 'cdr prefix-entry))
-;;; WRITER Macros
+;; WRITER Macros
(defmacro set-cmpl-prefix-entry-head (prefix-entry new-head)
(list 'setcar prefix-entry new-head))
(defmacro set-cmpl-prefix-entry-tail (prefix-entry new-tail)
(list 'setcdr prefix-entry new-tail))
-;;; Constructor
+;; Constructor
(defun make-cmpl-prefix-entry (completion-entry-list)
"Makes a new prefix entry containing only completion-entry."
(cons completion-entry-list completion-entry-list))
-;;;-----------------------------------------------
-;;; Completion Database - Utilities
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Completion Database - Utilities
+;;-----------------------------------------------
(defun clear-all-completions ()
"Initializes the completion storage. All existing completions are lost."
completions-list-return-value))))
\f
-;;;-----------------------------------------------
-;;; Updating the database
-;;;-----------------------------------------------
-;;;
-;;; These are the internal functions used to update the datebase
-;;;
-;;;
+;;-----------------------------------------------
+;; Updating the database
+;;-----------------------------------------------
+;;
+;; These are the internal functions used to update the datebase
+;;
+;;
(defvar completion-to-accept nil)
;;"Set to a string that is pending its acceptance."
;; this checked by the top level reading functions
(defvar cmpl-db-debug-p nil
"Set to T if you want to debug the database.")
-;;; READS
+;; READS
(defun find-exact-completion (string)
"Returns the completion entry for string or nil.
Sets up `cmpl-db-downcase-string' and `cmpl-db-symbol'."
(error "Completion database corrupted. Try M-x clear-all-completions. Send bug report.")
)
-;;; WRITES
+;; WRITES
(defun add-completion-to-tail-if-new (string)
"If STRING is not in the database add it to appropriate prefix list.
STRING is added to the end of the appropriate prefix list with
(error "Unknown completion `%s'" completion-string)
))
-;;; Tests --
-;;; - Add and Find -
-;;; (add-completion-to-head "banana") --> ("banana" 0 nil 0)
-;;; (find-exact-completion "banana") --> ("banana" 0 nil 0)
-;;; (find-exact-completion "bana") --> nil
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
-;;; (add-completion-to-head "banish") --> ("banish" 0 nil 0)
-;;; (find-exact-completion "banish") --> ("banish" 0 nil 0)
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banish" ...) ("banana" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
-;;; (add-completion-to-head "banana") --> ("banana" 0 nil 0)
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...) ("banish" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banish" ...))
-;;;
-;;; - Deleting -
-;;; (add-completion-to-head "banner") --> ("banner" 0 nil 0)
-;;; (delete-completion "banner")
-;;; (find-exact-completion "banner") --> nil
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...) ("banish" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banish" ...))
-;;; (add-completion-to-head "banner") --> ("banner" 0 nil 0)
-;;; (delete-completion "banana")
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banner" ...) ("banish" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banish" ...))
-;;; (delete-completion "banner")
-;;; (delete-completion "banish")
-;;; (find-cmpl-prefix-entry "ban") --> nil
-;;; (delete-completion "banner") --> error
-;;;
-;;; - Tail -
-;;; (add-completion-to-tail-if-new "banana") --> ("banana" 0 nil 0)
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
-;;; (add-completion-to-tail-if-new "banish") --> ("banish" 0 nil 0)
-;;; (car (find-cmpl-prefix-entry "ban")) -->(("banana" ...) ("banish" ...))
-;;; (cdr (find-cmpl-prefix-entry "ban")) -->(("banish" ...))
-;;;
+;; Tests --
+;; - Add and Find -
+;; (add-completion-to-head "banana") --> ("banana" 0 nil 0)
+;; (find-exact-completion "banana") --> ("banana" 0 nil 0)
+;; (find-exact-completion "bana") --> nil
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
+;; (add-completion-to-head "banish") --> ("banish" 0 nil 0)
+;; (find-exact-completion "banish") --> ("banish" 0 nil 0)
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banish" ...) ("banana" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
+;; (add-completion-to-head "banana") --> ("banana" 0 nil 0)
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...) ("banish" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banish" ...))
+;;
+;; - Deleting -
+;; (add-completion-to-head "banner") --> ("banner" 0 nil 0)
+;; (delete-completion "banner")
+;; (find-exact-completion "banner") --> nil
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...) ("banish" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banish" ...))
+;; (add-completion-to-head "banner") --> ("banner" 0 nil 0)
+;; (delete-completion "banana")
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banner" ...) ("banish" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banish" ...))
+;; (delete-completion "banner")
+;; (delete-completion "banish")
+;; (find-cmpl-prefix-entry "ban") --> nil
+;; (delete-completion "banner") --> error
+;;
+;; - Tail -
+;; (add-completion-to-tail-if-new "banana") --> ("banana" 0 nil 0)
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) --> (("banana" ...))
+;; (add-completion-to-tail-if-new "banish") --> ("banish" 0 nil 0)
+;; (car (find-cmpl-prefix-entry "ban")) -->(("banana" ...) ("banish" ...))
+;; (cdr (find-cmpl-prefix-entry "ban")) -->(("banish" ...))
+;;
\f
-;;;---------------------------------------------------------------------------
-;;; Database Update :: Interface level routines
-;;;---------------------------------------------------------------------------
-;;;
-;;; These lie on top of the database ref. functions but below the standard
-;;; user interface level
+;;---------------------------------------------------------------------------
+;; Database Update :: Interface level routines
+;;---------------------------------------------------------------------------
+;;
+;; These lie on top of the database ref. functions but below the standard
+;; user interface level
(defun interactive-completion-string-reader (prompt)
(setq cmpl-completions-accepted-p t)))))
))
-;;; Tests --
-;;; - Add and Find -
-;;; (add-completion "banana" 5 10)
-;;; (find-exact-completion "banana") --> ("banana" 5 10 0)
-;;; (add-completion "banana" 6)
-;;; (find-exact-completion "banana") --> ("banana" 6 10 0)
-;;; (add-completion "banish")
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banish" ...) ("banana" ...))
-;;;
-;;; - Accepting -
-;;; (setq completion-to-accept "banana")
-;;; (accept-completion)
-;;; (find-exact-completion "banana") --> ("banana" 7 10)
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...) ("banish" ...))
-;;; (setq completion-to-accept "banish")
-;;; (add-completion "banner")
-;;; (car (find-cmpl-prefix-entry "ban"))
-;;; --> (("banner" ...) ("banish" 1 ...) ("banana" 7 ...))
-;;;
-;;; - Deleting -
-;;; (kill-completion "banish")
-;;; (car (find-cmpl-prefix-entry "ban")) --> (("banner" ...) ("banana" ...))
+;; Tests --
+;; - Add and Find -
+;; (add-completion "banana" 5 10)
+;; (find-exact-completion "banana") --> ("banana" 5 10 0)
+;; (add-completion "banana" 6)
+;; (find-exact-completion "banana") --> ("banana" 6 10 0)
+;; (add-completion "banish")
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banish" ...) ("banana" ...))
+;;
+;; - Accepting -
+;; (setq completion-to-accept "banana")
+;; (accept-completion)
+;; (find-exact-completion "banana") --> ("banana" 7 10)
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banana" ...) ("banish" ...))
+;; (setq completion-to-accept "banish")
+;; (add-completion "banner")
+;; (car (find-cmpl-prefix-entry "ban"))
+;; --> (("banner" ...) ("banish" 1 ...) ("banana" 7 ...))
+;;
+;; - Deleting -
+;; (kill-completion "banish")
+;; (car (find-cmpl-prefix-entry "ban")) --> (("banner" ...) ("banana" ...))
\f
-;;;---------------------------------------------------------------------------
-;;; Searching the database
-;;;---------------------------------------------------------------------------
-;;; Functions outside this block must call completion-search-reset followed
-;;; by calls to completion-search-next or completion-search-peek
-;;;
-
-;;; Status variables
+;;---------------------------------------------------------------------------
+;; Searching the database
+;;---------------------------------------------------------------------------
+;; Functions outside this block must call completion-search-reset followed
+;; by calls to completion-search-next or completion-search-peek
+;;
+
+;; Status variables
;; Commented out to improve loading speed
(defvar cmpl-test-string "")
;; "The current string used by completion-search-next."
;; Completely unsuccessful, return nil
))
-;;; Tests --
-;;; - Add and Find -
-;;; (add-completion "banana")
-;;; (completion-search-reset "ban")
-;;; (completion-search-next 0) --> "banana"
-;;;
-;;; - Discrimination -
-;;; (add-completion "cumberland")
-;;; (add-completion "cumberbund")
-;;; cumbering
-;;; (completion-search-reset "cumb")
-;;; (completion-search-peek t) --> "cumberbund"
-;;; (completion-search-next 0) --> "cumberbund"
-;;; (completion-search-peek t) --> "cumberland"
-;;; (completion-search-next 1) --> "cumberland"
-;;; (completion-search-peek nil) --> nil
-;;; (completion-search-next 2) --> "cumbering" {cdabbrev}
-;;; (completion-search-next 3) --> nil or "cumming"{depends on context}
-;;; (completion-search-next 1) --> "cumberland"
-;;; (completion-search-peek t) --> "cumbering" {cdabbrev}
-;;;
-;;; - Accepting -
-;;; (completion-search-next 1) --> "cumberland"
-;;; (setq completion-to-accept "cumberland")
-;;; (completion-search-reset "foo")
-;;; (completion-search-reset "cum")
-;;; (completion-search-next 0) --> "cumberland"
-;;;
-;;; - Deleting -
-;;; (kill-completion "cumberland")
-;;; cummings
-;;; (completion-search-reset "cum")
-;;; (completion-search-next 0) --> "cumberbund"
-;;; (completion-search-next 1) --> "cummings"
-;;;
-;;; - Ignoring Capitalization -
-;;; (completion-search-reset "CuMb")
-;;; (completion-search-next 0) --> "cumberbund"
+;; Tests --
+;; - Add and Find -
+;; (add-completion "banana")
+;; (completion-search-reset "ban")
+;; (completion-search-next 0) --> "banana"
+;;
+;; - Discrimination -
+;; (add-completion "cumberland")
+;; (add-completion "cumberbund")
+;; cumbering
+;; (completion-search-reset "cumb")
+;; (completion-search-peek t) --> "cumberbund"
+;; (completion-search-next 0) --> "cumberbund"
+;; (completion-search-peek t) --> "cumberland"
+;; (completion-search-next 1) --> "cumberland"
+;; (completion-search-peek nil) --> nil
+;; (completion-search-next 2) --> "cumbering" {cdabbrev}
+;; (completion-search-next 3) --> nil or "cumming"{depends on context}
+;; (completion-search-next 1) --> "cumberland"
+;; (completion-search-peek t) --> "cumbering" {cdabbrev}
+;;
+;; - Accepting -
+;; (completion-search-next 1) --> "cumberland"
+;; (setq completion-to-accept "cumberland")
+;; (completion-search-reset "foo")
+;; (completion-search-reset "cum")
+;; (completion-search-next 0) --> "cumberland"
+;;
+;; - Deleting -
+;; (kill-completion "cumberland")
+;; cummings
+;; (completion-search-reset "cum")
+;; (completion-search-next 0) --> "cumberbund"
+;; (completion-search-next 1) --> "cummings"
+;;
+;; - Ignoring Capitalization -
+;; (completion-search-reset "CuMb")
+;; (completion-search-next 0) --> "cumberbund"
\f
-;;;-----------------------------------------------
-;;; COMPLETE
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; COMPLETE
+;;-----------------------------------------------
(defun completion-mode ()
"Toggles whether or not to add new words to the completion database."
(setq this-command 'failed-complete)
))))
-;;;-----------------------------------------------
-;;; "Complete" Key Keybindings
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; "Complete" Key Keybindings
+;;-----------------------------------------------
(global-set-key "\M-\r" 'complete)
(global-set-key [?\C-\r] 'complete)
(define-key function-key-map [C-return] [?\C-\r])
-;;; Tests -
-;;; (add-completion "cumberland")
-;;; (add-completion "cumberbund")
-;;; cum
-;;; Cumber
-;;; cumbering
-;;; cumb
+;; Tests -
+;; (add-completion "cumberland")
+;; (add-completion "cumberbund")
+;; cum
+;; Cumber
+;; cumbering
+;; cumb
\f
-;;;---------------------------------------------------------------------------
-;;; Parsing definitions from files into the database
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; Parsing definitions from files into the database
+;;---------------------------------------------------------------------------
-;;;-----------------------------------------------
-;;; Top Level functions ::
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Top Level functions ::
+;;-----------------------------------------------
-;;; User interface
+;; User interface
(defun add-completions-from-file (file)
"Parse possible completions from a file and add them to data base."
(interactive "fFile: ")
start-num)))
))
-;;; Find file hook
+;; Find file hook
(defun cmpl-find-file-hook ()
(cond (enable-completion
(cond ((and (memq major-mode '(emacs-lisp-mode lisp-mode))
(add-hook 'find-file-hooks 'cmpl-find-file-hook)
-;;;-----------------------------------------------
-;;; Tags Table Completions
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Tags Table Completions
+;;-----------------------------------------------
(defun add-completions-from-tags-table ()
;; Inspired by eero@media-lab.media.mit.edu
))))
\f
-;;;-----------------------------------------------
-;;; Lisp File completion parsing
-;;;-----------------------------------------------
-;;; This merely looks for phrases beginning with (def.... or
-;;; (package:def ... and takes the next word.
-;;;
-;;; We tried using forward-lines and explicit searches but the regexp technique
-;;; was faster. (About 100K characters per second)
-;;;
+;;-----------------------------------------------
+;; Lisp File completion parsing
+;;-----------------------------------------------
+;; This merely looks for phrases beginning with (def.... or
+;; (package:def ... and takes the next word.
+;;
+;; We tried using forward-lines and explicit searches but the regexp technique
+;; was faster. (About 100K characters per second)
+;;
(defconst *lisp-def-regexp*
"\n(\\(\\w*:\\)?def\\(\\w\\|\\s_\\)*\\s +(*"
"A regexp that searches for lisp definition form."
)
-;;; Tests -
-;;; (and (string-match *lisp-def-regexp* "\n(defun foo") (match-end 0)) -> 8
-;;; (and (string-match *lisp-def-regexp* "\n(si:def foo") (match-end 0)) -> 9
-;;; (and (string-match *lisp-def-regexp* "\n(def-bar foo")(match-end 0)) -> 10
-;;; (and (string-match *lisp-def-regexp* "\n(defun (foo") (match-end 0)) -> 9
+;; Tests -
+;; (and (string-match *lisp-def-regexp* "\n(defun foo") (match-end 0)) -> 8
+;; (and (string-match *lisp-def-regexp* "\n(si:def foo") (match-end 0)) -> 9
+;; (and (string-match *lisp-def-regexp* "\n(def-bar foo")(match-end 0)) -> 10
+;; (and (string-match *lisp-def-regexp* "\n(defun (foo") (match-end 0)) -> 9
-;;; Parses all the definition names from a Lisp mode buffer and adds them to
-;;; the completion database.
+;; Parses all the definition names from a Lisp mode buffer and adds them to
+;; the completion database.
(defun add-completions-from-lisp-buffer ()
;;; Benchmarks
;;; Sun-3/280 - 1500 to 3000 lines of lisp code per second
))))
\f
-;;;-----------------------------------------------
-;;; C file completion parsing
-;;;-----------------------------------------------
-;;; C :
-;;; Looks for #define or [<storage class>] [<type>] <name>{,<name>}
-;;; or structure, array or pointer defs.
-;;; It gets most of the definition names.
-;;;
-;;; As you might suspect by now, we use some symbol table hackery
-;;;
-;;; Symbol separator chars (have whitespace syntax) --> , ; * = (
-;;; Opening char --> [ {
-;;; Closing char --> ] }
-;;; opening and closing must be skipped over
-;;; Whitespace chars (have symbol syntax)
-;;; Everything else has word syntax
+;;-----------------------------------------------
+;; C file completion parsing
+;;-----------------------------------------------
+;; C :
+;; Looks for #define or [<storage class>] [<type>] <name>{,<name>}
+;; or structure, array or pointer defs.
+;; It gets most of the definition names.
+;;
+;; As you might suspect by now, we use some symbol table hackery
+;;
+;; Symbol separator chars (have whitespace syntax) --> , ; * = (
+;; Opening char --> [ {
+;; Closing char --> ] }
+;; opening and closing must be skipped over
+;; Whitespace chars (have symbol syntax)
+;; Everything else has word syntax
(defun cmpl-make-c-def-completion-syntax-table ()
(let ((table (make-syntax-table))
(defconst cmpl-c-def-syntax-table (cmpl-make-c-def-completion-syntax-table))
-;;; Regexps
+;; Regexps
(defconst *c-def-regexp*
;; This stops on lines with possible definitions
"\n[_a-zA-Z#]"
; (and (eq 0 (string-match regexp string)) (match-end 0))
; )
-;;; Tests -
-;;; (test-c-def-regexp *c-def-regexp* "\n#define foo") -> 10 (9)
-;;; (test-c-def-regexp *c-def-regexp* "\nfoo (x, y) {") -> 6 (6)
-;;; (test-c-def-regexp *c-def-regexp* "\nint foo (x, y)") -> 10 (5)
-;;; (test-c-def-regexp *c-def-regexp* "\n int foo (x, y)") -> nil
-;;; (test-c-def-regexp *c-cont-regexp* "oo, bar") -> 4
-;;; (test-c-def-regexp *c-cont-regexp* "oo, *bar") -> 5
-;;; (test-c-def-regexp *c-cont-regexp* "a [5][6], bar") -> 10
-;;; (test-c-def-regexp *c-cont-regexp* "oo(x,y)") -> nil
-;;; (test-c-def-regexp *c-cont-regexp* "a [6] ,\t bar") -> 9
-;;; (test-c-def-regexp *c-cont-regexp* "oo {trout =1} my_carp;") -> 14
-;;; (test-c-def-regexp *c-cont-regexp* "truct_p complex foon") -> nil
-
-;;; Parses all the definition names from a C mode buffer and adds them to the
-;;; completion database.
+;; Tests -
+;; (test-c-def-regexp *c-def-regexp* "\n#define foo") -> 10 (9)
+;; (test-c-def-regexp *c-def-regexp* "\nfoo (x, y) {") -> 6 (6)
+;; (test-c-def-regexp *c-def-regexp* "\nint foo (x, y)") -> 10 (5)
+;; (test-c-def-regexp *c-def-regexp* "\n int foo (x, y)") -> nil
+;; (test-c-def-regexp *c-cont-regexp* "oo, bar") -> 4
+;; (test-c-def-regexp *c-cont-regexp* "oo, *bar") -> 5
+;; (test-c-def-regexp *c-cont-regexp* "a [5][6], bar") -> 10
+;; (test-c-def-regexp *c-cont-regexp* "oo(x,y)") -> nil
+;; (test-c-def-regexp *c-cont-regexp* "a [6] ,\t bar") -> 9
+;; (test-c-def-regexp *c-cont-regexp* "oo {trout =1} my_carp;") -> 14
+;; (test-c-def-regexp *c-cont-regexp* "truct_p complex foon") -> nil
+
+;; Parses all the definition names from a C mode buffer and adds them to the
+;; completion database.
(defun add-completions-from-c-buffer ()
;; Benchmark --
;; Sun 3/280-- 1250 lines/sec.
)))))
\f
-;;;---------------------------------------------------------------------------
-;;; Init files
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; Init files
+;;---------------------------------------------------------------------------
-;;; The version of save-completions-to-file called at kill-emacs time.
+;; The version of save-completions-to-file called at kill-emacs time.
(defun kill-emacs-save-completions ()
(if (and save-completions-flag enable-completion cmpl-initialized-p)
(cond
(defconst saved-cmpl-file-header
";;; Completion Initialization file.
-;;; Version = %s
-;;; Format is (<string> . <last-use-time>)
-;;; <string> is the completion
-;;; <last-use-time> is the time the completion was last used
-;;; If it is t, the completion will never be pruned from the file.
-;;; Otherwise it is in hours since origin.
+;; Version = %s
+;; Format is (<string> . <last-use-time>)
+;; <string> is the completion
+;; <last-use-time> is the time the completion was last used
+;; If it is t, the completion will never be pruned from the file.
+;; Otherwise it is in hours since origin.
\n")
(defun completion-backup-filename (filename)
(record-save-completions total-in-db total-perm total-saved))
))))
-;;;(defun autosave-completions ()
-;;; (if (and save-completions-flag enable-completion cmpl-initialized-p
-;;; *completion-auto-save-period*
-;;; (> cmpl-emacs-idle-time *completion-auto-save-period*)
-;;; cmpl-completions-accepted-p)
-;;; (save-completions-to-file)))
+;;(defun autosave-completions ()
+;; (if (and save-completions-flag enable-completion cmpl-initialized-p
+;; *completion-auto-save-period*
+;; (> cmpl-emacs-idle-time *completion-auto-save-period*)
+;; cmpl-completions-accepted-p)
+;; (save-completions-to-file)))
-;;;(add-hook 'cmpl-emacs-idle-time-hooks 'autosave-completions)
+;;(add-hook 'cmpl-emacs-idle-time-hooks 'autosave-completions)
(defun load-completions-from-file (&optional filename no-message-p)
"Loads a completion init file FILENAME.
)
-;;;-----------------------------------------------
-;;; Kill EMACS patch
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Kill EMACS patch
+;;-----------------------------------------------
(add-hook 'kill-emacs-hook
'(lambda ()
(cmpl-statistics-block
(record-cmpl-kill-emacs))))
\f
-;;;-----------------------------------------------
-;;; Kill region patch
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Kill region patch
+;;-----------------------------------------------
(defun completion-kill-region (&optional beg end)
"Kill between point and mark.
(global-set-key "\C-w" 'completion-kill-region)
\f
-;;;-----------------------------------------------
-;;; Patches to self-insert-command.
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Patches to self-insert-command.
+;;-----------------------------------------------
-;;; Need 2 versions: generic separator chars. and space (to get auto fill
-;;; to work)
+;; Need 2 versions: generic separator chars. and space (to get auto fill
+;; to work)
-;;; All common separators (eg. space "(" ")" """) characters go through a
-;;; function to add new words to the list of words to complete from:
-;;; COMPLETION-SEPARATOR-SELF-INSERT-COMMAND (arg).
-;;; If the character before this was an alpha-numeric then this adds the
-;;; symbol before point to the completion list (using ADD-COMPLETION).
+;; All common separators (eg. space "(" ")" """) characters go through a
+;; function to add new words to the list of words to complete from:
+;; COMPLETION-SEPARATOR-SELF-INSERT-COMMAND (arg).
+;; If the character before this was an alpha-numeric then this adds the
+;; symbol before point to the completion list (using ADD-COMPLETION).
(defun completion-separator-self-insert-command (arg)
(interactive "p")
(funcall auto-fill-function))
)
-;;;-----------------------------------------------
-;;; Wrapping Macro
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Wrapping Macro
+;;-----------------------------------------------
-;;; Note that because of the way byte compiling works, none of
-;;; the functions defined with this macro get byte compiled.
+;; Note that because of the way byte compiling works, none of
+;; the functions defined with this macro get byte compiled.
(defmacro def-completion-wrapper (function-name type &optional new-name)
"Add a call to update the completion database before function execution.
(add-hook 'pre-command-hook 'completion-before-command)
-;;;---------------------------------------------------------------------------
-;;; Patches to standard keymaps insert completions
-;;;---------------------------------------------------------------------------
+;;---------------------------------------------------------------------------
+;; Patches to standard keymaps insert completions
+;;---------------------------------------------------------------------------
-;;;-----------------------------------------------
-;;; Separators
-;;;-----------------------------------------------
-;;; We've used the completion syntax table given as a guide.
-;;;
-;;; Global separator chars.
-;;; We left out <tab> because there are too many special cases for it. Also,
-;;; in normal coding it's rarely typed after a word.
+;;-----------------------------------------------
+;; Separators
+;;-----------------------------------------------
+;; We've used the completion syntax table given as a guide.
+;;
+;; Global separator chars.
+;; We left out <tab> because there are too many special cases for it. Also,
+;; in normal coding it's rarely typed after a word.
(global-set-key " " 'completion-separator-self-insert-autofilling)
(global-set-key "!" 'completion-separator-self-insert-command)
(global-set-key "%" 'completion-separator-self-insert-command)
(global-set-key "," 'completion-separator-self-insert-command)
(global-set-key "?" 'completion-separator-self-insert-command)
-;;; We include period and colon even though they are symbol chars because :
-;;; - in text we want to pick up the last word in a sentence.
-;;; - in C pointer refs. we want to pick up the first symbol
-;;; - it won't make a difference for lisp mode (package names are short)
+;; We include period and colon even though they are symbol chars because :
+;; - in text we want to pick up the last word in a sentence.
+;; - in C pointer refs. we want to pick up the first symbol
+;; - it won't make a difference for lisp mode (package names are short)
(global-set-key "." 'completion-separator-self-insert-command)
(global-set-key ":" 'completion-separator-self-insert-command)
-;;; Lisp Mode diffs
+;; Lisp Mode diffs
(define-key lisp-mode-map "!" 'self-insert-command)
(define-key lisp-mode-map "&" 'self-insert-command)
(define-key lisp-mode-map "%" 'self-insert-command)
(define-key lisp-mode-map "=" 'self-insert-command)
(define-key lisp-mode-map "^" 'self-insert-command)
-;;; C mode diffs.
+;; C mode diffs.
(defun completion-c-mode-hook ()
(def-completion-wrapper electric-c-semi :separator)
(define-key c-mode-map "+" 'completion-separator-self-insert-command)
(completion-c-mode-hook)
(add-hook 'c-mode-hook 'completion-c-mode-hook))
-;;; FORTRAN mode diffs. (these are defined when fortran is called)
+;; FORTRAN mode diffs. (these are defined when fortran is called)
(defun completion-setup-fortran-mode ()
(define-key fortran-mode-map "+" 'completion-separator-self-insert-command)
(define-key fortran-mode-map "-" 'completion-separator-self-insert-command)
(define-key fortran-mode-map "/" 'completion-separator-self-insert-command)
)
-;;;-----------------------------------------------
-;;; End of line chars.
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; End of line chars.
+;;-----------------------------------------------
(def-completion-wrapper newline :separator)
(def-completion-wrapper newline-and-indent :separator)
(def-completion-wrapper comint-send-input :separator)
(def-completion-wrapper eval-last-sexp :separator)
;;(def-completion-wrapper minibuffer-complete-and-exit :minibuffer)
-;;;-----------------------------------------------
-;;; Cursor movement
-;;;-----------------------------------------------
+;;-----------------------------------------------
+;; Cursor movement
+;;-----------------------------------------------
(def-completion-wrapper next-line :under-or-before)
(def-completion-wrapper previous-line :under-or-before)
(def-completion-wrapper delete-backward-char :backward)
(def-completion-wrapper delete-backward-char-untabify :backward)
-;;; Tests --
-;;; foobarbiz
-;;; foobar
-;;; fooquux
-;;; fooper
+;; Tests --
+;; foobarbiz
+;; foobar
+;; fooquux
+;; fooper
(cmpl-statistics-block
(record-completion-file-loaded))
;;; custom.el --- User friendly customization support.
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
-;;
+
;; Author: Per Abrahamsen <abraham@iesd.auc.dk>
;; Keywords: help
;; Version: 0.5
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
;;; Commentary:
-;;
+
;; WARNING: This package is still under construction and not all of
;; the features below are implemented.
;;
;;; dabbrev.el --- dynamic abbreviation package
+
;; Copyright (C) 1985, 1986, 1992, 1994 Free Software Foundation, Inc.
;; Author: Don Morrison
;; Lindberg's last update version: 5.7
;; Keywords: abbrev expand completion
-;; This program is free software; you can redistribute it and/or modify
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2 of the License, or
-;; (at your option) any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Code:
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
-;;; Customization variables
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
+;;----------------------------------------------------------------
+;; Customization variables
+;;----------------------------------------------------------------
(defvar dabbrev-backward-only nil
"*If non-nil, `dabbrev-expand' only looks backwards.")
It will not even look in the current buffer if it is not a member of
this list.")
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
-;;; Internal variables
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
+;;----------------------------------------------------------------
+;; Internal variables
+;;----------------------------------------------------------------
;; Last obarray of completions in `dabbrev-completion'
(defvar dabbrev--last-obarray nil)
;; The regexp for recognizing a character in an abbreviation.
(defvar dabbrev--abbrev-char-regexp nil)
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
-;;; Macros
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
+;;----------------------------------------------------------------
+;; Macros
+;;----------------------------------------------------------------
;;; Get the buffer that mini-buffer was activated from
(defsubst dabbrev--minibuffer-origin ()
(setq dabbrev-tail (cdr dabbrev-tail)))
(nreverse dabbrev-result))))
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
-;;; Exported functions
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
+;;----------------------------------------------------------------
+;; Exported functions
+;;----------------------------------------------------------------
;;;###autoload
(define-key esc-map "/" 'dabbrev-expand)
(setq dabbrev--last-abbreviation abbrev)
(setq dabbrev--last-abbrev-location (point-marker))))))
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
-;;; Local functions
-;;;----------------------------------------------------------------
-;;;----------------------------------------------------------------
+;;----------------------------------------------------------------
+;; Local functions
+;;----------------------------------------------------------------
;;; Checks if OTHER-BUFFER has the same major mode as current buffer.
(defun dabbrev--same-major-mode-p (other-buffer)
(provide 'dabbrev)
-;; dabbrev.el ends here
-
-
+;;; dabbrev.el ends here
;;; delsel.el --- delete selection if you insert
-;;; Copyright (C) 1992 Free Software Foundation, Inc.
+;; Copyright (C) 1992 Free Software Foundation, Inc.
;; Author: Matthieu Devin <devin@lucid.com>
;; Created: 14 Jul 92
;; Last change 18-Feb-93, devin.
-;;; This file is part of GNU Emacs.
+;; This file is part of GNU Emacs.
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This file makes the active region be pending delete, meaning that
-;;; text inserted while the region is active will replace the region contents.
-;;; This is a popular behavior of personal computers text editors.
+;; This file makes the active region be pending delete, meaning that
+;; text inserted while the region is active will replace the region contents.
+;; This is a popular behavior of personal computers text editors.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
\f
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This is Sebastian Kremer's excellent dired-x.el (Dired Extra), version
-;;; 1.191, hacked up for GNU Emacs 19. Redundant or conflicting material
-;;; has been removed or renamed in order to work properly with dired of
-;;; GNU Emacs 19. All suggestions or comments are most welcomed.
-
-;;;
-;;; Please, PLEASE, *PLEASE* see the info pages.
-;;;
-
-;;; BUGS: Type M-x dired-x-submit-report and a report will be generated.
-
-;;; INSTALLATION: In your ~/.emacs,
-;;;
-;;; (add-hook 'dired-load-hook
-;;; (function (lambda ()
-;;; (load "dired-x")
-;;; ;; Set global variables here. For example:
-;;; ;; (setq dired-guess-shell-gnutar "gtar")
-;;; )))
-;;; (add-hook 'dired-mode-hook
-;;; (function (lambda ()
-;;; ;; Set buffer-local variables here. For example:
-;;; ;; (setq dired-omit-files-p t)
-;;; )))
-;;;
-;;; At load time dired-x.el will install itself, redefine some functions, and
-;;; bind some dired keys. *Please* see the info pages for more details.
-
-;;; CAUTION: If you are using a version of GNU Emacs earlier than 19.20 than
-;;; you may have to edit dired.el. The copy of dired.el in GNU Emacs versions
-;;; earlier than 19.20 incorrectly had the call to run-hooks *before* the call
-;;; to provide. In such a case, it is possible that byte-compiling and/or
-;;; loading dired can cause an infinite loop. To prevent this, make sure the
-;;; line of code
-;;;
-;;; (run-hooks 'dired-load-hook)
-;;;
-;;; is the *last* executable line in the file dired.el. That is, make sure it
-;;; comes *after* the line
-;;;
-;;; (provide 'dired)
-;;;
-;;; *Please* see the info pages for more details.
-
-;;; User defined variables:
-;;;
-;;; dired-bind-vm
-;;; dired-vm-read-only-folders
-;;; dired-bind-jump
-;;; dired-bind-info
-;;; dired-bind-man
-;;; dired-x-hands-off-my-keys
-;;; dired-find-subdir
-;;; dired-enable-local-variables
-;;; dired-local-variables-file
-;;; dired-guess-shell-gnutar
-;;; dired-guess-shell-gzip-quiet
-;;; dired-guess-shell-znew-switches
-;;; dired-guess-shell-alist-user
-;;; dired-clean-up-buffers-too
-;;; dired-omit-files-p
-;;; dired-omit-files
-;;; dired-omit-extensions
-;;;
-;;; To find out more about these variables, load this file, put your cursor at
-;;; the end of any of the variable names, and hit C-h v [RET]. *Please* see
-;;; the info pages for more details.
-
-;;; When loaded this code redefines the following functions of GNU Emacs
-;;;
-;;; Function Found in this file of GNU Emacs
-;;; -------- -------------------------------
-;;; dired-clean-up-after-deletion ../lisp/dired.el
-;;; dired-find-buffer-nocreate ../lisp/dired.el
-;;; dired-initial-position ../lisp/dired.el
-;;;
-;;; dired-add-entry ../lisp/dired-aux.el
-;;; dired-read-shell-command ../lisp/dired-aux.el
-;;;
-;;; One drawback is that dired-x.el will load dired-aux.el as soon as dired is
-;;; loaded. Thus, the advantage of separating out non-essential dired stuff
-;;; into dired-aux.el and only loading when necessary will be lost. Please
-;;; note also that some of the comments in dired.el and dired-aux.el are
-;;; Kremer's that referred to the old dired-x.el. This now should be referring
-;;; to this program. (This is also a good reason to call this dired-x.el
-;;; instead of dired-x19.el.)
+;; This is Sebastian Kremer's excellent dired-x.el (Dired Extra), version
+;; 1.191, hacked up for GNU Emacs 19. Redundant or conflicting material
+;; has been removed or renamed in order to work properly with dired of
+;; GNU Emacs 19. All suggestions or comments are most welcomed.
+
+;;
+;; Please, PLEASE, *PLEASE* see the info pages.
+;;
+
+;; BUGS: Type M-x dired-x-submit-report and a report will be generated.
+
+;; INSTALLATION: In your ~/.emacs,
+;;
+;; (add-hook 'dired-load-hook
+;; (function (lambda ()
+;; (load "dired-x")
+;; ;; Set global variables here. For example:
+;; ;; (setq dired-guess-shell-gnutar "gtar")
+;; )))
+;; (add-hook 'dired-mode-hook
+;; (function (lambda ()
+;; ;; Set buffer-local variables here. For example:
+;; ;; (setq dired-omit-files-p t)
+;; )))
+;;
+;; At load time dired-x.el will install itself, redefine some functions, and
+;; bind some dired keys. *Please* see the info pages for more details.
+
+;; CAUTION: If you are using a version of GNU Emacs earlier than 19.20 than
+;; you may have to edit dired.el. The copy of dired.el in GNU Emacs versions
+;; earlier than 19.20 incorrectly had the call to run-hooks *before* the call
+;; to provide. In such a case, it is possible that byte-compiling and/or
+;; loading dired can cause an infinite loop. To prevent this, make sure the
+;; line of code
+;;
+;; (run-hooks 'dired-load-hook)
+;;
+;; is the *last* executable line in the file dired.el. That is, make sure it
+;; comes *after* the line
+;;
+;; (provide 'dired)
+;;
+;; *Please* see the info pages for more details.
+
+;; User defined variables:
+;;
+;; dired-bind-vm
+;; dired-vm-read-only-folders
+;; dired-bind-jump
+;; dired-bind-info
+;; dired-bind-man
+;; dired-x-hands-off-my-keys
+;; dired-find-subdir
+;; dired-enable-local-variables
+;; dired-local-variables-file
+;; dired-guess-shell-gnutar
+;; dired-guess-shell-gzip-quiet
+;; dired-guess-shell-znew-switches
+;; dired-guess-shell-alist-user
+;; dired-clean-up-buffers-too
+;; dired-omit-files-p
+;; dired-omit-files
+;; dired-omit-extensions
+;;
+;; To find out more about these variables, load this file, put your cursor at
+;; the end of any of the variable names, and hit C-h v [RET]. *Please* see
+;; the info pages for more details.
+
+;; When loaded this code redefines the following functions of GNU Emacs
+;;
+;; Function Found in this file of GNU Emacs
+;; -------- -------------------------------
+;; dired-clean-up-after-deletion ../lisp/dired.el
+;; dired-find-buffer-nocreate ../lisp/dired.el
+;; dired-initial-position ../lisp/dired.el
+;;
+;; dired-add-entry ../lisp/dired-aux.el
+;; dired-read-shell-command ../lisp/dired-aux.el
+;;
+;; One drawback is that dired-x.el will load dired-aux.el as soon as dired is
+;; loaded. Thus, the advantage of separating out non-essential dired stuff
+;; into dired-aux.el and only loading when necessary will be lost. Please
+;; note also that some of the comments in dired.el and dired-aux.el are
+;; Kremer's that referred to the old dired-x.el. This now should be referring
+;; to this program. (This is also a good reason to call this dired-x.el
+;; instead of dired-x19.el.)
\f
-;;;; Code:
+;;; Code:
-;;; LOAD.
+;; LOAD.
-;;; This is a no-op if dired-x is being loaded via `dired-load-hook'. It is
-;;; here in case the user has autoloaded dired-x via the dired-jump key binding
-;;; (instead of autoloading to dired as is suggested in the info-pages).
+;; This is a no-op if dired-x is being loaded via `dired-load-hook'. It is
+;; here in case the user has autoloaded dired-x via the dired-jump key binding
+;; (instead of autoloading to dired as is suggested in the info-pages).
(require 'dired)
-;;; We will redefine some functions and also need some macros so we need to
-;;; load dired stuff of GNU Emacs.
+;; We will redefine some functions and also need some macros so we need to
+;; load dired stuff of GNU Emacs.
(require 'dired-aux)
-;;;; User-defined variables.
+;;; User-defined variables.
(defvar dired-bind-vm nil
"*t says \"V\" in dired-mode will `dired-vm', otherwise \"V\" is `dired-rmail'.
(defvar dired-clean-up-buffers-too t
"*t says offer to kill buffers visiting files and dirs deleted in dired.")
-;;;; KEY BINDINGS.
+;;; KEY BINDINGS.
(define-key dired-mode-map "\M-o" 'dired-omit-toggle)
(define-key dired-mode-map "\M-(" 'dired-mark-sexp)
(define-key global-map "\C-x4\C-j" 'dired-jump-other-window)))
\f
-;;;; Install into appropriate hooks.
+;;; Install into appropriate hooks.
(add-hook 'dired-mode-hook 'dired-extra-startup)
(add-hook 'dired-after-readin-hook 'dired-omit-expunge)
(dired-omit-startup))
\f
-;;;; BUFFER CLEANING.
+;;; BUFFER CLEANING.
-;;; REDEFINE.
+;; REDEFINE.
(defun dired-clean-up-after-deletion (fn)
;; Clean up after a deleted file or directory FN.
)
\f
-;;;; EXTENSION MARKING FUNCTIONS.
+;;; EXTENSION MARKING FUNCTIONS.
;;; Mark files with some extension.
(defun dired-mark-extension (extension &optional marker-char)
dired-tex-unclean-extensions
(list ".dvi"))))
\f
-;;;; JUMP.
+;;; JUMP.
;;;###autoload
(defun dired-jump (&optional other-window)
(interactive)
(dired-jump t))
\f
-;;;; TOGGLE.
+;;; TOGGLE.
;;; Toggle marked files with unmarked files.
(defun dired-do-toggle ()
(forward-line 1)))))
\f
-;;;; COPY NAMES OF MARKED FILES INTO KILL-RING.
+;;; COPY NAMES OF MARKED FILES INTO KILL-RING.
(defun dired-copy-filename-as-kill (&optional arg)
"Copy names of marked (or next ARG) files into the kill ring.
(message "%s" string)))
\f
-;;;; OMITTING.
+;;; OMITTING.
;;; Enhanced omitting of lines from directory listings.
;;; Marked files are never omitted.
(fset 'dired-add-entry 'dired-omit-new-add-entry)
\f
-;;;; VIRTUAL DIRED MODE.
+;;; VIRTUAL DIRED MODE.
;;; For browsing `ls -lR' listings in a dired-like fashion.
(dired-virtual (dired-virtual-guess-dir)))
\f
-;;;; SMART SHELL.
+;;; SMART SHELL.
;;; An Emacs buffer can have but one working directory, stored in the
;;; buffer-local variable `default-directory'. A Dired buffer may have
(shell-command cmd insert)))
\f
-;;;; LOCAL VARIABLES FOR DIRED BUFFERS.
+;;; LOCAL VARIABLES FOR DIRED BUFFERS.
;;; Brief Description:
;;;
(dired-revert)))
\f
-;;;; GUESS SHELL COMMAND.
+;;; GUESS SHELL COMMAND.
;;; Brief Description:
;;;
files)) ; FILES
\f
-;;;; RELATIVE SYMBOLIC LINKS.
+;;; RELATIVE SYMBOLIC LINKS.
(defvar dired-keep-marker-relsymlink ?S
"See variable `dired-keep-marker-move'.")
"RelSymLink" nil regexp newname whole-path dired-keep-marker-relsymlink))
\f
-;;;; VISIT ALL MARKED FILES SIMULTANEOUSLY.
+;;; VISIT ALL MARKED FILES SIMULTANEOUSLY.
;;; Brief Description:
;;;
(setq file-list (cdr file-list)))))
\f
-;;;; MISCELLANEOUS COMMANDS.
+;;; MISCELLANEOUS COMMANDS.
;;; Run man on files.
(dired-rmail)))
\f
-;;;; MISCELLANEOUS INTERNAL FUNCTIONS.
+;;; MISCELLANEOUS INTERNAL FUNCTIONS.
(or (fboundp 'dired-old-find-buffer-nocreate)
(fset 'dired-old-find-buffer-nocreate
(format "'%s file" predicate))))
\f
-;;;; FIND FILE AT POINT.
+;;; FIND FILE AT POINT.
(defvar dired-x-hands-off-my-keys t
"*t means don't bind `dired-x-find-file' over `find-file' on keyboard.
(read-file-name prompt default-directory)))
\f
-;;;; BUG REPORTS
+;;; BUG REPORTS
;;; This section is provided for reports. It uses Barry A. Warsaw's
;;; reporter.el which is bundled with GNU Emacs v19.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; docref.el --- Simple cross references for Elisp documentation strings
+
;; Copyright (C) 1994 Free Software Foundation, Inc.
;; Author: Vadim Geshel <vadik@unas.cs.kiev.ua>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; This package allows you to use a simple form of cross references in
;; your Emacs Lisp documentation strings. Cross-references look like
;; \\(type@[label@]data), where type defines a method for retrieving
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; ediff-diff.el --- diff-related utilities
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
-(require 'ediff-init)
+;;; Code:
+(require 'ediff-init)
(defvar ediff-shell
(cond ((eq system-type 'emx) "cmd") ; OS/2
(provide 'ediff-diff)
-
;; ediff-diff.el ends here
;;; ediff-hook.el --- setup for Ediff's menus and autoloads
-;;; Copyright (C) 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+;;; Code:
-;;; These must be placed in menu-bar.el in Emacs
+;; These must be placed in menu-bar.el in Emacs
;;
;; (define-key menu-bar-tools-menu [eregistry]
;; '("List Ediff Sessions" . ediff-show-registry))
;;; ediff-init.el --- Macros, variables, and defsubsts used by Ediff
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+;;; Code:
;; Is it XEmacs?
(defconst ediff-xemacs-p (string-match "XEmacs" emacs-version))
;;; ediff-merg.el --- merging utilities
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+;;; Code:
(require 'ediff-init)
;;; ediff-mult.el --- support for multi-file/multi-buffer processing in Ediff
-;;; Copyright (C) 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Commentary:
-;;; Notes:
-;;
;; Users are strongly encourage to add functionality to this file.
;; In particular, epatch needs to be enhanced to work with multi-file
;; patches. The present file contains all the infrastructure needed for that.
;; that do the layout of the meta- and differences buffers and of
;; ediff-dir-action.
+;;; Code:
+
(require 'ediff-init)
;; meta-buffer
;;; ediff-util.el --- the core commands and utilities of ediff
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; ediff-wind.el --- window manipulation utilities
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+;;; Code:
(require 'ediff-init)
;;; ediff.el --- a comprehensive visual interface to diff & patch
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
;; Created: February 2, 1994
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;; ----------
;; Never read that diff output again!
;; Apply patch selectively, like a pro!
;; particular, it can do patching, and 2-way and 3-way file comparison,
;; merging, and directory operations.
-
-
;;; Bugs:
-;; -----
;; 1. The undo command doesn't restore deleted regions well. That is, if
;; you delete all characters in a difference region and then invoke
;; commands in `ediff-prepare-buffer-hook' (which will unhighlight every
;; buffer used by Ediff) or you can execute them interactively, at any time
;; and on any buffer.
-;;
-
;;; Acknowledgements:
;; its many users. See Ediff on-line Info for the full list of those who
;; helped. Improved defaults in Ediff file-name reading commands.
-
;;; Code:
(require 'ediff-init)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; LCD Archive Entry:
;; advice|Hans Chalupsky|hans@cs.buffalo.edu|
;;; assoc.el --- insert/delete/sort functions on association lists
+;; Copyright (C) 1996 Free Software Foundation, Inc.
+
;; Author: Barry A. Warsaw <bwarsaw@cen.com>
;; Keywords: extensions
-;; This software is distributed in the hope that it will be useful,
-;; but WITHOUT ANY WARRANTY. No author or distributor accepts
-;; responsibility to anyone for the consequences of using it or for
-;; whether it serves any particular purpose or works at all, unless he
-;; says so in writing.
-
-;; This software was written as part of the supercite author's
-;; official duty as an employee of the United States Government and is
-;; thus in the public domain. You are free to use that particular
-;; software as you wish, but WITHOUT ANY WARRANTY WHATSOEVER. It
-;; would be nice, though if when you use any of this code, you give
-;; due credit to the author.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; autoload.el --- maintain autoloads in loaddefs.el.
-;;; Copyright (C) 1991, 92, 93, 94, 95, 96 Free Software Foundation, Inc.
-;;;
+;; Copyright (C) 1991, 92, 93, 94, 95, 96 Free Software Foundation, Inc.
+
;; Author: Roland McGrath <roland@gnu.ai.mit.edu>
;; Keywords: maint
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; This program is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; A copy of the GNU General Public License can be obtained from this
-;;; program's author (send electronic mail to roland@ai.mit.edu) or from
-;;; the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA
-;;; 02139, USA.
-;;;
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; backquote.el -- implement the ` Lisp construct
+
;;; Copyright (C) 1990, 1992, 1994 Free Software Foundation, Inc.
;; Author: Rick Sladkey <jrs@world.std.com>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; ========================================================================
-;;; "No matter how hard you try, you can't make a racehorse out of a pig.
-;;; You can, however, make a faster pig."
-;;;
-;;; Or, to put it another way, the emacs byte compiler is a VW Bug. This code
-;;; makes it be a VW Bug with fuel injection and a turbocharger... You're
-;;; still not going to make it go faster than 70 mph, but it might be easier
-;;; to get it there.
-;;;
+;; ========================================================================
+;; "No matter how hard you try, you can't make a racehorse out of a pig.
+;; You can, however, make a faster pig."
+;;
+;; Or, to put it another way, the emacs byte compiler is a VW Bug. This code
+;; makes it be a VW Bug with fuel injection and a turbocharger... You're
+;; still not going to make it go faster than 70 mph, but it might be easier
+;; to get it there.
+;;
-;;; TO DO:
-;;;
-;;; (apply '(lambda (x &rest y) ...) 1 (foo))
-;;;
-;;; maintain a list of functions known not to access any global variables
-;;; (actually, give them a 'dynamically-safe property) and then
-;;; (let ( v1 v2 ... vM vN ) <...dynamically-safe...> ) ==>
-;;; (let ( v1 v2 ... vM ) vN <...dynamically-safe...> )
-;;; by recursing on this, we might be able to eliminate the entire let.
-;;; However certain variables should never have their bindings optimized
-;;; away, because they affect everything.
-;;; (put 'debug-on-error 'binding-is-magic t)
-;;; (put 'debug-on-abort 'binding-is-magic t)
-;;; (put 'debug-on-next-call 'binding-is-magic t)
-;;; (put 'mocklisp-arguments 'binding-is-magic t)
-;;; (put 'inhibit-quit 'binding-is-magic t)
-;;; (put 'quit-flag 'binding-is-magic t)
-;;; (put 't 'binding-is-magic t)
-;;; (put 'nil 'binding-is-magic t)
-;;; possibly also
-;;; (put 'gc-cons-threshold 'binding-is-magic t)
-;;; (put 'track-mouse 'binding-is-magic t)
-;;; others?
-;;;
-;;; Simple defsubsts often produce forms like
-;;; (let ((v1 (f1)) (v2 (f2)) ...)
-;;; (FN v1 v2 ...))
-;;; It would be nice if we could optimize this to
-;;; (FN (f1) (f2) ...)
-;;; but we can't unless FN is dynamically-safe (it might be dynamically
-;;; referring to the bindings that the lambda arglist established.)
-;;; One of the uncountable lossages introduced by dynamic scope...
-;;;
-;;; Maybe there should be a control-structure that says "turn on
-;;; fast-and-loose type-assumptive optimizations here." Then when
-;;; we see a form like (car foo) we can from then on assume that
-;;; the variable foo is of type cons, and optimize based on that.
-;;; But, this won't win much because of (you guessed it) dynamic
-;;; scope. Anything down the stack could change the value.
-;;; (Another reason it doesn't work is that it is perfectly valid
-;;; to call car with a null argument.) A better approach might
-;;; be to allow type-specification of the form
-;;; (put 'foo 'arg-types '(float (list integer) dynamic))
-;;; (put 'foo 'result-type 'bool)
-;;; It should be possible to have these types checked to a certain
-;;; degree.
-;;;
-;;; collapse common subexpressions
-;;;
-;;; It would be nice if redundant sequences could be factored out as well,
-;;; when they are known to have no side-effects:
-;;; (list (+ a b c) (+ a b c)) --> a b add c add dup list-2
-;;; but beware of traps like
-;;; (cons (list x y) (list x y))
-;;;
-;;; Tail-recursion elimination is not really possible in Emacs Lisp.
-;;; Tail-recursion elimination is almost always impossible when all variables
-;;; have dynamic scope, but given that the "return" byteop requires the
-;;; binding stack to be empty (rather than emptying it itself), there can be
-;;; no truly tail-recursive Emacs Lisp functions that take any arguments or
-;;; make any bindings.
-;;;
-;;; Here is an example of an Emacs Lisp function which could safely be
-;;; byte-compiled tail-recursively:
-;;;
-;;; (defun tail-map (fn list)
-;;; (cond (list
-;;; (funcall fn (car list))
-;;; (tail-map fn (cdr list)))))
-;;;
-;;; However, if there was even a single let-binding around the COND,
-;;; it could not be byte-compiled, because there would be an "unbind"
-;;; byte-op between the final "call" and "return." Adding a
-;;; Bunbind_all byteop would fix this.
-;;;
-;;; (defun foo (x y z) ... (foo a b c))
-;;; ... (const foo) (varref a) (varref b) (varref c) (call 3) END: (return)
-;;; ... (varref a) (varbind x) (varref b) (varbind y) (varref c) (varbind z) (goto 0) END: (unbind-all) (return)
-;;; ... (varref a) (varset x) (varref b) (varset y) (varref c) (varset z) (goto 0) END: (return)
-;;;
-;;; this also can be considered tail recursion:
-;;;
-;;; ... (const foo) (varref a) (call 1) (goto X) ... X: (return)
-;;; could generalize this by doing the optimization
-;;; (goto X) ... X: (return) --> (return)
-;;;
-;;; But this doesn't solve all of the problems: although by doing tail-
-;;; recursion elimination in this way, the call-stack does not grow, the
-;;; binding-stack would grow with each recursive step, and would eventually
-;;; overflow. I don't believe there is any way around this without lexical
-;;; scope.
-;;;
-;;; Wouldn't it be nice if Emacs Lisp had lexical scope.
-;;;
-;;; Idea: the form (lexical-scope) in a file means that the file may be
-;;; compiled lexically. This proclamation is file-local. Then, within
-;;; that file, "let" would establish lexical bindings, and "let-dynamic"
-;;; would do things the old way. (Or we could use CL "declare" forms.)
-;;; We'd have to notice defvars and defconsts, since those variables should
-;;; always be dynamic, and attempting to do a lexical binding of them
-;;; should simply do a dynamic binding instead.
-;;; But! We need to know about variables that were not necessarily defvarred
-;;; in the file being compiled (doing a boundp check isn't good enough.)
-;;; Fdefvar() would have to be modified to add something to the plist.
-;;;
-;;; A major disadvantage of this scheme is that the interpreter and compiler
-;;; would have different semantics for files compiled with (dynamic-scope).
-;;; Since this would be a file-local optimization, there would be no way to
-;;; modify the interpreter to obey this (unless the loader was hacked
-;;; in some grody way, but that's a really bad idea.)
+;; TO DO:
+;;
+;; (apply '(lambda (x &rest y) ...) 1 (foo))
+;;
+;; maintain a list of functions known not to access any global variables
+;; (actually, give them a 'dynamically-safe property) and then
+;; (let ( v1 v2 ... vM vN ) <...dynamically-safe...> ) ==>
+;; (let ( v1 v2 ... vM ) vN <...dynamically-safe...> )
+;; by recursing on this, we might be able to eliminate the entire let.
+;; However certain variables should never have their bindings optimized
+;; away, because they affect everything.
+;; (put 'debug-on-error 'binding-is-magic t)
+;; (put 'debug-on-abort 'binding-is-magic t)
+;; (put 'debug-on-next-call 'binding-is-magic t)
+;; (put 'mocklisp-arguments 'binding-is-magic t)
+;; (put 'inhibit-quit 'binding-is-magic t)
+;; (put 'quit-flag 'binding-is-magic t)
+;; (put 't 'binding-is-magic t)
+;; (put 'nil 'binding-is-magic t)
+;; possibly also
+;; (put 'gc-cons-threshold 'binding-is-magic t)
+;; (put 'track-mouse 'binding-is-magic t)
+;; others?
+;;
+;; Simple defsubsts often produce forms like
+;; (let ((v1 (f1)) (v2 (f2)) ...)
+;; (FN v1 v2 ...))
+;; It would be nice if we could optimize this to
+;; (FN (f1) (f2) ...)
+;; but we can't unless FN is dynamically-safe (it might be dynamically
+;; referring to the bindings that the lambda arglist established.)
+;; One of the uncountable lossages introduced by dynamic scope...
+;;
+;; Maybe there should be a control-structure that says "turn on
+;; fast-and-loose type-assumptive optimizations here." Then when
+;; we see a form like (car foo) we can from then on assume that
+;; the variable foo is of type cons, and optimize based on that.
+;; But, this won't win much because of (you guessed it) dynamic
+;; scope. Anything down the stack could change the value.
+;; (Another reason it doesn't work is that it is perfectly valid
+;; to call car with a null argument.) A better approach might
+;; be to allow type-specification of the form
+;; (put 'foo 'arg-types '(float (list integer) dynamic))
+;; (put 'foo 'result-type 'bool)
+;; It should be possible to have these types checked to a certain
+;; degree.
+;;
+;; collapse common subexpressions
+;;
+;; It would be nice if redundant sequences could be factored out as well,
+;; when they are known to have no side-effects:
+;; (list (+ a b c) (+ a b c)) --> a b add c add dup list-2
+;; but beware of traps like
+;; (cons (list x y) (list x y))
+;;
+;; Tail-recursion elimination is not really possible in Emacs Lisp.
+;; Tail-recursion elimination is almost always impossible when all variables
+;; have dynamic scope, but given that the "return" byteop requires the
+;; binding stack to be empty (rather than emptying it itself), there can be
+;; no truly tail-recursive Emacs Lisp functions that take any arguments or
+;; make any bindings.
+;;
+;; Here is an example of an Emacs Lisp function which could safely be
+;; byte-compiled tail-recursively:
+;;
+;; (defun tail-map (fn list)
+;; (cond (list
+;; (funcall fn (car list))
+;; (tail-map fn (cdr list)))))
+;;
+;; However, if there was even a single let-binding around the COND,
+;; it could not be byte-compiled, because there would be an "unbind"
+;; byte-op between the final "call" and "return." Adding a
+;; Bunbind_all byteop would fix this.
+;;
+;; (defun foo (x y z) ... (foo a b c))
+;; ... (const foo) (varref a) (varref b) (varref c) (call 3) END: (return)
+;; ... (varref a) (varbind x) (varref b) (varbind y) (varref c) (varbind z) (goto 0) END: (unbind-all) (return)
+;; ... (varref a) (varset x) (varref b) (varset y) (varref c) (varset z) (goto 0) END: (return)
+;;
+;; this also can be considered tail recursion:
+;;
+;; ... (const foo) (varref a) (call 1) (goto X) ... X: (return)
+;; could generalize this by doing the optimization
+;; (goto X) ... X: (return) --> (return)
+;;
+;; But this doesn't solve all of the problems: although by doing tail-
+;; recursion elimination in this way, the call-stack does not grow, the
+;; binding-stack would grow with each recursive step, and would eventually
+;; overflow. I don't believe there is any way around this without lexical
+;; scope.
+;;
+;; Wouldn't it be nice if Emacs Lisp had lexical scope.
+;;
+;; Idea: the form (lexical-scope) in a file means that the file may be
+;; compiled lexically. This proclamation is file-local. Then, within
+;; that file, "let" would establish lexical bindings, and "let-dynamic"
+;; would do things the old way. (Or we could use CL "declare" forms.)
+;; We'd have to notice defvars and defconsts, since those variables should
+;; always be dynamic, and attempting to do a lexical binding of them
+;; should simply do a dynamic binding instead.
+;; But! We need to know about variables that were not necessarily defvarred
+;; in the file being compiled (doing a boundp check isn't good enough.)
+;; Fdefvar() would have to be modified to add something to the plist.
+;;
+;; A major disadvantage of this scheme is that the interpreter and compiler
+;; would have different semantics for files compiled with (dynamic-scope).
+;; Since this would be a file-local optimization, there would be no way to
+;; modify the interpreter to obey this (unless the loader was hacked
+;; in some grody way, but that's a really bad idea.)
;; Other things to consider:
;;; bytecomp.el --- compilation of Lisp code into byte code.
-;;; Copyright (C) 1985, 1986, 1987, 1992, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1986, 1987, 1992, 1994 Free Software Foundation, Inc.
;; Author: Jamie Zawinski <jwz@lucid.com>
;; Hallvard Furuseth <hbf@ulrik.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Code:
-;;; ========================================================================
-;;; Entry points:
-;;; byte-recompile-directory, byte-compile-file,
-;;; batch-byte-compile, batch-byte-recompile-directory,
-;;; byte-compile, compile-defun,
-;;; display-call-tree
-;;; (byte-compile-buffer and byte-compile-and-load-file were turned off
-;;; because they are not terribly useful and get in the way of completion.)
-
-;;; This version of the byte compiler has the following improvements:
-;;; + optimization of compiled code:
-;;; - removal of unreachable code;
-;;; - removal of calls to side-effectless functions whose return-value
-;;; is unused;
-;;; - compile-time evaluation of safe constant forms, such as (consp nil)
-;;; and (ash 1 6);
-;;; - open-coding of literal lambdas;
-;;; - peephole optimization of emitted code;
-;;; - trivial functions are left uncompiled for speed.
-;;; + support for inline functions;
-;;; + compile-time evaluation of arbitrary expressions;
-;;; + compile-time warning messages for:
-;;; - functions being redefined with incompatible arglists;
-;;; - functions being redefined as macros, or vice-versa;
-;;; - functions or macros defined multiple times in the same file;
-;;; - functions being called with the incorrect number of arguments;
-;;; - functions being called which are not defined globally, in the
-;;; file, or as autoloads;
-;;; - assignment and reference of undeclared free variables;
-;;; - various syntax errors;
-;;; + correct compilation of nested defuns, defmacros, defvars and defsubsts;
-;;; + correct compilation of top-level uses of macros;
-;;; + the ability to generate a histogram of functions called.
-
-;;; User customization variables:
-;;;
-;;; byte-compile-verbose Whether to report the function currently being
-;;; compiled in the minibuffer;
-;;; byte-optimize Whether to do optimizations; this may be
-;;; t, nil, 'source, or 'byte;
-;;; byte-optimize-log Whether to report (in excruciating detail)
-;;; exactly which optimizations have been made.
-;;; This may be t, nil, 'source, or 'byte;
-;;; byte-compile-error-on-warn Whether to stop compilation when a warning is
-;;; produced;
-;;; byte-compile-delete-errors Whether the optimizer may delete calls or
-;;; variable references that are side-effect-free
-;;; except that they may return an error.
-;;; byte-compile-generate-call-tree Whether to generate a histogram of
-;;; function calls. This can be useful for
-;;; finding unused functions, as well as simple
-;;; performance metering.
-;;; byte-compile-warnings List of warnings to issue, or t. May contain
-;;; 'free-vars (references to variables not in the
-;;; current lexical scope)
-;;; 'unresolved (calls to unknown functions)
-;;; 'callargs (lambda calls with args that don't
-;;; match the lambda's definition)
-;;; 'redefine (function cell redefined from
-;;; a macro to a lambda or vice versa,
-;;; or redefined to take other args)
-;;; 'obsolete (obsolete variables and functions)
-;;; byte-compile-compatibility Whether the compiler should
-;;; generate .elc files which can be loaded into
-;;; generic emacs 18.
-;;; emacs-lisp-file-regexp Regexp for the extension of source-files;
-;;; see also the function byte-compile-dest-file.
-
-;;; New Features:
-;;;
-;;; o The form `defsubst' is just like `defun', except that the function
-;;; generated will be open-coded in compiled code which uses it. This
-;;; means that no function call will be generated, it will simply be
-;;; spliced in. Lisp functions calls are very slow, so this can be a
-;;; big win.
-;;;
-;;; You can generally accomplish the same thing with `defmacro', but in
-;;; that case, the defined procedure can't be used as an argument to
-;;; mapcar, etc.
-;;;
-;;; o You can also open-code one particular call to a function without
-;;; open-coding all calls. Use the 'inline' form to do this, like so:
-;;;
-;;; (inline (foo 1 2 3)) ;; `foo' will be open-coded
-;;; or...
-;;; (inline ;; `foo' and `baz' will be
-;;; (foo 1 2 3 (bar 5)) ;; open-coded, but `bar' will not.
-;;; (baz 0))
-;;;
-;;; o It is possible to open-code a function in the same file it is defined
-;;; in without having to load that file before compiling it. the
-;;; byte-compiler has been modified to remember function definitions in
-;;; the compilation environment in the same way that it remembers macro
-;;; definitions.
-;;;
-;;; o Forms like ((lambda ...) ...) are open-coded.
-;;;
-;;; o The form `eval-when-compile' is like progn, except that the body
-;;; is evaluated at compile-time. When it appears at top-level, this
-;;; is analogous to the Common Lisp idiom (eval-when (compile) ...).
-;;; When it does not appear at top-level, it is similar to the
-;;; Common Lisp #. reader macro (but not in interpreted code).
-;;;
-;;; o The form `eval-and-compile' is similar to eval-when-compile, but
-;;; the whole form is evalled both at compile-time and at run-time.
-;;;
-;;; o The command compile-defun is analogous to eval-defun.
-;;;
-;;; o If you run byte-compile-file on a filename which is visited in a
-;;; buffer, and that buffer is modified, you are asked whether you want
-;;; to save the buffer before compiling.
-;;;
-;;; o byte-compiled files now start with the string `;ELC'.
-;;; Some versions of `file' can be customized to recognize that.
+;; ========================================================================
+;; Entry points:
+;; byte-recompile-directory, byte-compile-file,
+;; batch-byte-compile, batch-byte-recompile-directory,
+;; byte-compile, compile-defun,
+;; display-call-tree
+;; (byte-compile-buffer and byte-compile-and-load-file were turned off
+;; because they are not terribly useful and get in the way of completion.)
+
+;; This version of the byte compiler has the following improvements:
+;; + optimization of compiled code:
+;; - removal of unreachable code;
+;; - removal of calls to side-effectless functions whose return-value
+;; is unused;
+;; - compile-time evaluation of safe constant forms, such as (consp nil)
+;; and (ash 1 6);
+;; - open-coding of literal lambdas;
+;; - peephole optimization of emitted code;
+;; - trivial functions are left uncompiled for speed.
+;; + support for inline functions;
+;; + compile-time evaluation of arbitrary expressions;
+;; + compile-time warning messages for:
+;; - functions being redefined with incompatible arglists;
+;; - functions being redefined as macros, or vice-versa;
+;; - functions or macros defined multiple times in the same file;
+;; - functions being called with the incorrect number of arguments;
+;; - functions being called which are not defined globally, in the
+;; file, or as autoloads;
+;; - assignment and reference of undeclared free variables;
+;; - various syntax errors;
+;; + correct compilation of nested defuns, defmacros, defvars and defsubsts;
+;; + correct compilation of top-level uses of macros;
+;; + the ability to generate a histogram of functions called.
+
+;; User customization variables:
+;;
+;; byte-compile-verbose Whether to report the function currently being
+;; compiled in the minibuffer;
+;; byte-optimize Whether to do optimizations; this may be
+;; t, nil, 'source, or 'byte;
+;; byte-optimize-log Whether to report (in excruciating detail)
+;; exactly which optimizations have been made.
+;; This may be t, nil, 'source, or 'byte;
+;; byte-compile-error-on-warn Whether to stop compilation when a warning is
+;; produced;
+;; byte-compile-delete-errors Whether the optimizer may delete calls or
+;; variable references that are side-effect-free
+;; except that they may return an error.
+;; byte-compile-generate-call-tree Whether to generate a histogram of
+;; function calls. This can be useful for
+;; finding unused functions, as well as simple
+;; performance metering.
+;; byte-compile-warnings List of warnings to issue, or t. May contain
+;; 'free-vars (references to variables not in the
+;; current lexical scope)
+;; 'unresolved (calls to unknown functions)
+;; 'callargs (lambda calls with args that don't
+;; match the lambda's definition)
+;; 'redefine (function cell redefined from
+;; a macro to a lambda or vice versa,
+;; or redefined to take other args)
+;; 'obsolete (obsolete variables and functions)
+;; byte-compile-compatibility Whether the compiler should
+;; generate .elc files which can be loaded into
+;; generic emacs 18.
+;; emacs-lisp-file-regexp Regexp for the extension of source-files;
+;; see also the function byte-compile-dest-file.
+
+;; New Features:
+;;
+;; o The form `defsubst' is just like `defun', except that the function
+;; generated will be open-coded in compiled code which uses it. This
+;; means that no function call will be generated, it will simply be
+;; spliced in. Lisp functions calls are very slow, so this can be a
+;; big win.
+;;
+;; You can generally accomplish the same thing with `defmacro', but in
+;; that case, the defined procedure can't be used as an argument to
+;; mapcar, etc.
+;;
+;; o You can also open-code one particular call to a function without
+;; open-coding all calls. Use the 'inline' form to do this, like so:
+;;
+;; (inline (foo 1 2 3)) ;; `foo' will be open-coded
+;; or...
+;; (inline ;; `foo' and `baz' will be
+;; (foo 1 2 3 (bar 5)) ;; open-coded, but `bar' will not.
+;; (baz 0))
+;;
+;; o It is possible to open-code a function in the same file it is defined
+;; in without having to load that file before compiling it. the
+;; byte-compiler has been modified to remember function definitions in
+;; the compilation environment in the same way that it remembers macro
+;; definitions.
+;;
+;; o Forms like ((lambda ...) ...) are open-coded.
+;;
+;; o The form `eval-when-compile' is like progn, except that the body
+;; is evaluated at compile-time. When it appears at top-level, this
+;; is analogous to the Common Lisp idiom (eval-when (compile) ...).
+;; When it does not appear at top-level, it is similar to the
+;; Common Lisp #. reader macro (but not in interpreted code).
+;;
+;; o The form `eval-and-compile' is similar to eval-when-compile, but
+;; the whole form is evalled both at compile-time and at run-time.
+;;
+;; o The command compile-defun is analogous to eval-defun.
+;;
+;; o If you run byte-compile-file on a filename which is visited in a
+;; buffer, and that buffer is modified, you are asked whether you want
+;; to save the buffer before compiling.
+;;
+;; o byte-compiled files now start with the string `;ELC'.
+;; Some versions of `file' can be customized to recognize that.
(require 'backquote)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; LCD Archive Entry:
;; cl-specs.el|Daniel LaLiberte|liberte@cs.uiuc.edu
;; |Edebug specs for cl.el
-;; |$Date: 1995/10/30 16:51:55 $|1.1|
+;; |$Date: 1996/01/05 21:56:25 $|1.1|
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; disass.el --- disassembler for compiled Emacs Lisp code
-;;; Copyright (C) 1986, 1991 Free Software Foundation, Inc.
+;; Copyright (C) 1986, 1991 Free Software Foundation, Inc.
;; Author: Doug Cutting <doug@csli.stanford.edu>
;; Jamie Zawinski <jwz@lucid.com>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
-;;; This is compatible with easymenu.el by Per Abrahamsen
-;;; but it is much simpler as it doesn't try to support other Emacs versions.
-;;; The code was mostly derived from lmenu.el.
+;;; Commentary:
+
+;; This is compatible with easymenu.el by Per Abrahamsen
+;; but it is much simpler as it doesn't try to support other Emacs versions.
+;; The code was mostly derived from lmenu.el.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;
;;; eval-reg.el --- Redefine eval-region, and subrs that use it, in Lisp
-;; Copyright (C) 1994 Daniel LaLiberte
+;; Copyright (C) 1994, 1996 Daniel LaLiberte
;; Author: Daniel LaLiberte <liberte@cs.uiuc.edu>
;; Keywords: lisp
;; along with GNU Emacs; see the file COPYING. If not, write to
;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-;;;; Commentary:
+;;; Commentary:
-;;; eval-region, eval-buffer, and eval-current-buffer are redefined in
-;;; Lisp to allow customizations by Lisp code. eval-region calls
-;;; `read', `eval', and `prin1', so Lisp replacements of these
-;;; functions will affect eval-region and anything else that calls it.
-;;; eval-buffer and eval-current-buffer are redefined in Lisp to call
-;;; eval-region on the buffer.
+;; eval-region, eval-buffer, and eval-current-buffer are redefined in
+;; Lisp to allow customizations by Lisp code. eval-region calls
+;; `read', `eval', and `prin1', so Lisp replacements of these
+;; functions will affect eval-region and anything else that calls it.
+;; eval-buffer and eval-current-buffer are redefined in Lisp to call
+;; eval-region on the buffer.
-;;; Because of dynamic binding, all local variables are protected from
-;;; being seen by eval by giving them funky names. But variables in
-;;; routines that call eval-region are similarly exposed.
+;; Because of dynamic binding, all local variables are protected from
+;; being seen by eval by giving them funky names. But variables in
+;; routines that call eval-region are similarly exposed.
-;;; Perhaps this should be one of several files in an `elisp' package
-;;; that replaces Emacs Lisp subroutines with Lisp versions of the
-;;; same.
+;; Perhaps this should be one of several files in an `elisp' package
+;; that replaces Emacs Lisp subroutines with Lisp versions of the
+;; same.
-;;; Eval-region may be installed, after loading, by calling:
-;;; (elisp-eval-region-install). Installation can be undone with:
-;;; (elisp-eval-region-uninstall).
+;; Eval-region may be installed, after loading, by calling:
+;; (elisp-eval-region-install). Installation can be undone with:
+;; (elisp-eval-region-uninstall).
+
+;;; Code:
'(defpackage "elisp-eval-region"
(:nicknames "elisp")
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
-; hey, here's a helping hand.
+;; hey, here's a helping hand.
;; Bind this to a string for <blank> in "... Other keys <blank>".
;; Helper-help uses this to construct help string when scrolling.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Author: Eric S. Raymond <esr@snark.thyrsus.com>
;; Maintainer: Eric S. Raymond <esr@snark.thyrsus.com>
;; Created: 14 Jul 1992
-;; Version: $Id: lisp-mnt.el,v 1.10 1995/03/16 04:37:48 rms Exp kwzh $
+;; Version: $Id: lisp-mnt.el,v 1.11 1995/06/15 20:42:24 kwzh Exp erik $
;; Keywords: docs
;; X-Bogus-Bureaucratic-Cruft: Gruad will get you if you don't watch out!
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; lmenu.el --- emulate Lucid's menubar support
-;; Keywords: emulations
-
;; Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
+;; Keywords: emulations
+
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; lselect.el --- Lucid interface to X Selections
+;; Copyright (C) 1990, 1993 Free Software Foundation, Inc.
+
;; Keywords: emulations
;; This won't completely work until we support or emulate Lucid-style extents.
-;; Copyright (C) 1990, 1993 Free Software Foundation, Inc.
;; Based on Lucid's selection code.
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; lucid.el --- Emulate some Lucid Emacs functions.
+
;; Copyright (C) 1993, 1995 Free Software Foundation, Inc.
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+;;; Code:
(defun add-timeout (secs function object &optional resignal)
(run-at-time secs resignal function object))
;;; pp.el --- pretty printer for Emacs Lisp
+
;; Copyright (C) 1989, 1993 Free Software Foundation, Inc.
;; Author: Randal Schwartz <merlyn@ora.com>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-; DESCRIPTION:
-; ------------
-; This program can be used to monitor running time performance of Emacs Lisp
-; functions. It takes a list of functions and report the real time spent
-; inside these functions. It runs a process with a separate timer program.
-; Caveat: the C code in ../lib-src/profile.c requires BSD-compatible
-; time-of-day functions. If you're running an AT&T version prior to SVr4,
-; you may have difficulty getting it to work. Your X library may supply
-; the required routines if the standard C library does not.
-
-; HOW TO USE:
-; -----------
-; Set the variable profile-functions-list to the list of functions
-; (as symbols) You want to profile. Call M-x profile-functions to set
-; this list on and start using your program. Note that profile-functions
-; MUST be called AFTER all the functions in profile-functions-list have
-; been loaded !! (This call modifies the code of the profiled functions.
-; Hence if you reload these functions, you need to call profile-functions
-; again! ).
-; To display the results do M-x profile-results . For example:
-;-------------------------------------------------------------------
-; (setq profile-functions-list '(sokoban-set-mode-line sokoban-load-game
-; sokoban-move-vertical sokoban-move))
-; (load "sokoban")
-; M-x profile-functions
-; ... I play the sokoban game ..........
-; M-x profile-results
-;
-; Function Time (Seconds.Useconds)
-; ======== =======================
-; sokoban-move 0.539088
-; sokoban-move-vertical 0.410130
-; sokoban-load-game 0.453235
-; sokoban-set-mode-line 1.949203
-;-----------------------------------------------------
-; To clear all the settings to profile use profile-finish.
-; To set one function at a time (instead of or in addition to setting the
-; above list and M-x profile-functions) use M-x profile-a-function.
+;; DESCRIPTION:
+;; ------------
+;; This program can be used to monitor running time performance of Emacs Lisp
+;; functions. It takes a list of functions and report the real time spent
+;; inside these functions. It runs a process with a separate timer program.
+;; Caveat: the C code in ../lib-src/profile.c requires BSD-compatible
+;; time-of-day functions. If you're running an AT&T version prior to SVr4,
+;; you may have difficulty getting it to work. Your X library may supply
+;; the required routines if the standard C library does not.
+
+;; HOW TO USE:
+;; -----------
+;; Set the variable profile-functions-list to the list of functions
+;; (as symbols) You want to profile. Call M-x profile-functions to set
+;; this list on and start using your program. Note that profile-functions
+;; MUST be called AFTER all the functions in profile-functions-list have
+;; been loaded !! (This call modifies the code of the profiled functions.
+;; Hence if you reload these functions, you need to call profile-functions
+;; again! ).
+;; To display the results do M-x profile-results . For example:
+;;-------------------------------------------------------------------
+;; (setq profile-functions-list '(sokoban-set-mode-line sokoban-load-game
+;; sokoban-move-vertical sokoban-move))
+;; (load "sokoban")
+;; M-x profile-functions
+;; ... I play the sokoban game ..........
+;; M-x profile-results
+;;
+;; Function Time (Seconds.Useconds)
+;; ======== =======================
+;; sokoban-move 0.539088
+;; sokoban-move-vertical 0.410130
+;; sokoban-load-game 0.453235
+;; sokoban-set-mode-line 1.949203
+;;-----------------------------------------------------
+;; To clear all the settings to profile use profile-finish.
+;; To set one function at a time (instead of or in addition to setting the
+;; above list and M-x profile-functions) use M-x profile-a-function.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This code defines a ring data structure. A ring is a
-;;; (hd-index length . vector)
-;;; list. You can insert to, remove from, and rotate a ring. When the ring
-;;; fills up, insertions cause the oldest elts to be quietly dropped.
-;;;
-;;; In ring-ref, 0 is the index of the newest element. Higher indexes
-;;; correspond to older elements until they wrap.
-;;;
-;;; hd-index = index of the newest item on the ring.
-;;; length = number of ring items.
-;;;
-;;; These functions are used by the input history mechanism, but they can
-;;; be used for other purposes as well.
+;; This code defines a ring data structure. A ring is a
+;; (hd-index length . vector)
+;; list. You can insert to, remove from, and rotate a ring. When the ring
+;; fills up, insertions cause the oldest elts to be quietly dropped.
+;;
+;; In ring-ref, 0 is the index of the newest element. Higher indexes
+;; correspond to older elements until they wrap.
+;;
+;; hd-index = index of the newest item on the ring.
+;; length = number of ring items.
+;;
+;; These functions are used by the input history mechanism, but they can
+;; be used for other purposes as well.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; The functions in this file detect (`find-emacs-lisp-shadows')
;; and display (`list-load-path-shadows') potential load-path
;; problems that arise when Emacs Lisp files "shadow" each other.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; LCD Archive Entry:
;; trace|Hans Chalupsky|hans@cs.buffalo.edu|
;;; emacs-lock.el --- prevents you from exiting emacs if a buffer is locked
+
;; Copyright (C) 1994 Free Software Foundation, Inc
-;;
+
;; Author: Tom Wurgler <twurgler@goodyear.com>
;; Created: 12/8/94
;; Version: 1.3
;; Keywords:
-;;
-;; This program is free software; you can redistribute it and/or modify
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2 of the License, or
-;; (at your option) any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; This code sets a buffer-local variable to t if toggle-emacs-lock is run,
;; then if the user attempts to exit emacs, the locked buffer name will be
;; displayed and the exit aborted. This is just a way of protecting
;; accidentally exit emacs. To unlock the buffer, just goto the buffer and
;; run toggle-emacs-lock again.
+;;; Code:
+
(defvar lock-emacs-from-exiting nil
"Whether emacs is locked to prevent exiting. See `check-emacs-lock'.")
(make-variable-buffer-local 'lock-emacs-from-exiting)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Usage:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Usage:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Usage:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Usage:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; pc-mode.el emulate certain key bindings used on PCs.
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Keywords: emulations
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
+
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+;;; Code:
;;;###autoload
(defun pc-bindings-mode ()
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; This package emulates the mark, copy, cut and paste look-and-feel of motif
;; programs (which is the same as the MAC gui and (sorry for that) MS-Windows).
;; It modifies the keybindings of the cursor keys and the next, prior,
;; They will be bound according to the "old" behaviour to S-delete (cut),
;; S-insert (paste) and C-insert (copy). These keys do the same in many
;; other programs.
-;;
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-;;;;
-;;;; INSTALLATION:
-;;;; o Put this file called "pc-select.el" into a path where emacs
-;;;; looks for lisp libraries. Byte-compile if you want to.
-;;;; o Put the command '(require 'pc-select) or
-;;;; '(load "pc-select")' into your ~/.emacs. After that line
-;;;; put the command '(pc-selection-mode)' to activate the mode.
-;;;;
-;;;; Please note that I am _not_ a lisp expert, I apologise for
-;;;; all hacks which look ugly to an experienced lisp programmer.
-;;;; Please report all errors and improvement. Thank you.
-;;;;
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-;;;; Code:
+;;; Code:
;;;;
;; misc
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; TPU-edt is based on tpu.el by Jeff Kowalski and Bob Covey.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Version: 3.5
;; Keywords: emulations
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
;;; Commentary:
;; A full-featured vi(1) emulator.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
(require 'viper-util)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
(require 'viper-util)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
(require 'viper-util)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
(require 'viper-util)
;;; viper-util.el --- Utilities used by viper.el
+
;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
(require 'ring)
;; a VI Plan for Emacs Rescue,
;; and a venomous VI PERil.
;; Viper Is also a Package for Emacs Rebels.
-;;
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
;; Keywords: emulations
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
(defconst viper-version "2.82 of October 12, 1995"
"The current version of Viper")
-;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
-
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; enriched.el --- read and save files in text/enriched format
+
;; Copyright (c) 1994, 1995 Free Software Foundation, Inc.
;; Author: Boris Goldowsky <boris@gnu.ai.mit.edu>
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
+
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; This file implements reading, editing, and saving files with
-;; text-properties such as faces, levels of indentation, and true line breaks
-;; distinguished from newlines just used to fit text into the window.
-;;
+;; text-properties such as faces, levels of indentation, and true line
+;; breaks distinguished from newlines just used to fit text into the window.
+
;; The file format used is the MIME text/enriched format, which is a
-;; standard format defined in internet RFC 1563. All standard annotations are
-;; supported except for <smaller> and <bigger>, which are currently not
+;; standard format defined in internet RFC 1563. All standard annotations
+;; are supported except for <smaller> and <bigger>, which are currently not
;; possible to display.
-;;
+
;; A separate file, enriched.doc, contains further documentation and other
-;; important information about this code. It also serves as an example file
-;; in text/enriched format. It should be in the etc directory of your emacs
-;; distribution.
+;; important information about this code. It also serves as an example
+;; file in text/enriched format. It should be in the etc directory of your
+;; emacs distribution.
+
+;;; Code:
(provide 'enriched)
(if window-system (require 'facemenu))
;;; env.el --- functions to manipulate environment variables.
-;;; Copyright 1991, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1991, 1994 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: processes, unix
-;;; This file is part of GNU Emacs.
+;; This file is part of GNU Emacs.
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;; UNIX processes inherit a list of name-to-string associations from
-;; their parents called their `environment'; these are commonly used
-;; to control program options. This package permits you to set
-;; environment variables to be passed to any sub-process run under Emacs.
+;; UNIX processes inherit a list of name-to-string associations from their
+;; parents called their `environment'; these are commonly used to control
+;; program options. This package permits you to set environment variables
+;; to be passed to any sub-process run under Emacs.
;;; Code:
;;; facemenu.el --- create a face menu for interactively adding fonts to text
+
;; Copyright (c) 1994, 1995, 1996 Free Software Foundation, Inc.
;; Author: Boris Goldowsky <boris@gnu.ai.mit.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
+
;; This file defines a menu of faces (bold, italic, etc) which allows you to
;; set the face used for a region of the buffer. Some faces also have
;; keybindings, which are shown in the menu. Faces with names beginning with
;;; faces.el --- Lisp interface to the c "face" structure
-;; Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1992, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; fast-lock.el --- Automagic text properties caching for fast Font Lock mode.
-;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
;; Author: Simon Marshall <simon@gnu.ai.mit.edu>
;; Keywords: faces files
;; Version: 3.08
-;;; This file is part of GNU Emacs.
+;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; ffap.el -- find-file-at-point,
-;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
-;;; Author: Michelangelo Grigni <mic@mathcs.emory.edu>
+;; Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+
+;; Author: Michelangelo Grigni <mic@mathcs.emory.edu>
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; find-dired.el --- run a `find' command and dired the output
-;;; Copyright (C) 1992, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1992, 1994, 1995 Free Software Foundation, Inc.
;; Author: Roland McGrath <roland@gnu.ai.mit.edu>,
;; Sebastian Kremer <sk@thp.uni-koeln.de>
;; Keywords: unix
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; This program is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; A copy of the GNU General Public License can be obtained from this
-;;; program's author (send electronic mail to roland@ai.mit.edu) or from
-;;; the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA
-;;; 02139, USA.
-;;;
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
-;;; This file is part of GNU Emacs.
-
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Produce in unsafe-list the set of all functions that may invoke GC.
-;;; This expects the Emacs sources to live in emacs-source-directory.
-;;; It creates a temporary working directory /tmp/esrc.
+;; Produce in unsafe-list the set of all functions that may invoke GC.
+;; This expects the Emacs sources to live in emacs-source-directory.
+;; It creates a temporary working directory /tmp/esrc.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; flow-ctrl.el --- help for lusers on cu(1) or ttys with wired-in ^S/^Q flow control
-;;; Copyright (C) 1990, 1991, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1990, 1991, 1994 Free Software Foundation, Inc.
;; Author Kevin Gallagher
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;;; Terminals that use XON/XOFF flow control can cause problems with
-;;;; GNU Emacs users. This file contains Emacs Lisp code that makes it
-;;;; easy for a user to deal with this problem, when using such a
-;;;; terminal.
-;;;;
-;;;; To invoke these adjustments, a user need only invoke the function
-;;;; enable-flow-control-on with a list of terminal types in his/her own
-;;;; .emacs file. As arguments, give it the names of one or more terminal
-;;;; types in use by that user which require flow control adjustments.
-;;;; Here's an example:
-;;;;
-;;;; (enable-flow-control-on "vt200" "vt300" "vt101" "vt131")
-
-;;; Portability note: This uses (getenv "TERM"), and therefore probably
-;;; won't work outside of UNIX-like environments.
+;; Terminals that use XON/XOFF flow control can cause problems with
+;; GNU Emacs users. This file contains Emacs Lisp code that makes it
+;; easy for a user to deal with this problem, when using such a
+;; terminal.
+;;
+;; To invoke these adjustments, a user need only invoke the function
+;; enable-flow-control-on with a list of terminal types in his/her own
+;; .emacs file. As arguments, give it the names of one or more terminal
+;; types in use by that user which require flow control adjustments.
+;; Here's an example:
+;;
+;; (enable-flow-control-on "vt200" "vt300" "vt101" "vt131")
+
+;; Portability note: This uses (getenv "TERM"), and therefore probably
+;; won't work outside of UNIX-like environments.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; format.el --- read and save files in multiple formats
+
;; Copyright (c) 1994, 1995 Free Software Foundation
;; Author: Boris Goldowsky <boris@gnu.ai.mit.edu>
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
+
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;; This file defines a unified mechanism for saving & loading files stored in
-;; different formats. `format-alist' contains information that directs
+
+;; This file defines a unified mechanism for saving & loading files stored
+;; in different formats. `format-alist' contains information that directs
;; Emacs to call an encoding or decoding function when reading or writing
;; files that match certain conditions.
;;
-;; When a file is visited, its format is determined by matching the beginning
-;; of the file against regular expressions stored in `format-alist'. If this
-;; fails, you can manually translate the buffer using `format-decode-buffer'.
-;; In either case, the formats used are listed in the variable
-;; `buffer-file-format', and become the default format for saving the buffer.
-;; To save a buffer in a different format, change this variable, or use
-;; `format-write-file'.
+;; When a file is visited, its format is determined by matching the
+;; beginning of the file against regular expressions stored in
+;; `format-alist'. If this fails, you can manually translate the buffer
+;; using `format-decode-buffer'. In either case, the formats used are
+;; listed in the variable `buffer-file-format', and become the default
+;; format for saving the buffer. To save a buffer in a different format,
+;; change this variable, or use `format-write-file'.
;;
;; Auto-save files are normally created in the same format as the visited
-;; file, but the variable `auto-save-file-format' can be set to a particularly
-;; fast or otherwise preferred format to be used for auto-saving (or nil to do
-;; no encoding on auto-save files, but then you risk losing any
-;; text-properties in the buffer).
+;; file, but the variable `auto-save-file-format' can be set to a
+;; particularly fast or otherwise preferred format to be used for
+;; auto-saving (or nil to do no encoding on auto-save files, but then you
+;; risk losing any text-properties in the buffer).
;;
-;; You can manually translate a buffer into or out of a particular format with
-;; the functions `format-encode-buffer' and `format-decode-buffer'.
-;; To translate just the region use the functions `format-encode-region' and
-;; `format-decode-region'.
+;; You can manually translate a buffer into or out of a particular format
+;; with the functions `format-encode-buffer' and `format-decode-buffer'.
+;; To translate just the region use the functions `format-encode-region'
+;; and `format-decode-region'.
;;
-;; You can define a new format by writing the encoding and decoding functions,
-;; and adding an entry to `format-alist'. See enriched.el for an example of
-;; how to implement a file format. There are various functions defined
-;; in this file that may be useful for writing the encoding and decoding
-;; functions:
-;; * `format-annotate-region' and `format-deannotate-region' allow a single
-;; alist of information to be used for encoding and decoding. The alist
-;; defines a correspondence between strings in the file ("annotations")
-;; and text-properties in the buffer.
+;; You can define a new format by writing the encoding and decoding
+;; functions, and adding an entry to `format-alist'. See enriched.el for
+;; an example of how to implement a file format. There are various
+;; functions defined in this file that may be useful for writing the
+;; encoding and decoding functions:
+;; * `format-annotate-region' and `format-deannotate-region' allow a
+;; single alist of information to be used for encoding and decoding.
+;; The alist defines a correspondence between strings in the file
+;; ("annotations") and text-properties in the buffer.
;; * `format-replace-strings' is similarly useful for doing simple
;; string->string translations in a reversible manner.
+;;; Code:
+
(put 'buffer-file-format 'permanent-local t)
(defconst format-alist
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Visit a file using a form.
-;;;
-;;; === Naming conventions
-;;;
-;;; The names of all variables and functions start with 'forms-'.
-;;; Names which start with 'forms--' are intended for internal use, and
-;;; should *NOT* be used from the outside.
-;;;
-;;; All variables are buffer-local, to enable multiple forms visits
-;;; simultaneously.
-;;; Variable `forms--mode-setup' is local to *ALL* buffers, for it
-;;; controls if forms-mode has been enabled in a buffer.
-;;;
-;;; === How it works ===
-;;;
-;;; Forms mode means visiting a data file which is supposed to consist
-;;; of records each containing a number of fields. The records are
-;;; separated by a newline, the fields are separated by a user-defined
-;;; field separator (default: TAB).
-;;; When shown, a record is transferred to an Emacs buffer and
-;;; presented using a user-defined form. One record is shown at a
-;;; time.
-;;;
-;;; Forms mode is a composite mode. It involves two files, and two
-;;; buffers.
-;;; The first file, called the control file, defines the name of the
-;;; data file and the forms format. This file buffer will be used to
-;;; present the forms.
-;;; The second file holds the actual data. The buffer of this file
-;;; will be buried, for it is never accessed directly.
-;;;
-;;; Forms mode is invoked using M-x forms-find-file control-file .
-;;; Alternatively `forms-find-file-other-window' can be used.
-;;;
-;;; You may also visit the control file, and switch to forms mode by hand
-;;; with M-x forms-mode .
-;;;
-;;; Automatic mode switching is supported if you specify
-;;; "-*- forms -*-" in the first line of the control file.
-;;;
-;;; The control file is visited, evaluated using `eval-current-buffer',
-;;; and should set at least the following variables:
-;;;
-;;; forms-file [string]
-;;; The name of the data file.
-;;;
-;;; forms-number-of-fields [integer]
-;;; The number of fields in each record.
-;;;
-;;; forms-format-list [list]
-;;; Formatting instructions.
-;;;
-;;; `forms-format-list' should be a list, each element containing
-;;;
-;;; - a string, e.g. "hello". The string is inserted in the forms
-;;; "as is".
-;;;
-;;; - an integer, denoting a field number.
-;;; The contents of this field are inserted at this point.
-;;; Fields are numbered starting with number one.
-;;;
-;;; - a function call, e.g. (insert "text").
-;;; This function call is dynamically evaluated and should return a
-;;; string. It should *NOT* have side-effects on the forms being
-;;; constructed. The current fields are available to the function
-;;; in the variable `forms-fields', they should *NOT* be modified.
-;;;
-;;; - a lisp symbol, that must evaluate to one of the above.
-;;;
-;;; Optional variables which may be set in the control file:
-;;;
-;;; forms-field-sep [string, default TAB]
-;;; The field separator used to separate the
-;;; fields in the data file. It may be a string.
-;;;
-;;; forms-read-only [bool, default nil]
-;;; Non-nil means that the data file is visited
-;;; read-only (view mode) as opposed to edit mode.
-;;; If no write access to the data file is
-;;; possible, view mode is enforced.
-;;;
-;;; forms-check-number-of-fields [bool, default t]
-;;; If non-nil, a warning will be issued whenever
-;;; a record is found that does not have the number
-;;; of fields specified by `forms-number-of-fields'.
-;;;
-;;; forms-multi-line [string, default "^K"]
-;;; If non-null the records of the data file may
-;;; contain fields that can span multiple lines in
-;;; the form.
-;;; This variable denotes the separator character
-;;; to be used for this purpose. Upon display, all
-;;; occurrences of this character are translated
-;;; to newlines. Upon storage they are translated
-;;; back to the separator character.
-;;;
-;;; forms-forms-scroll [bool, default nil]
-;;; Non-nil means: rebind locally the commands that
-;;; perform `scroll-up' or `scroll-down' to use
-;;; `forms-next-field' resp. `forms-prev-field'.
-;;;
-;;; forms-forms-jump [bool, default nil]
-;;; Non-nil means: rebind locally the commands that
-;;; perform `beginning-of-buffer' or `end-of-buffer'
-;;; to perform `forms-first-field' resp. `forms-last-field'.
-;;;
-;;; forms-read-file-filter [symbol, default nil]
-;;; If not nil: this should be the name of a
-;;; function that is called after the forms data file
-;;; has been read. It can be used to transform
-;;; the contents of the file into a format more suitable
-;;; for forms-mode processing.
-;;;
-;;; forms-write-file-filter [symbol, default nil]
-;;; If not nil: this should be the name of a
-;;; function that is called before the forms data file
-;;; is written (saved) to disk. It can be used to undo
-;;; the effects of `forms-read-file-filter', if any.
-;;;
-;;; forms-new-record-filter [symbol, default nil]
-;;; If not nil: this should be the name of a
-;;; function that is called when a new
-;;; record is created. It can be used to fill in
-;;; the new record with default fields, for example.
-;;;
-;;; forms-modified-record-filter [symbol, default nil]
-;;; If not nil: this should be the name of a
-;;; function that is called when a record has
-;;; been modified. It is called after the fields
-;;; are parsed. It can be used to register
-;;; modification dates, for example.
-;;;
-;;; forms-use-text-properties [bool, see text for default]
-;;; This variable controls if forms mode should use
-;;; text properties to protect the form text from being
-;;; modified (using text-property `read-only').
-;;; Also, the read-write fields are shown using a
-;;; distinct face, if possible.
-;;; As of emacs 19.29, the `intangible' text property
-;;; is used to prevent moving into read-only fields.
-;;; This variable defaults to t if running Emacs 19
-;;; with text properties.
-;;; The default face to show read-write fields is
-;;; copied from face `region'.
-;;;
-;;; forms-ro-face [symbol, default 'default]
-;;; This is the face that is used to show
-;;; read-only text on the screen.If used, this
-;;; variable should be set to a symbol that is a
-;;; valid face.
-;;; E.g.
-;;; (make-face 'my-face)
-;;; (setq forms-ro-face 'my-face)
-;;;
-;;; forms-rw-face [symbol, default 'region]
-;;; This is the face that is used to show
-;;; read-write text on the screen.
-;;;
-;;; After evaluating the control file, its buffer is cleared and used
-;;; for further processing.
-;;; The data file (as designated by `forms-file') is visited in a buffer
-;;; `forms--file-buffer' which will not normally be shown.
-;;; Great malfunctioning may be expected if this file/buffer is modified
-;;; outside of this package while it is being visited!
-;;;
-;;; Normal operation is to transfer one line (record) from the data file,
-;;; split it into fields (into `forms--the-record-list'), and display it
-;;; using the specs in `forms-format-list'.
-;;; A format routine `forms--format' is built upon startup to format
-;;; the records according to `forms-format-list'.
-;;;
-;;; When a form is changed the record is updated as soon as this form
-;;; is left. The contents of the form are parsed using information
-;;; obtained from `forms-format-list', and the fields which are
-;;; deduced from the form are modified. Fields not shown on the forms
-;;; retain their original values. The newly formed record then
-;;; replaces the contents of the old record in `forms--file-buffer'.
-;;; A parse routine `forms--parser' is built upon startup to parse
-;;; the records.
-;;;
-;;; Two exit functions exist: `forms-exit' and `forms-exit-no-save'.
-;;; `forms-exit' saves the data to the file, if modified.
-;;; `forms-exit-no-save` does not. However, if `forms-exit-no-save'
-;;; is executed and the file buffer has been modified, Emacs will ask
-;;; questions anyway.
-;;;
-;;; Other functions provided by forms mode are:
-;;;
-;;; paging (forward, backward) by record
-;;; jumping (first, last, random number)
-;;; searching
-;;; creating and deleting records
-;;; reverting the form (NOT the file buffer)
-;;; switching edit <-> view mode v.v.
-;;; jumping from field to field
-;;;
-;;; As an documented side-effect: jumping to the last record in the
-;;; file (using forms-last-record) will adjust forms--total-records if
-;;; needed.
-;;;
-;;; The forms buffer can be in on eof two modes: edit mode or view
-;;; mode. View mode is a read-only mode, you cannot modify the
-;;; contents of the buffer.
-;;;
-;;; Edit mode commands:
-;;;
-;;; TAB forms-next-field
-;;; \C-c TAB forms-next-field
-;;; \C-c < forms-first-record
-;;; \C-c > forms-last-record
-;;; \C-c ? describe-mode
-;;; \C-c \C-k forms-delete-record
-;;; \C-c \C-q forms-toggle-read-only
-;;; \C-c \C-o forms-insert-record
-;;; \C-c \C-l forms-jump-record
-;;; \C-c \C-n forms-next-record
-;;; \C-c \C-p forms-prev-record
-;;; \C-c \C-r forms-search-backward
-;;; \C-c \C-s forms-search-forward
-;;; \C-c \C-x forms-exit
-;;;
-;;; Read-only mode commands:
-;;;
-;;; SPC forms-next-record
-;;; DEL forms-prev-record
-;;; ? describe-mode
-;;; \C-q forms-toggle-read-only
-;;; l forms-jump-record
-;;; n forms-next-record
-;;; p forms-prev-record
-;;; r forms-search-backward
-;;; s forms-search-forward
-;;; x forms-exit
-;;;
-;;; Of course, it is also possible to use the \C-c prefix to obtain the
-;;; same command keys as in edit mode.
-;;;
-;;; The following bindings are available, independent of the mode:
-;;;
-;;; [next] forms-next-record
-;;; [prior] forms-prev-record
-;;; [begin] forms-first-record
-;;; [end] forms-last-record
-;;; [S-TAB] forms-prev-field
-;;; [backtab] forms-prev-field
-;;;
-;;; For convenience, TAB is always bound to `forms-next-field', so you
-;;; don't need the C-c prefix for this command.
-;;;
-;;; As mentioned above (see `forms-forms-scroll' and `forms-forms-jump')
-;;; the bindings of standard functions `scroll-up', `scroll-down',
-;;; `beginning-of-buffer' and `end-of-buffer' can be locally replaced with
-;;; forms mode functions next/prev record and first/last
-;;; record.
-;;;
-;;; `local-write-file hook' is defined to save the actual data file
-;;; instead of the buffer data, `revert-file-hook' is defined to
-;;; revert a forms to original.
+;; Visit a file using a form.
+;;
+;; === Naming conventions
+;;
+;; The names of all variables and functions start with 'forms-'.
+;; Names which start with 'forms--' are intended for internal use, and
+;; should *NOT* be used from the outside.
+;;
+;; All variables are buffer-local, to enable multiple forms visits
+;; simultaneously.
+;; Variable `forms--mode-setup' is local to *ALL* buffers, for it
+;; controls if forms-mode has been enabled in a buffer.
+;;
+;; === How it works ===
+;;
+;; Forms mode means visiting a data file which is supposed to consist
+;; of records each containing a number of fields. The records are
+;; separated by a newline, the fields are separated by a user-defined
+;; field separator (default: TAB).
+;; When shown, a record is transferred to an Emacs buffer and
+;; presented using a user-defined form. One record is shown at a
+;; time.
+;;
+;; Forms mode is a composite mode. It involves two files, and two
+;; buffers.
+;; The first file, called the control file, defines the name of the
+;; data file and the forms format. This file buffer will be used to
+;; present the forms.
+;; The second file holds the actual data. The buffer of this file
+;; will be buried, for it is never accessed directly.
+;;
+;; Forms mode is invoked using M-x forms-find-file control-file .
+;; Alternatively `forms-find-file-other-window' can be used.
+;;
+;; You may also visit the control file, and switch to forms mode by hand
+;; with M-x forms-mode .
+;;
+;; Automatic mode switching is supported if you specify
+;; "-*- forms -*-" in the first line of the control file.
+;;
+;; The control file is visited, evaluated using `eval-current-buffer',
+;; and should set at least the following variables:
+;;
+;; forms-file [string]
+;; The name of the data file.
+;;
+;; forms-number-of-fields [integer]
+;; The number of fields in each record.
+;;
+;; forms-format-list [list]
+;; Formatting instructions.
+;;
+;; `forms-format-list' should be a list, each element containing
+;;
+;; - a string, e.g. "hello". The string is inserted in the forms
+;; "as is".
+;;
+;; - an integer, denoting a field number.
+;; The contents of this field are inserted at this point.
+;; Fields are numbered starting with number one.
+;;
+;; - a function call, e.g. (insert "text").
+;; This function call is dynamically evaluated and should return a
+;; string. It should *NOT* have side-effects on the forms being
+;; constructed. The current fields are available to the function
+;; in the variable `forms-fields', they should *NOT* be modified.
+;;
+;; - a lisp symbol, that must evaluate to one of the above.
+;;
+;; Optional variables which may be set in the control file:
+;;
+;; forms-field-sep [string, default TAB]
+;; The field separator used to separate the
+;; fields in the data file. It may be a string.
+;;
+;; forms-read-only [bool, default nil]
+;; Non-nil means that the data file is visited
+;; read-only (view mode) as opposed to edit mode.
+;; If no write access to the data file is
+;; possible, view mode is enforced.
+;;
+;; forms-check-number-of-fields [bool, default t]
+;; If non-nil, a warning will be issued whenever
+;; a record is found that does not have the number
+;; of fields specified by `forms-number-of-fields'.
+;;
+;; forms-multi-line [string, default "^K"]
+;; If non-null the records of the data file may
+;; contain fields that can span multiple lines in
+;; the form.
+;; This variable denotes the separator character
+;; to be used for this purpose. Upon display, all
+;; occurrences of this character are translated
+;; to newlines. Upon storage they are translated
+;; back to the separator character.
+;;
+;; forms-forms-scroll [bool, default nil]
+;; Non-nil means: rebind locally the commands that
+;; perform `scroll-up' or `scroll-down' to use
+;; `forms-next-field' resp. `forms-prev-field'.
+;;
+;; forms-forms-jump [bool, default nil]
+;; Non-nil means: rebind locally the commands that
+;; perform `beginning-of-buffer' or `end-of-buffer'
+;; to perform `forms-first-field' resp. `forms-last-field'.
+;;
+;; forms-read-file-filter [symbol, default nil]
+;; If not nil: this should be the name of a
+;; function that is called after the forms data file
+;; has been read. It can be used to transform
+;; the contents of the file into a format more suitable
+;; for forms-mode processing.
+;;
+;; forms-write-file-filter [symbol, default nil]
+;; If not nil: this should be the name of a
+;; function that is called before the forms data file
+;; is written (saved) to disk. It can be used to undo
+;; the effects of `forms-read-file-filter', if any.
+;;
+;; forms-new-record-filter [symbol, default nil]
+;; If not nil: this should be the name of a
+;; function that is called when a new
+;; record is created. It can be used to fill in
+;; the new record with default fields, for example.
+;;
+;; forms-modified-record-filter [symbol, default nil]
+;; If not nil: this should be the name of a
+;; function that is called when a record has
+;; been modified. It is called after the fields
+;; are parsed. It can be used to register
+;; modification dates, for example.
+;;
+;; forms-use-text-properties [bool, see text for default]
+;; This variable controls if forms mode should use
+;; text properties to protect the form text from being
+;; modified (using text-property `read-only').
+;; Also, the read-write fields are shown using a
+;; distinct face, if possible.
+;; As of emacs 19.29, the `intangible' text property
+;; is used to prevent moving into read-only fields.
+;; This variable defaults to t if running Emacs 19
+;; with text properties.
+;; The default face to show read-write fields is
+;; copied from face `region'.
+;;
+;; forms-ro-face [symbol, default 'default]
+;; This is the face that is used to show
+;; read-only text on the screen.If used, this
+;; variable should be set to a symbol that is a
+;; valid face.
+;; E.g.
+;; (make-face 'my-face)
+;; (setq forms-ro-face 'my-face)
+;;
+;; forms-rw-face [symbol, default 'region]
+;; This is the face that is used to show
+;; read-write text on the screen.
+;;
+;; After evaluating the control file, its buffer is cleared and used
+;; for further processing.
+;; The data file (as designated by `forms-file') is visited in a buffer
+;; `forms--file-buffer' which will not normally be shown.
+;; Great malfunctioning may be expected if this file/buffer is modified
+;; outside of this package while it is being visited!
+;;
+;; Normal operation is to transfer one line (record) from the data file,
+;; split it into fields (into `forms--the-record-list'), and display it
+;; using the specs in `forms-format-list'.
+;; A format routine `forms--format' is built upon startup to format
+;; the records according to `forms-format-list'.
+;;
+;; When a form is changed the record is updated as soon as this form
+;; is left. The contents of the form are parsed using information
+;; obtained from `forms-format-list', and the fields which are
+;; deduced from the form are modified. Fields not shown on the forms
+;; retain their original values. The newly formed record then
+;; replaces the contents of the old record in `forms--file-buffer'.
+;; A parse routine `forms--parser' is built upon startup to parse
+;; the records.
+;;
+;; Two exit functions exist: `forms-exit' and `forms-exit-no-save'.
+;; `forms-exit' saves the data to the file, if modified.
+;; `forms-exit-no-save` does not. However, if `forms-exit-no-save'
+;; is executed and the file buffer has been modified, Emacs will ask
+;; questions anyway.
+;;
+;; Other functions provided by forms mode are:
+;;
+;; paging (forward, backward) by record
+;; jumping (first, last, random number)
+;; searching
+;; creating and deleting records
+;; reverting the form (NOT the file buffer)
+;; switching edit <-> view mode v.v.
+;; jumping from field to field
+;;
+;; As an documented side-effect: jumping to the last record in the
+;; file (using forms-last-record) will adjust forms--total-records if
+;; needed.
+;;
+;; The forms buffer can be in on eof two modes: edit mode or view
+;; mode. View mode is a read-only mode, you cannot modify the
+;; contents of the buffer.
+;;
+;; Edit mode commands:
+;;
+;; TAB forms-next-field
+;; \C-c TAB forms-next-field
+;; \C-c < forms-first-record
+;; \C-c > forms-last-record
+;; \C-c ? describe-mode
+;; \C-c \C-k forms-delete-record
+;; \C-c \C-q forms-toggle-read-only
+;; \C-c \C-o forms-insert-record
+;; \C-c \C-l forms-jump-record
+;; \C-c \C-n forms-next-record
+;; \C-c \C-p forms-prev-record
+;; \C-c \C-r forms-search-backward
+;; \C-c \C-s forms-search-forward
+;; \C-c \C-x forms-exit
+;;
+;; Read-only mode commands:
+;;
+;; SPC forms-next-record
+;; DEL forms-prev-record
+;; ? describe-mode
+;; \C-q forms-toggle-read-only
+;; l forms-jump-record
+;; n forms-next-record
+;; p forms-prev-record
+;; r forms-search-backward
+;; s forms-search-forward
+;; x forms-exit
+;;
+;; Of course, it is also possible to use the \C-c prefix to obtain the
+;; same command keys as in edit mode.
+;;
+;; The following bindings are available, independent of the mode:
+;;
+;; [next] forms-next-record
+;; [prior] forms-prev-record
+;; [begin] forms-first-record
+;; [end] forms-last-record
+;; [S-TAB] forms-prev-field
+;; [backtab] forms-prev-field
+;;
+;; For convenience, TAB is always bound to `forms-next-field', so you
+;; don't need the C-c prefix for this command.
+;;
+;; As mentioned above (see `forms-forms-scroll' and `forms-forms-jump')
+;; the bindings of standard functions `scroll-up', `scroll-down',
+;; `beginning-of-buffer' and `end-of-buffer' can be locally replaced with
+;; forms mode functions next/prev record and first/last
+;; record.
+;;
+;; `local-write-file hook' is defined to save the actual data file
+;; instead of the buffer data, `revert-file-hook' is defined to
+;; revert a forms to original.
\f
;;; Code:
(provide 'forms) ;;; official
(provide 'forms-mode) ;;; for compatibility
-(defconst forms-version (substring "$Revision: 2.23 $" 11 -2)
+(defconst forms-version (substring "$Revision: 2.24 $" 11 -2)
"The version number of forms-mode (as string). The complete RCS id is:
- $Id: forms.el,v 2.23 1995/11/16 20:04:57 jvromans Exp kwzh $")
+ $Id: forms.el,v 2.24 1996/01/04 23:38:16 kwzh Exp erik $")
(defvar forms-mode-hooks nil
"Hook functions to be run upon entering Forms mode.")
;;; frame.el --- multi-frame management independent of window systems.
-;;;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: internal
-;;; This file is part of GNU Emacs.
-;;;
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; gnus-cache.el --- cache interface for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-cite.el --- parse citations in articles for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Per Abrahamsen <abraham@iesd.auc.dk>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-cus.el --- User friendly customization of Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
-;;
+
;; Author: Per Abrahamsen <abraham@iesd.auc.dk>
;; Keywords: help, news
;; Version: 0.1
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-edit.el --- Gnus SCORE file editing
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
-;;
+
;; Author: Per Abrahamsen <abraham@iesd.auc.dk>
;; Keywords: news, help
;; Version: 0.2
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
;;; Commentary:
-;;
+
;; Type `M-x gnus-score-customize RET' to invoke.
;;; Code:
;;; gnus-ems.el --- functions for making Gnus work under different Emacsen
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-kill.el --- kill commands for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-mh.el --- mh-e interface for Gnus
+
;; Copyright (C) 1994,95 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-msg.el --- mail and post interface for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-score.el --- scoring code for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Per Abrahamsen <amanda@iesd.auc.dk>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-uu.el --- extract (uu)encoded files in Gnus
+
;; Copyright (C) 1985,86,87,93,94,95 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-vis.el --- display-oriented parts of Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus-vm.el --- vm interface for Gnus
+
;; Copyright (C) 1994,95 Free Software Foundation, Inc.
;; Author: Per Persson <pp@solace.mh.se>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; gnus.el --- a newsreader for GNU Emacs
+
;; Copyright (C) 1987,88,89,90,93,94,95 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; goto-addr.el --- click to browse URL or to send to e-mail address
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Eric Ding <ericding@mit.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; gud.el --- Grand Unified Debugger mode for gdb, sdb, dbx, or xdb
-;;; under Emacs
+;;; gud.el --- Grand Unified Debugger mode for gdb, sdb, dbx, or xdb under Emacs
;; Author: Eric S. Raymond <esr@snark.thyrsus.com>
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
-;; This file supplies the macro make-help-screen which constructs
+
+;; This file supplies the macro make-help-screen which constructs
;; single character dispatching with browsable help such as that provided
;; by help-for-help. This can be used to make many modes easier to use; for
;; example, the Gnu Emacs Empire Tool uses this for every "nested" mode map
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; hippie-exp.el --- expand text trying various ways to find its expansion.
+;; Copyright (C) 1992 Free Software Foundation, Inc.
+
;; Author: Anders Holst <aho@sans.kth.se>
;; Last change: 6 August 1995
;; Version: 1.4
;; Keywords: abbrev
-;; Copyright (C) 1992 Free Software Foundation, Inc.
-;;
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; `hippie-expand' is a single function for a lot of different kinds
;; of completions and expansions. Called repeatedly it tries all
;; possible completions in succession.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Loading this package implements a more fine-grained minibuffer
-;;; completion feedback scheme. Prospective completions are concisely
-;;; indicated within the minibuffer itself, with each successive
-;;; keystroke.
-
-;;; See 'icomplete-completions' docstring for a description of the
-;;; icomplete display format.
-
-;;; See the `icomplete-minibuffer-setup-hook' docstring for a means to
-;;; customize icomplete setup for interoperation with other
-;;; minibuffer-oriented packages.
-
-;;; To activate icomplete mode, simply load the package. You can
-;;; subsequently deactivate it by invoking the function icomplete-mode
-;;; with a negative prefix-arg (C-U -1 ESC-x icomplete-mode). Also,
-;;; you can prevent activation of the mode during package load by
-;;; first setting the variable `icomplete-mode' to nil. Icompletion
-;;; can be enabled any time after the package is loaded by invoking
-;;; icomplete-mode without a prefix arg.
-
-;;; Thanks to everyone for their suggestions for refinements of this
-;;; package. I particularly have to credit Michael Cook, who
-;;; implemented an incremental completion style in his 'iswitch'
-;;; functions that served as a model for icomplete. Some other
-;;; contributors: Noah Freidman (restructuring as minor mode), Colin
-;;; Rafferty (lemacs reconciliation), Lars Lindberg, RMS, and
-;;; others.
-
-;;; klm.
+;; Loading this package implements a more fine-grained minibuffer
+;; completion feedback scheme. Prospective completions are concisely
+;; indicated within the minibuffer itself, with each successive
+;; keystroke.
+
+;; See 'icomplete-completions' docstring for a description of the
+;; icomplete display format.
+
+;; See the `icomplete-minibuffer-setup-hook' docstring for a means to
+;; customize icomplete setup for interoperation with other
+;; minibuffer-oriented packages.
+
+;; To activate icomplete mode, simply load the package. You can
+;; subsequently deactivate it by invoking the function icomplete-mode
+;; with a negative prefix-arg (C-U -1 ESC-x icomplete-mode). Also,
+;; you can prevent activation of the mode during package load by
+;; first setting the variable `icomplete-mode' to nil. Icompletion
+;; can be enabled any time after the package is loaded by invoking
+;; icomplete-mode without a prefix arg.
+
+;; Thanks to everyone for their suggestions for refinements of this
+;; package. I particularly have to credit Michael Cook, who
+;; implemented an incremental completion style in his 'iswitch'
+;; functions that served as a model for icomplete. Some other
+;; contributors: Noah Freidman (restructuring as minor mode), Colin
+;; Rafferty (lemacs reconciliation), Lars Lindberg, RMS, and
+;; others.
+
+;; klm.
;;; Code:
;;; ielm.el --- interaction mode for Emacs Lisp
+
;; Copyright (C) 1994 Free Software Foundation, Inc.
;; Author: David Smith <maa036@lancaster.ac.uk>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
(defvar ielm-header
(concat
"*** Welcome to IELM version "
- (substring "$Revision: 1.5 $" 11 -2)
+ (substring "$Revision: 1.6 $" 11 -2)
" *** Type (describe-mode) for help.\n"
"IELM has ABSOLUTELY NO WARRANTY; type (describe-no-warranty) for details.\n")
"Message to display when IELM is started.")
;; Lars Lindberg <lli@sypro.cap.se>
;; Created: 8 Feb 1994
;; Keywords: tools
-;;
-;; This program is free software; you can redistribute it and/or modify
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; Purpose of this package:
;; To present a framework for mode-specific buffer indexes.
;; A buffer index is an alist of names and buffer positions.
;; [karl] - Karl Fogel kfogel@floss.life.uiuc.edu
;;; Code
+
(eval-when-compile (require 'cl))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Note that nowadays we expect info files to be made using makeinfo.
+;; Note that nowadays we expect info files to be made using makeinfo.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; iso-acc.el -- minor mode providing electric accent keys
-;;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+
+;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
;; Author: Johan Vromans <jv@mh.nl>
;; Version: 1.7 (modified)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
+
;; This lisp code serves two purposes, both of which involve
;; the translation of various conventions for representing European
;; character sets to ISO 8859-1.
-; Net support:
-; Various conventions exist in Newsgroups on how to represent national
-; characters. The functions provided here translate these net conventions
-; to ISO.
-;
-; Calling `iso-german' will turn the net convention for umlauts ("a etc.)
-; into ISO latin1 umlauts for easy reading.
-; 'iso-spanish' will turn net conventions for representing spanish
-; to ISO latin1. (Note that accents are omitted in news posts most
-; of the time, only enye is escaped.)
-
-; TeX support
-; This mode installs hooks which change TeX files to ISO Latin-1 for
-; simplified editing. When the TeX file is saved, ISO latin1 characters are
-; translated back to escape sequences.
-;
-; An alternative is a TeX style that handles 8 bit ISO files
-; (available on ftp.vlsivie.tuwien.ac.at in /pub/8bit)
-; - but these files are difficult to transmit ... so while the net is
-; still @ 7 bit this may be useful
-
-;; TO DO:
-; The net support should install hooks (like TeX support does)
-; which recognizes certain news groups and translates all articles from
-; those groups.
-;
-; Cover more cases for translation (There is an infinite number of ways to
-; represent accented characters in TeX)
-
-;; SEE ALSO:
-; If you are interested in questions related to using the ISO 8859-1
-; characters set (configuring emacs, Unix, etc. to use ISO), then you
-; can get the ISO 8859-1 FAQ via anonymous ftp from
-; ftp.vlsivie.tuwien.ac.at in /pub/bit/FAQ-ISO-8859-1
+;; Net support:
+;; Various conventions exist in Newsgroups on how to represent national
+;; characters. The functions provided here translate these net conventions
+;; to ISO.
+;;
+;; Calling `iso-german' will turn the net convention for umlauts ("a etc.)
+;; into ISO latin1 umlauts for easy reading.
+;; 'iso-spanish' will turn net conventions for representing spanish
+;; to ISO latin1. (Note that accents are omitted in news posts most
+;; of the time, only enye is escaped.)
+
+;; TeX support
+;; This mode installs hooks which change TeX files to ISO Latin-1 for
+;; simplified editing. When the TeX file is saved, ISO latin1 characters are
+;; translated back to escape sequences.
+;;
+;; An alternative is a TeX style that handles 8 bit ISO files
+;; (available on ftp.vlsivie.tuwien.ac.at in /pub/8bit)
+;; - but these files are difficult to transmit ... so while the net is
+;; still @ 7 bit this may be useful
+
+;;; TO DO:
+;; The net support should install hooks (like TeX support does)
+;; which recognizes certain news groups and translates all articles from
+;; those groups.
+;;
+;; Cover more cases for translation (There is an infinite number of ways to
+;; represent accented characters in TeX)
+
+;;; SEE ALSO:
+;; If you are interested in questions related to using the ISO 8859-1
+;; characters set (configuring emacs, Unix, etc. to use ISO), then you
+;; can get the ISO 8859-1 FAQ via anonymous ftp from
+;; ftp.vlsivie.tuwien.ac.at in /pub/bit/FAQ-ISO-8859-1
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;;====================================================================
;; Instructions
;; For programmed use of isearch-mode, e.g. calling (isearch-forward),
;;; Change Log:
-;;; Changes before those recorded in ChangeLog:
-
-;;; Revision 1.4 92/09/14 16:26:02 liberte
-;;; Added prefix args to isearch-forward, etc. to switch between
-;;; string and regular expression searching.
-;;; Added some support for lemacs.
-;;; Added general isearch-highlight option - but only for lemacs so far.
-;;; Added support for frame switching in emacs 19.
-;;; Added word search option to isearch-edit-string.
-;;; Renamed isearch-quit to isearch-abort.
-;;; Numerous changes to comments and doc strings.
-;;;
-;;; Revision 1.3 92/06/29 13:10:08 liberte
-;;; Moved modal isearch-mode handling into isearch-mode.
-;;; Got rid of buffer-local isearch variables.
-;;; isearch-edit-string used by ring adjustments, completion, and
-;;; nonincremental searching. C-s and C-r are additional exit commands.
-;;; Renamed all regex to regexp.
-;;; Got rid of found-start and found-point globals.
-;;; Generalized handling of upper-case chars.
-
-;;; Revision 1.2 92/05/27 11:33:57 liberte
-;;; Emacs version 19 has a search ring, which is supported here.
-;;; Other fixes found in the version 19 isearch are included here.
-;;;
-;;; Also see variables search-caps-disable-folding,
-;;; search-nonincremental-instead, search-whitespace-regexp, and
-;;; commands isearch-toggle-regexp, isearch-edit-string.
-;;;
-;;; semi-modal isearching is supported.
-
-;;; Changes for 1.1
-;;; 3/18/92 Fixed invalid-regexp.
-;;; 3/18/92 Fixed yanking in regexps.
+;; Changes before those recorded in ChangeLog:
+
+;; Revision 1.4 92/09/14 16:26:02 liberte
+;; Added prefix args to isearch-forward, etc. to switch between
+;; string and regular expression searching.
+;; Added some support for lemacs.
+;; Added general isearch-highlight option - but only for lemacs so far.
+;; Added support for frame switching in emacs 19.
+;; Added word search option to isearch-edit-string.
+;; Renamed isearch-quit to isearch-abort.
+;; Numerous changes to comments and doc strings.
+;;
+;; Revision 1.3 92/06/29 13:10:08 liberte
+;; Moved modal isearch-mode handling into isearch-mode.
+;; Got rid of buffer-local isearch variables.
+;; isearch-edit-string used by ring adjustments, completion, and
+;; nonincremental searching. C-s and C-r are additional exit commands.
+;; Renamed all regex to regexp.
+;; Got rid of found-start and found-point globals.
+;; Generalized handling of upper-case chars.
+
+;; Revision 1.2 92/05/27 11:33:57 liberte
+;; Emacs version 19 has a search ring, which is supported here.
+;; Other fixes found in the version 19 isearch are included here.
+;;
+;; Also see variables search-caps-disable-folding,
+;; search-nonincremental-instead, search-whitespace-regexp, and
+;; commands isearch-toggle-regexp, isearch-edit-string.
+;;
+;; semi-modal isearching is supported.
+
+;; Changes for 1.1
+;; 3/18/92 Fixed invalid-regexp.
+;; 3/18/92 Fixed yanking in regexps.
;;; Code:
\f
-;;;========================================================================
;;; Some additional options and constants.
(defconst search-exit-option t
(defvar isearch-mode-end-hook nil
"Function(s) to call after terminating an incremental search.")
-;;;==================================================================
;;; Search ring.
(defvar search-ring nil
"*Non-nil if advancing or retreating in the search ring should cause search.
Default value, nil, means edit the string instead.")
-;;;====================================================
;;; Define isearch-mode keymap.
(defvar isearch-mode-map nil
(setq minibuffer-local-isearch-map map)
))
-;;;========================================================
;; Internal variables declared globally for byte-compiler.
;; These are all set with setq while isearching
;; and bound locally while editing the search string.
(defvar isearch-new-forward nil)
-;;;==============================================================
;; Minor-mode-alist changes - kind of redundant with the
;; echo area, but if isearching in multiple windows, it can be useful.
(define-key global-map "\C-r" 'isearch-backward)
(define-key esc-map "\C-r" 'isearch-backward-regexp)
-;;;===============================================================
;;; Entry points to isearch-mode.
;;; These four functions should replace those in loaddefs.el
;;; An alternative is to defalias isearch-forward etc to isearch-mode,
(isearch-update))
\f
-;;;==================================================================
;; isearch-mode only sets up incremental search for the minor mode.
;; All the work is done by the isearch-mode commands.
isearch-success)
-;;;====================================================
;; Some high level utilities. Others below.
(defun isearch-update ()
(if (> (length search-ring) search-ring-max)
(setcdr (nthcdr (1- search-ring-max) search-ring) nil))))))
-;;;=======================================================
;;; Switching buffers should first terminate isearch-mode.
;;; This is done quite differently for each variant of emacs.
;;; For lemacs, see Exiting in lemacs below
(isearch-done)
(handle-switch-frame (car (cdr (isearch-last-command-char)))))
-;;;========================================================
-
\f
-;;;====================================================
;; Commands active while inside of the isearch minor mode.
(defun isearch-exit ()
(isearch-search-and-update))
\f
-;;===========================================================
;; Search Ring
(defun isearch-ring-adjust1 (advance)
(insert isearch-string))))
\f
-;;;==============================================================
;; The search status stack (and isearch window-local variables, not used).
;; Need a structure for this.
isearch-cmds)))
\f
-;;;==================================================================
;; Message string
(defun isearch-message (&optional c-q-hack ellipsis)
"")))
\f
-;;;========================================================
;;; Searching
(defun isearch-search ()
\f
-;;;========================================================
;;; Highlighting
(defvar isearch-overlay nil)
(if isearch-overlay
(delete-overlay isearch-overlay)))
-;;;===========================================================
;;; General utilities
string))))
-;;;=================================================
;; Portability functions to support various Emacs versions.
;; To quiet the byte-compiler.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; jka-compr.el --- reading/writing/loading compressed files
-;;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
;; Author: jka@ece.cmu.edu (Jay K. Adams)
;; Keywords: data
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This package implements low-level support for reading, writing,
-;;; and loading compressed files. It hooks into the low-level file
-;;; I/O functions (including write-region and insert-file-contents) so
-;;; that they automatically compress or uncompress a file if the file
-;;; appears to need it (based on the extension of the file name).
-;;; Packages like Rmail, VM, GNUS, and Info should be able to work
-;;; with compressed files without modification.
-
-
-;;; INSTRUCTIONS:
-;;;
-;;; To use jka-compr, simply load this package, and edit as usual.
-;;; Its operation should be transparent to the user (except for
-;;; messages appearing when a file is being compressed or
-;;; uncompressed).
-;;;
-;;; The variable, jka-compr-compression-info-list can be used to
-;;; customize jka-compr to work with other compression programs.
-;;; The default value of this variable allows jka-compr to work with
-;;; Unix compress and gzip.
-;;;
-;;; If you are concerned about the stderr output of gzip and other
-;;; compression/decompression programs showing up in your buffers, you
-;;; should set the discard-error flag in the compression-info-list.
-;;; This will cause the stderr of all programs to be discarded.
-;;; However, it also causes emacs to call compression/uncompression
-;;; programs through a shell (which is specified by jka-compr-shell).
-;;; This may be a drag if, on your system, starting up a shell is
-;;; slow.
-;;;
-;;; If you don't want messages about compressing and decompressing
-;;; to show up in the echo area, you can set the compress-name and
-;;; decompress-name fields of the jka-compr-compression-info-list to
-;;; nil.
-
-
-;;; APPLICATION NOTES:
-;;;
-;;; crypt++
-;;; jka-compr can coexist with crpyt++ if you take all the decompression
-;;; entries out of the crypt-encoding-list. Clearly problems will arise if
-;;; you have two programs trying to compress/decompress files. jka-compr
-;;; will not "work with" crypt++ in the following sense: you won't be able to
-;;; decode encrypted compressed files--that is, files that have been
-;;; compressed then encrypted (in that order). Theoretically, crypt++ and
-;;; jka-compr could properly handle a file that has been encrypted then
-;;; compressed, but there is little point in trying to compress an encrypted
-;;; file.
-;;;
-
-
-;;; ACKNOWLEDGMENTS
-;;;
-;;; jka-compr is a V19 adaptation of jka-compr for V18 of Emacs. Many people
-;;; have made helpful suggestions, reported bugs, and even fixed bugs in
-;;; jka-compr. I recall the following people as being particularly helpful.
-;;;
-;;; Jean-loup Gailly
-;;; David Hughes
-;;; Richard Pieri
-;;; Daniel Quinlan
-;;; Chris P. Ross
-;;; Rick Sladkey
-;;;
-;;; Andy Norman's ange-ftp was the inspiration for the original jka-compr for
-;;; Version 18 of Emacs.
-;;;
-;;; After I had made progress on the original jka-compr for V18, I learned of a
-;;; package written by Kazushi Jam Marukawa, called jam-zcat, that did exactly
-;;; what I was trying to do. I looked over the jam-zcat source code and
-;;; probably got some ideas from it.
-;;;
+;; This package implements low-level support for reading, writing,
+;; and loading compressed files. It hooks into the low-level file
+;; I/O functions (including write-region and insert-file-contents) so
+;; that they automatically compress or uncompress a file if the file
+;; appears to need it (based on the extension of the file name).
+;; Packages like Rmail, VM, GNUS, and Info should be able to work
+;; with compressed files without modification.
+
+
+;; INSTRUCTIONS:
+;;
+;; To use jka-compr, simply load this package, and edit as usual.
+;; Its operation should be transparent to the user (except for
+;; messages appearing when a file is being compressed or
+;; uncompressed).
+;;
+;; The variable, jka-compr-compression-info-list can be used to
+;; customize jka-compr to work with other compression programs.
+;; The default value of this variable allows jka-compr to work with
+;; Unix compress and gzip.
+;;
+;; If you are concerned about the stderr output of gzip and other
+;; compression/decompression programs showing up in your buffers, you
+;; should set the discard-error flag in the compression-info-list.
+;; This will cause the stderr of all programs to be discarded.
+;; However, it also causes emacs to call compression/uncompression
+;; programs through a shell (which is specified by jka-compr-shell).
+;; This may be a drag if, on your system, starting up a shell is
+;; slow.
+;;
+;; If you don't want messages about compressing and decompressing
+;; to show up in the echo area, you can set the compress-name and
+;; decompress-name fields of the jka-compr-compression-info-list to
+;; nil.
+
+
+;; APPLICATION NOTES:
+;;
+;; crypt++
+;; jka-compr can coexist with crpyt++ if you take all the decompression
+;; entries out of the crypt-encoding-list. Clearly problems will arise if
+;; you have two programs trying to compress/decompress files. jka-compr
+;; will not "work with" crypt++ in the following sense: you won't be able to
+;; decode encrypted compressed files--that is, files that have been
+;; compressed then encrypted (in that order). Theoretically, crypt++ and
+;; jka-compr could properly handle a file that has been encrypted then
+;; compressed, but there is little point in trying to compress an encrypted
+;; file.
+;;
+
+
+;; ACKNOWLEDGMENTS
+;;
+;; jka-compr is a V19 adaptation of jka-compr for V18 of Emacs. Many people
+;; have made helpful suggestions, reported bugs, and even fixed bugs in
+;; jka-compr. I recall the following people as being particularly helpful.
+;;
+;; Jean-loup Gailly
+;; David Hughes
+;; Richard Pieri
+;; Daniel Quinlan
+;; Chris P. Ross
+;; Rick Sladkey
+;;
+;; Andy Norman's ange-ftp was the inspiration for the original jka-compr for
+;; Version 18 of Emacs.
+;;
+;; After I had made progress on the original jka-compr for V18, I learned of a
+;; package written by Kazushi Jam Marukawa, called jam-zcat, that did exactly
+;; what I was trying to do. I looked over the jam-zcat source code and
+;; probably got some ideas from it.
+;;
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; loadhist.el --- lisp functions for working with feature groups
-;;; Copyright (C) 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Eric S. Raymond <esr@snark.thyrsus.com>
;; Version: 1.0
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; ls-lisp.el --- emulate insert-directory completely in Emacs Lisp
+;; Copyright (C) 1992, 1994 by Sebastian Kremer <sk@thp.uni-koeln.de>
+
;; Author: Sebastian Kremer <sk@thp.uni-koeln.de>
;; Keywords: unix
-;; Copyright (C) 1992, 1994 by Sebastian Kremer <sk@thp.uni-koeln.de>
+;; This file is part of GNU Emacs.
-;; This program is free software; you can redistribute it and/or modify
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Commentary:
;; INSTALLATION =======================================================
;;
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; blessmail.el --- Decide whether movemail needs special privileges.
-;;; Copyright (C) 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1994 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: internal
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; mail-hist.el --- Headers and message body history for outgoing mail.
+
;; Copyright (C) 1994 Free Software Foundation, Inc.
;; Author: Karl Fogel <kfogel@cs.oberlin.edu>
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
;;; Commentary:
;; You should have received a copy of the GNU General Public License
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; mailabbrev.el --- abbrev-expansion of mail aliases.
-;;; Copyright (C) 1985, 1986, 1987, 1992, 1993 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1986, 1987, 1992, 1993 Free Software Foundation, Inc.
;; Author: Jamie Zawinski <jwz@lucid.com>
;; Maintainer: Jamie Zawinski <jwz@lucid.com>
;; Created: 19 Oct 90
;; Keywords: mail
-;;; This file is part of GNU Emacs.
+;; This file is part of GNU Emacs.
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This file ensures that, when the point is in a To:, CC:, BCC:, or From:
-;;; field, word-abbrevs are defined for each of your mail aliases. These
-;;; aliases will be defined from your .mailrc file (or the file specified by
-;;; the MAILRC environment variable) if it exists. Your mail aliases will
-;;; expand any time you type a word-delimiter at the end of an abbreviation.
-;;;
-;;; What you see is what you get: if mailabbrev is in use when you type
-;;; a name, and the name does not expand, you know it is not an abbreviation.
-;;; However, if you yank abbreviations into the headers
-;;; in a way that bypasses the check for abbreviations,
-;;; they are expanded (but not visibly) when you send the message.
-;;;
-;;; Your mail alias abbrevs will be in effect only when the point is in an
-;;; appropriate header field. When in the body of the message, or other
-;;; header fields, the mail aliases will not expand. Rather, the normal
-;;; mode-specific abbrev table (mail-mode-abbrev-table) will be used if
-;;; defined. So if you use mail-mode specific abbrevs, this code will not
-;;; adversely affect you. You can control which header fields the abbrevs
-;;; are used in by changing the variable mail-abbrev-mode-regexp.
-;;;
-;;; If auto-fill mode is on, abbrevs will wrap at commas instead of at word
-;;; boundaries; also, header continuation-lines will be properly indented.
-;;;
-;;; You can also insert a mail alias with mail-interactive-insert-alias
-;;; (bound to C-c C-a), which prompts you for an alias (with completion)
-;;; and inserts its expansion at point.
-;;;
-;;; This file fixes a bug in the old system which prohibited your .mailrc
-;;; file from having lines like
-;;;
-;;; alias someone "John Doe <doe@quux.com>"
-;;;
-;;; That is, if you want an address to have embedded spaces, simply surround it
-;;; with double-quotes. This is necessary because the format of the .mailrc
-;;; file bogusly uses spaces as address delimiters. The following line defines
-;;; an alias which expands to three addresses:
-;;;
-;;; alias foobar addr-1 addr-2 "address three <addr-3>"
-;;;
-;;; (This is bogus because mail-delivery programs want commas, not spaces,
-;;; but that's what the file format is, so we have to live with it.)
-;;;
-;;; If you like, you can call the function define-mail-abbrev to define your
-;;; mail aliases instead of using a .mailrc file. When you call it in this
-;;; way, addresses are separated by commas.
-;;;
-;;; CAVEAT: This works on most Sun systems; I have been told that some versions
-;;; of /bin/mail do not understand double-quotes in the .mailrc file. So you
-;;; should make sure your version does before including verbose addresses like
-;;; this. One solution to this, if you are on a system whose /bin/mail doesn't
-;;; work that way, (and you still want to be able to /bin/mail to send mail in
-;;; addition to emacs) is to define minimal aliases (without full names) in
-;;; your .mailrc file, and use define-mail-abbrev to redefine them when sending
-;;; mail from emacs; this way, mail sent from /bin/mail will work, and mail
-;;; sent from emacs will be pretty.
-;;;
-;;; Aliases in the mailrc file may be nested. If you define aliases like
-;;; alias group1 fred ethel
-;;; alias group2 larry curly moe
-;;; alias everybody group1 group2
-;;; Then when you type "everybody" on the To: line, it will be expanded to
-;;; fred, ethyl, larry, curly, moe
-;;;
-;;; Aliases may also contain forward references; the alias of "everybody" can
-;;; precede the aliases of "group1" and "group2".
-;;;
-;;; This code also understands the "source" .mailrc command, for reading
-;;; aliases from some other file as well.
-;;;
-;;; Aliases may contain hyphens, as in "alias foo-bar foo@bar"; word-abbrevs
-;;; normally cannot contain hyphens, but this code works around that for the
-;;; specific case of mail-alias word-abbrevs.
-;;;
-;;; To read in the contents of another .mailrc-type file from emacs, use the
-;;; command Meta-X merge-mail-abbrevs. The rebuild-mail-abbrevs command is
-;;; similar, but will delete existing aliases first.
-;;;
-;;; If you would like your aliases to be expanded when you type M-> or ^N to
-;;; move out of the mail-header into the message body (instead of having to
-;;; type SPC at the end of the abbrev before moving away) then you can do
-;;;
-;;; (add-hook
-;;; 'mail-setup-hook
-;;; '(lambda ()
-;;; (substitute-key-definition 'next-line 'mail-abbrev-next-line
-;;; mail-mode-map global-map)
-;;; (substitute-key-definition 'end-of-buffer 'mail-abbrev-end-of-buffer
-;;; mail-mode-map global-map)))
-;;;
-;;; If you want multiple addresses separated by a string other than ", " then
-;;; you can set the variable mail-alias-separator-string to it. This has to
-;;; be a comma bracketed by whitespace if you want any kind of reasonable
-;;; behaviour.
-;;;
-;;; Thanks to Harald Hanche-Olsen, Michael Ernst, David Loeffler, and
-;;; Noah Friedman for suggestions and bug reports.
-
-;;; To use this package, do (add-hook 'mail-setup-hook 'mail-abbrevs-setup).
+;; This file ensures that, when the point is in a To:, CC:, BCC:, or From:
+;; field, word-abbrevs are defined for each of your mail aliases. These
+;; aliases will be defined from your .mailrc file (or the file specified by
+;; the MAILRC environment variable) if it exists. Your mail aliases will
+;; expand any time you type a word-delimiter at the end of an abbreviation.
+;;
+;; What you see is what you get: if mailabbrev is in use when you type
+;; a name, and the name does not expand, you know it is not an abbreviation.
+;; However, if you yank abbreviations into the headers
+;; in a way that bypasses the check for abbreviations,
+;; they are expanded (but not visibly) when you send the message.
+;;
+;; Your mail alias abbrevs will be in effect only when the point is in an
+;; appropriate header field. When in the body of the message, or other
+;; header fields, the mail aliases will not expand. Rather, the normal
+;; mode-specific abbrev table (mail-mode-abbrev-table) will be used if
+;; defined. So if you use mail-mode specific abbrevs, this code will not
+;; adversely affect you. You can control which header fields the abbrevs
+;; are used in by changing the variable mail-abbrev-mode-regexp.
+;;
+;; If auto-fill mode is on, abbrevs will wrap at commas instead of at word
+;; boundaries; also, header continuation-lines will be properly indented.
+;;
+;; You can also insert a mail alias with mail-interactive-insert-alias
+;; (bound to C-c C-a), which prompts you for an alias (with completion)
+;; and inserts its expansion at point.
+;;
+;; This file fixes a bug in the old system which prohibited your .mailrc
+;; file from having lines like
+;;
+;; alias someone "John Doe <doe@quux.com>"
+;;
+;; That is, if you want an address to have embedded spaces, simply surround it
+;; with double-quotes. This is necessary because the format of the .mailrc
+;; file bogusly uses spaces as address delimiters. The following line defines
+;; an alias which expands to three addresses:
+;;
+;; alias foobar addr-1 addr-2 "address three <addr-3>"
+;;
+;; (This is bogus because mail-delivery programs want commas, not spaces,
+;; but that's what the file format is, so we have to live with it.)
+;;
+;; If you like, you can call the function define-mail-abbrev to define your
+;; mail aliases instead of using a .mailrc file. When you call it in this
+;; way, addresses are separated by commas.
+;;
+;; CAVEAT: This works on most Sun systems; I have been told that some versions
+;; of /bin/mail do not understand double-quotes in the .mailrc file. So you
+;; should make sure your version does before including verbose addresses like
+;; this. One solution to this, if you are on a system whose /bin/mail doesn't
+;; work that way, (and you still want to be able to /bin/mail to send mail in
+;; addition to emacs) is to define minimal aliases (without full names) in
+;; your .mailrc file, and use define-mail-abbrev to redefine them when sending
+;; mail from emacs; this way, mail sent from /bin/mail will work, and mail
+;; sent from emacs will be pretty.
+;;
+;; Aliases in the mailrc file may be nested. If you define aliases like
+;; alias group1 fred ethel
+;; alias group2 larry curly moe
+;; alias everybody group1 group2
+;; Then when you type "everybody" on the To: line, it will be expanded to
+;; fred, ethyl, larry, curly, moe
+;;
+;; Aliases may also contain forward references; the alias of "everybody" can
+;; precede the aliases of "group1" and "group2".
+;;
+;; This code also understands the "source" .mailrc command, for reading
+;; aliases from some other file as well.
+;;
+;; Aliases may contain hyphens, as in "alias foo-bar foo@bar"; word-abbrevs
+;; normally cannot contain hyphens, but this code works around that for the
+;; specific case of mail-alias word-abbrevs.
+;;
+;; To read in the contents of another .mailrc-type file from emacs, use the
+;; command Meta-X merge-mail-abbrevs. The rebuild-mail-abbrevs command is
+;; similar, but will delete existing aliases first.
+;;
+;; If you would like your aliases to be expanded when you type M-> or ^N to
+;; move out of the mail-header into the message body (instead of having to
+;; type SPC at the end of the abbrev before moving away) then you can do
+;;
+;; (add-hook
+;; 'mail-setup-hook
+;; '(lambda ()
+;; (substitute-key-definition 'next-line 'mail-abbrev-next-line
+;; mail-mode-map global-map)
+;; (substitute-key-definition 'end-of-buffer 'mail-abbrev-end-of-buffer
+;; mail-mode-map global-map)))
+;;
+;; If you want multiple addresses separated by a string other than ", " then
+;; you can set the variable mail-alias-separator-string to it. This has to
+;; be a comma bracketed by whitespace if you want any kind of reasonable
+;; behaviour.
+;;
+;; Thanks to Harald Hanche-Olsen, Michael Ernst, David Loeffler, and
+;; Noah Friedman for suggestions and bug reports.
+
+;; To use this package, do (add-hook 'mail-setup-hook 'mail-abbrevs-setup).
;;; Code:
;;(define-key mail-mode-map "\M->" 'mail-abbrev-end-of-buffer)
(provide 'mailabbrev)
+
+;;; mailabbrev.el ends here.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Copyright (C) 1993 Masanobu UMEDA
;; Author: Masanobu UMEDA <umerin@mse.kyutech.ac.jp>
-;; Version: $Header: /home/gd/gnu/emacs/19.0/lisp/RCS/metamail.el,v 1.1 1993/07/20 03:02:12 rms Exp kwzh $
+;; Version: $Header: /home/gd/gnu/emacs/19.0/lisp/RCS/metamail.el,v 1.2 1996/01/05 00:07:09 kwzh Exp erik $
;; Keywords: mail, news, mime, multimedia
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; LCD Archive Entry:
;; metamail|Masanobu UMEDA|umerin@mse.kyutech.ac.jp|
;; Metamail interface for GNU Emacs|
-;; $Date: 1993/07/20 03:02:12 $|$Revision: 1.1 $|~/misc/metamail.el.Z|
+;; $Date: 1996/01/05 00:07:09 $|$Revision: 1.2 $|~/misc/metamail.el.Z|
;; Note: Metamail does not have all options which are compatible with
;; the environment variables. For that reason, metamail.el has to
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Change Log:
-;; $Id: mh-comp.el,v 1.6 1995/04/25 22:28:25 kwzh Exp kwzh $
+;; $Id: mh-comp.el,v 1.7 1995/11/03 02:28:52 kwzh Exp erik $
;;; Code:
;;; mh-e.el --- GNU Emacs interface to the MH mail system
-;;; Copyright (C) 1985,86,87,88,90,92,93,94,95 Free Software Foundation, Inc.
-
-(defconst mh-e-time-stamp "Time-stamp: <95/10/30 19:14:06 gildea>")
-(defconst mh-e-version "5.0.2"
- "Version numbers of this version of mh-e.")
+;; Copyright (C) 1985,86,87,88,90,92,93,94,95 Free Software Foundation, Inc.
;; Maintainer: Stephen Gildea <gildea@lcs.mit.edu>
;; Version: 5.0.2
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; HOW TO USE:
-;;; M-x mh-rmail to read mail. Type C-h m there for a list of commands.
-;;; C-u M-x mh-rmail to visit any folder.
-;;; M-x mh-smail to send mail. From within the mail reader, "m" works, too.
-
-;;; MH (Message Handler) is a powerful mail reader. The MH newsgroup
-;;; is comp.mail.mh; the mailing list is mh-users@ics.uci.edu (send to
-;;; mh-users-request to be added). See the monthly Frequently Asked
-;;; Questions posting there for information on getting MH and mh-e.
-
-;;; mh-e is an Emacs interface to the MH mail system.
-;;; The mailing list mh-e@x.org is for discussion of mh-e and
-;;; announcements of new versions. Send a "subscribe" message to
-;;; mh-e-request@x.org to be added. Do not report bugs here; mail
-;;; them directly to the author (see top of mh-e.el source).
-;;; Include the output of M-x mh-version in any bug report.
-
-;;; mh-e works with GNU Emacs 18 or 19, and MH 6.
-
-;;; NB. MH must have been compiled with the MHE compiler flag or several
-;;; features necessary for mh-e will be missing from MH commands, specifically
-;;; the -build switch to repl and forw.
-
-;;; Your .emacs might benefit from these bindings:
-;;; (global-set-key "\C-cr" 'mh-rmail)
-;;; (global-set-key "\C-xm" 'mh-smail)
-;;; (global-set-key "\C-x4m" 'mh-smail-other-window)
-
-;;; Change Log:
-
-;;; Original version for Gosling emacs by Brian Reid, Stanford, 1982.
-;;; Modified by James Larus, BBN, July 1984 and UCB, 1984 & 1985.
-;;; Rewritten for GNU Emacs, James Larus 1985. larus@ginger.berkeley.edu
-;;; Modified by Stephen Gildea 1988. gildea@lcs.mit.edu
-(defconst mh-e-RCS-id "$Id: mh-e.el,v 1.9 1995/11/03 02:28:26 kwzh Exp kwzh $")
+;; HOW TO USE:
+;; M-x mh-rmail to read mail. Type C-h m there for a list of commands.
+;; C-u M-x mh-rmail to visit any folder.
+;; M-x mh-smail to send mail. From within the mail reader, "m" works, too.
+
+;; MH (Message Handler) is a powerful mail reader. The MH newsgroup
+;; is comp.mail.mh; the mailing list is mh-users@ics.uci.edu (send to
+;; mh-users-request to be added). See the monthly Frequently Asked
+;; Questions posting there for information on getting MH and mh-e.
+
+;; mh-e is an Emacs interface to the MH mail system.
+;; The mailing list mh-e@x.org is for discussion of mh-e and
+;; announcements of new versions. Send a "subscribe" message to
+;; mh-e-request@x.org to be added. Do not report bugs here; mail
+;; them directly to the author (see top of mh-e.el source).
+;; Include the output of M-x mh-version in any bug report.
+
+;; mh-e works with GNU Emacs 18 or 19, and MH 6.
+
+;; NB. MH must have been compiled with the MHE compiler flag or several
+;; features necessary for mh-e will be missing from MH commands, specifically
+;; the -build switch to repl and forw.
+
+;; Your .emacs might benefit from these bindings:
+;; (global-set-key "\C-cr" 'mh-rmail)
+;; (global-set-key "\C-xm" 'mh-smail)
+;; (global-set-key "\C-x4m" 'mh-smail-other-window)
+
+;; Change Log:
+
+;; Original version for Gosling emacs by Brian Reid, Stanford, 1982.
+;; Modified by James Larus, BBN, July 1984 and UCB, 1984 & 1985.
+;; Rewritten for GNU Emacs, James Larus 1985. larus@ginger.berkeley.edu
+;; Modified by Stephen Gildea 1988. gildea@lcs.mit.edu
+(defconst mh-e-RCS-id "$Id: mh-e.el,v 1.10 1996/01/04 23:45:17 kwzh Exp erik $")
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Internal support for mh-e package.
-;;; Putting these functions in a separate file lets mh-e start up faster,
-;;; since less Lisp code needs to be loaded all at once.
+;; Internal support for mh-e package.
+;; Putting these functions in a separate file lets mh-e start up faster,
+;; since less Lisp code needs to be loaded all at once.
;;; Change Log:
-;; $Id: mh-funcs.el,v 1.3 1995/04/10 00:20:07 kwzh Exp kwzh $
+;; $Id: mh-funcs.el,v 1.4 1995/11/03 02:29:34 kwzh Exp erik $
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Internal support for mh-e package.
-;;; Support for generating an mhn composition file.
-;;; MIME is supported only by MH 6.8 or later.
+;; Internal support for mh-e package.
+;; Support for generating an mhn composition file.
+;; MIME is supported only by MH 6.8 or later.
;;; Change Log:
-;; $Id: mh-mime.el,v 1.4 1995/04/20 23:35:26 kwzh Exp kwzh $
+;; $Id: mh-mime.el,v 1.5 1995/11/03 02:29:49 kwzh Exp erik $
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Change Log:
-;; $Id: mh-pick.el,v 1.3 1995/04/10 00:19:54 kwzh Exp kwzh $
+;; $Id: mh-pick.el,v 1.4 1995/11/03 02:30:09 kwzh Exp erik $
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Change Log:
-;; $Id: mh-seq.el,v 1.3 1995/04/10 00:19:48 kwzh Exp kwzh $
+;; $Id: mh-seq.el,v 1.4 1995/11/03 02:30:17 kwzh Exp erik $
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Change Log:
-;; $Id: mh-utils.el,v 1.6 1995/11/03 02:29:09 kwzh Exp kwzh $
+;; $Id: mh-utils.el,v 1.7 1996/01/09 23:19:28 kwzh Exp erik $
;;; Code:
;;; reporter.el --- customizable bug reporting of lisp programs
+;; Copyright (C) 1993 1994 Barry A. Warsaw
+;; Copyright (C) 1993 1994 Free Software Foundation, Inc.
+
;; Author: 1993 Barry A. Warsaw <bwarsaw@cnri.reston.va.us>
;; Maintainer: bwarsaw@cnri.reston.va.us
;; Created: 19-Apr-1993
;; Last Modified: 1994/11/29 16:13:50
;; Keywords: bug reports lisp
-;; Copyright (C) 1993 1994 Barry A. Warsaw
-;; Copyright (C) 1993 1994 Free Software Foundation, Inc.
-
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; Introduction
;; ============
;; This program is for lisp package authors and can be used to ease
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Change Log:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; Change Log:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; LCD Archive Entry
;; supercite|Barry A. Warsaw|supercite-help@anthem.nlm.nih.gov
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; map-ynp.el --- General-purpose boolean question-asker.
-;;; Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
;; Author: Roland McGrath <roland@gnu.ai.mit.edu>
;; Keywords: lisp, extensions
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; This program is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; A copy of the GNU General Public License can be obtained from this
-;;; program's author (send electronic mail to roland@ai.mit.edu) or from
-;;; the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA
-;;; 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; map-y-or-n-p is a general-purpose question-asking function.
-;;; It asks a series of y/n questions (a la y-or-n-p), and decides to
-;;; applies an action to each element of a list based on the answer.
-;;; The nice thing is that you also get some other possible answers
-;;; to use, reminiscent of query-replace: ! to answer y to all remaining
-;;; questions; ESC or q to answer n to all remaining questions; . to answer
-;;; y once and then n for the remainder; and you can get help with C-h.
+;; map-y-or-n-p is a general-purpose question-asking function.
+;; It asks a series of y/n questions (a la y-or-n-p), and decides to
+;; applies an action to each element of a list based on the answer.
+;; The nice thing is that you also get some other possible answers
+;; to use, reminiscent of query-replace: ! to answer y to all remaining
+;; questions; ESC or q to answer n to all remaining questions; . to answer
+;; y once and then n for the remainder; and you can get help with C-h.
;;; Code:
;;; menu-bar.el --- define a default menu bar.
+;; Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
+
;; Author: RMS
;; Keywords: internal
-;; Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
-
;; This file is part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; Avishai Yacobi suggested some menu rearrangements.
+;;; Code:
+
;;; User options:
(defvar buffers-menu-max-size 10
If this is nil, then all buffers are shown.
A large number or nil slows down menu responsiveness.")
-;;; Code:
-
;; Don't clobber an existing menu-bar keymap, to preserve any menu-bar key
;; definitions made in loaddefs.el.
(or (lookup-key global-map [menu-bar])
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; mldrag.el --- mode line and vertical line dragging to resize windows
-;;; Copyright (C) 1994 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994 Free Software Foundation, Inc.
;; Author: Kyle E. Jones <kyle@wonderworks.com>
;; Keywords: mouse
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
;;; Commentary:
-;;
+
;; This module provides multi-click mouse support for GNU Emacs versions
;; 19.18 and later. I've tried to make it behave more like standard X
;; clients (eg. xterm) than the default Emacs 19 mouse selection handlers.
;;
;; (overlay-put mouse-drag-overlay 'face 'bold)
-;;; Code: =================================================================
+;;; Code:
(provide 'mouse-sel)
;;; msb.el --- Customizable buffer-selection with multiple menus.
+
;; Copyright (C) 1993, 1994, 1995 Lars Lindberg <Lars.Lindberg@sypro.cap.se>
-;;
+
;; Author: Lars Lindberg <Lars.Lindberg@sypro.cap.se>
;; Created: 8 Oct 1993
;; Lindberg's last update version: 3.31
;; Keywords: mouse buffer menu
-;;
-;; This program is free software; you can redistribute it and/or modify
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2 of the License, or
-;; (at your option) any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; Purpose of this package:
;; 1. Offer a function for letting the user choose buffer,
;; not necessarily for switching to it.
;;; nndir.el --- single directory newsgroup access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nndoc.el --- single file access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nneething.el --- random file access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnfolder.el --- mail folder access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Scott Byer <byer@mv.us.adobe.com>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnheader.el --- header access macros for Gnus and its backends
+
;; Copyright (C) 1987,88,89,90,93,94,95 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnkiboze.el --- select virtual news access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnmail.el --- mail support functions for the Gnus mail backends
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnmbox.el --- mail mbox access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnmh.el --- mhspool access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnml.el --- mail spool access for Gnus
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnspool.el --- spool access for GNU Emacs
+
;; Copyright (C) 1988,89,90,93,94,95 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nntp.el --- nntp access for Gnus
+
;; Copyright (C) 1987,88,89,90,92,93,94,95 Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; nnvirtual.el --- virtual newsgroups access for Gnus
+
;; Copyright (C) 1994,95 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; paren.el --- highlight matching paren.
+
;; Copyright (C) 1993 Free Software Foundation, Inc.
;; Author: rms@gnu.ai.mit.edu
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-; by F. Thomas May <uw-nsr!uw-warp!tom@beaver.cs.washington.edu>
-; doc comment by Root Boy Jim <rbj@dsys.icst.nbs.gov>, 27 Apr 89
-; interface improvements by ESR, Dec 5 1991.
-
-; The object of the game is to find four hidden balls by shooting rays
-; into the black box. There are four possibilities: 1) the ray will
-; pass thru the box undisturbed, 2) it will hit a ball and be absorbed,
-; 3) it will be deflected and exit the box, or 4) be deflected immediately,
-; not even being allowed entry into the box.
-;
-; The strange part is the method of deflection. It seems that rays will
-; not pass next to a ball, and change direction at right angles to avoid it.
-;
-; R 3
-; 1 - - - - - - - - 1
-; - - - - - - - -
-; - O - - - - - - 3
-; 2 - - - - O - O -
-; 4 - - - - - - - -
-; 5 - - - - - - - - 5
-; - - - - - - - - R
-; H - - - - - - - O
-; 2 H 4 H
-;
-; Rays which enter and exit are numbered. You can see that rays 1 & 5 pass
-; thru the box undisturbed. Ray 2 is deflected by the northwesternmost
-; ball. Likewise rays 3 and 4. Rays which hit balls and are absorbed are
-; marked with H. The bottom of the left and the right of the bottom hit
-; the southeastern ball directly. Rays may also hit balls after being
-; reflected. Consider the H on the bottom next to the 4. It bounces off
-; the NW-ern most ball and hits the central ball. A ray shot from above
-; the right side 5 would hit the SE-ern most ball. The R beneath the 5
-; is because the ball is returned instantly. It is not allowed into
-; the box if it would reflect immediately. The R on the top is a more
-; leisurely return. Both central balls would tend to deflect it east
-; or west, but it cannot go either way, so it just retreats.
-;
-; At the end of the game, if you've placed guesses for as many balls as
-; there are in the box, the true board position will be revealed. Each
-; `x' is an incorrect guess of yours; `o' is the true location of a ball.
+;; by F. Thomas May <uw-nsr!uw-warp!tom@beaver.cs.washington.edu>
+;; doc comment by Root Boy Jim <rbj@dsys.icst.nbs.gov>, 27 Apr 89
+;; interface improvements by ESR, Dec 5 1991.
+
+;; The object of the game is to find four hidden balls by shooting rays
+;; into the black box. There are four possibilities: 1) the ray will
+;; pass thru the box undisturbed, 2) it will hit a ball and be absorbed,
+;; 3) it will be deflected and exit the box, or 4) be deflected immediately,
+;; not even being allowed entry into the box.
+;;
+;; The strange part is the method of deflection. It seems that rays will
+;; not pass next to a ball, and change direction at right angles to avoid it.
+;;
+;; R 3
+;; 1 - - - - - - - - 1
+;; - - - - - - - -
+;; - O - - - - - - 3
+;; 2 - - - - O - O -
+;; 4 - - - - - - - -
+;; 5 - - - - - - - - 5
+;; - - - - - - - - R
+;; H - - - - - - - O
+;; 2 H 4 H
+;;
+;; Rays which enter and exit are numbered. You can see that rays 1 & 5 pass
+;; thru the box undisturbed. Ray 2 is deflected by the northwesternmost
+;; ball. Likewise rays 3 and 4. Rays which hit balls and are absorbed are
+;; marked with H. The bottom of the left and the right of the bottom hit
+;; the southeastern ball directly. Rays may also hit balls after being
+;; reflected. Consider the H on the bottom next to the 4. It bounces off
+;; the NW-ern most ball and hits the central ball. A ray shot from above
+;; the right side 5 would hit the SE-ern most ball. The R beneath the 5
+;; is because the ball is returned instantly. It is not allowed into
+;; the box if it would reflect immediately. The R on the top is a more
+;; leisurely return. Both central balls would tend to deflect it east
+;; or west, but it cannot go either way, so it just retreats.
+;;
+;; At the end of the game, if you've placed guesses for as many balls as
+;; there are in the box, the true board position will be revealed. Each
+;; `x' is an incorrect guess of yours; `o' is the true location of a ball.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; dunnet.el --- Text adventure for Emacs
+;; Copyright (C) 1992, 1993 Free Software Foundation, Inc.
+
;; Author: Ron Schnell <ronnie@media.mit.edu>
;; Created: 25 Jul 1992
;; Version: 2.0
;; Keywords: games
-;; Copyright (C) 1992, 1993 Free Software Foundation, Inc.
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Gomoku game between you and GNU Emacs. Last modified on 13 Sep 1988
-;;;
-;;; Written by Ph. Schnoebelen (phs@lifia.imag.fr), 1987, 1988
-;;; with precious advices from J.-F. Rit.
-;;; This has been tested with GNU Emacs 18.50.
+;; Gomoku game between you and GNU Emacs. Last modified on 13 Sep 1988
+;;
+;; Written by Ph. Schnoebelen (phs@lifia.imag.fr), 1987, 1988
+;; with precious advices from J.-F. Rit.
+;; This has been tested with GNU Emacs 18.50.
;; RULES:
;;
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; mpuz.el --- multiplication puzzle for GNU Emacs
-;;; Copyright (C) 1990 Free Software Foundation, Inc.
+;; Copyright (C) 1990 Free Software Foundation, Inc.
;; Author: Philippe Schnoebelen <phs@lifia.imag.fr>
;; Keywords: games
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-; Steve Strassmann <straz@media-lab.media.mit.edu> didn't write
-; this, and even if he did, he really didn't mean for you to use it
-; in an anarchistic way.
-;
-; To use this:
-; Just before sending mail, do M-x spook.
-; A number of phrases will be inserted into your buffer, to help
-; give your message that extra bit of attractiveness for automated
-; keyword scanners. Help defeat the NSA trunk trawler!
+;; Steve Strassmann <straz@media-lab.media.mit.edu> didn't write
+;; this, and even if he did, he really didn't mean for you to use it
+;; in an anarchistic way.
+;;
+;; To use this:
+;; Just before sending mail, do M-x spook.
+;; A number of phrases will be inserted into your buffer, to help
+;; give your message that extra bit of attractiveness for automated
+;; keyword scanners. Help defeat the NSA trunk trawler!
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; This mode is a complete rewrite of a major mode for editing Ada 83
;;; and Ada 95 source code under Emacs-19. It contains completely new
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; c-mode.el --- C code editing commands for Emacs
+
;; Copyright (C) 1985, 86, 87, 92, 94, 95 Free Software Foundation, Inc.
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Copyright (C) 1992, 1994 Free Software Foundation, Inc.
;; Author: Francesco Potorti` <pot@cnuce.cnr.it>
-;; Version: $Id: cmacexp.el,v 1.19 1995/03/07 15:24:44 pot Exp rms $
+;; Version: $Id: cmacexp.el,v 1.20 1995/10/26 03:14:40 rms Exp erik $
;; Adapted-By: ESR
;; Keywords: c
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; USAGE =============================================================
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; cplus-md.el --- C++ code editing commands for Emacs
-;;; Copyright (C) 1985, 1992, 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1985, 1992, 1994, 1995 Free Software Foundation, Inc.
+
+;; Maintainer: Dave Detlefs <dld@cs.cmu.edu>
+;; Keywords: c
;; This file is part of GNU Emacs.
-;; Keywords: c languages oop
;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-;; Maintainer: Dave Detlefs <dld@cs.cmu.edu>
-;; Keywords: c
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; executable.el --- base functionality for executable interpreter scripts
-;; Copyright (C) 1994, 1995 by Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995, 1996 by Free Software Foundation, Inc.
;; Author: Daniel.Pfeiffer@Informatik.START.dbp.de, fax (+49 69) 7588-2389
;; Keywords: languages, unix
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; f90.el --- Fortran-90 mode (free format)
-;; Copyright (C) 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1995, 1996 Free Software Foundation, Inc.
;; Author: Torbj\"orn Einarsson <T.Einarsson@clab.ericsson.se>
;; Created: Sep. 21, 1995
;; Keywords: fortran, f90, languages
-;; This program is free software; you can redistribute it and/or modify
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2 of the License, or
-;; (at your option) any later version.
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;; This program is distributed in the hope that it will be useful,
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
+
;; Smart mode for editing F90 programs in FREE FORMAT.
;; Knows about continuation lines, named structured statements, and other
;; new features in F90 including HPF (High Performance Fortran) structures.
;; Also thanks to the authors of the fortran and pascal modes, on which some
;; of this code is built.
-
;;; Code:
+
(defconst bug-f90-mode "T.Einarsson@clab.ericsson.se"
"Address of mailing list for F90 mode bugs.")
;;; fortran.el --- Fortran mode for GNU Emacs
-;;; Copyright (c) 1986, 1993, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (c) 1986, 1993, 1994, 1995 Free Software Foundation, Inc.
;; Author: Michael D. Prange <prange@erl.mit.edu>
;; Maintainer: bug-fortran-mode@erl.mit.edu
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Dr. Anil Gokhale, Ulrich Mueller, Mark Neale, Eric Prestemon,
;; Gary Sabot and Richard Stallman.
-;;; This file may be used with GNU Emacs version 18.xx if the following
-;;; variable and function substitutions are made.
-;;; Replace:
-;;; frame-width with screen-width
-;;; auto-fill-function with auto-fill-hook
-;;; comment-indent-function with comment-indent-hook
-;;; (setq unread-command-events (list c)) with (setq unread-command-char c)
+;; This file may be used with GNU Emacs version 18.xx if the following
+;; variable and function substitutions are made.
+;; Replace:
+;; frame-width with screen-width
+;; auto-fill-function with auto-fill-hook
+;; comment-indent-function with comment-indent-hook
+;; (setq unread-command-events (list c)) with (setq unread-command-char c)
-;;; Bugs to bug-fortran-mode@erl.mit.edu
-
-(defconst fortran-mode-version "version 1.30.6")
+;; Bugs to bug-fortran-mode@erl.mit.edu
;;; Code:
+(defconst fortran-mode-version "version 1.30.6")
+
;;;###autoload
(defvar fortran-tab-mode-default nil
"*Default tabbing/carriage control style for empty files in Fortran mode.
(provide 'fortran)
;;; fortran.el ends here
-
;;; hide-ifdef-mode.el --- hides selected code within ifdef.
-;;; Copyright (C) 1988, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1988, 1994 Free Software Foundation, Inc.
;; Author: Dan LaLiberte <liberte@a.cs.uiuc.edu>
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; To initialize, toggle the hide-ifdef minor mode with
-;;;
-;;; M-x hide-ifdef-mode
-;;;
-;;; This will set up key bindings and call hide-ifdef-mode-hook if it
-;;; has a value. To explicitly hide ifdefs using a buffer-local
-;;; define list (default empty), type
-;;;
-;;; M-x hide-ifdefs or C-c @ h
-;;;
-;;; Hide-ifdef suppresses the display of code that the preprocessor wouldn't
-;;; pass through. The support of constant expressions in #if lines is
-;;; limited to identifiers, parens, and the operators: &&, ||, !, and
-;;; "defined". Please extend this.
-;;;
-;;; The hidden code is marked by ellipses (...). Be
-;;; cautious when editing near ellipses, since the hidden text is
-;;; still in the buffer, and you can move the point into it and modify
-;;; text unawares. If you don't want to see the ellipses, set
-;;; selective-display-ellipses to nil. But this can be dangerous.
-;;; You can make your buffer read-only while hide-ifdef-hiding by setting
-;;; hide-ifdef-read-only to a non-nil value. You can toggle this
-;;; variable with hide-ifdef-toggle-read-only (C-c @ C-q).
-;;;
-;;; You can undo the effect of hide-ifdefs by typing
-;;;
-;;; M-x show-ifdefs or C-c @ s
-;;;
-;;; Use M-x hide-ifdef-define (C-c @ d) to define a symbol.
-;;; Use M-x hide-ifdef-undef (C-c @ u) to undefine a symbol.
-;;;
-;;; If you define or undefine a symbol while hide-ifdef-mode is in effect,
-;;; the display will be updated. Only the define list for the current
-;;; buffer will be affected. You can save changes to the local define
-;;; list with hide-ifdef-set-define-alist. This adds entries
-;;; to hide-ifdef-define-alist.
-;;;
-;;; If you have defined a hide-ifdef-mode-hook, you can set
-;;; up a list of symbols that may be used by hide-ifdefs as in the
-;;; following example:
-;;;
-;;; (setq hide-ifdef-mode-hook
-;;; '(lambda ()
-;;; (if (not hide-ifdef-define-alist)
-;;; (setq hide-ifdef-define-alist
-;;; '((list1 ONE TWO)
-;;; (list2 TWO THREE)
-;;; )))
-;;; (hide-ifdef-use-define-alist 'list2) ; use list2 by default
-;;; ))
-;;;
-;;; You can call hide-ifdef-use-define-alist (C-c @ u) at any time to specify
-;;; another list to use.
-;;;
-;;; To cause ifdefs to be hidden as soon as hide-ifdef-mode is called,
-;;; set hide-ifdef-initially to non-nil.
-;;;
-;;; If you set hide-ifdef-lines to t, hide-ifdefs hides all the #ifdef lines.
-;;; In the absence of highlighting, that might be a bad idea. If you set
-;;; hide-ifdef-lines to nil (the default), the surrounding preprocessor
-;;; lines will be displayed. That can be confusing in its own
-;;; right. Other variations on display are possible, but not much
-;;; better.
-;;;
-;;; You can explicitly hide or show individual ifdef blocks irrespective
-;;; of the define list by using hide-ifdef-block and show-ifdef-block.
-;;;
-;;; You can move the point between ifdefs with forward-ifdef, backward-ifdef,
-;;; up-ifdef, down-ifdef, next-ifdef, and previous-ifdef.
-;;;
-;;; If you have minor-mode-alist in your mode line (the default) two labels
-;;; may appear. "Ifdef" will appear when hide-ifdef-mode is active. "Hiding"
-;;; will appear when text may be hidden ("hide-ifdef-hiding" is non-nil).
-;;;
-;;; Written by Brian Marick, at Gould, Computer Systems Division, Urbana IL.
-;;; Extensively modified by Daniel LaLiberte (while at Gould).
-;;;
-;;; You may freely modify and distribute this, but keep a record
-;;; of modifications and send comments to:
-;;; liberte@a.cs.uiuc.edu or ihnp4!uiucdcs!liberte
-;;; I will continue to upgrade hide-ifdef-mode
-;;; with your contributions.
+;; To initialize, toggle the hide-ifdef minor mode with
+;;
+;; M-x hide-ifdef-mode
+;;
+;; This will set up key bindings and call hide-ifdef-mode-hook if it
+;; has a value. To explicitly hide ifdefs using a buffer-local
+;; define list (default empty), type
+;;
+;; M-x hide-ifdefs or C-c @ h
+;;
+;; Hide-ifdef suppresses the display of code that the preprocessor wouldn't
+;; pass through. The support of constant expressions in #if lines is
+;; limited to identifiers, parens, and the operators: &&, ||, !, and
+;; "defined". Please extend this.
+;;
+;; The hidden code is marked by ellipses (...). Be
+;; cautious when editing near ellipses, since the hidden text is
+;; still in the buffer, and you can move the point into it and modify
+;; text unawares. If you don't want to see the ellipses, set
+;; selective-display-ellipses to nil. But this can be dangerous.
+;; You can make your buffer read-only while hide-ifdef-hiding by setting
+;; hide-ifdef-read-only to a non-nil value. You can toggle this
+;; variable with hide-ifdef-toggle-read-only (C-c @ C-q).
+;;
+;; You can undo the effect of hide-ifdefs by typing
+;;
+;; M-x show-ifdefs or C-c @ s
+;;
+;; Use M-x hide-ifdef-define (C-c @ d) to define a symbol.
+;; Use M-x hide-ifdef-undef (C-c @ u) to undefine a symbol.
+;;
+;; If you define or undefine a symbol while hide-ifdef-mode is in effect,
+;; the display will be updated. Only the define list for the current
+;; buffer will be affected. You can save changes to the local define
+;; list with hide-ifdef-set-define-alist. This adds entries
+;; to hide-ifdef-define-alist.
+;;
+;; If you have defined a hide-ifdef-mode-hook, you can set
+;; up a list of symbols that may be used by hide-ifdefs as in the
+;; following example:
+;;
+;; (setq hide-ifdef-mode-hook
+;; '(lambda ()
+;; (if (not hide-ifdef-define-alist)
+;; (setq hide-ifdef-define-alist
+;; '((list1 ONE TWO)
+;; (list2 TWO THREE)
+;; )))
+;; (hide-ifdef-use-define-alist 'list2) ; use list2 by default
+;; ))
+;;
+;; You can call hide-ifdef-use-define-alist (C-c @ u) at any time to specify
+;; another list to use.
+;;
+;; To cause ifdefs to be hidden as soon as hide-ifdef-mode is called,
+;; set hide-ifdef-initially to non-nil.
+;;
+;; If you set hide-ifdef-lines to t, hide-ifdefs hides all the #ifdef lines.
+;; In the absence of highlighting, that might be a bad idea. If you set
+;; hide-ifdef-lines to nil (the default), the surrounding preprocessor
+;; lines will be displayed. That can be confusing in its own
+;; right. Other variations on display are possible, but not much
+;; better.
+;;
+;; You can explicitly hide or show individual ifdef blocks irrespective
+;; of the define list by using hide-ifdef-block and show-ifdef-block.
+;;
+;; You can move the point between ifdefs with forward-ifdef, backward-ifdef,
+;; up-ifdef, down-ifdef, next-ifdef, and previous-ifdef.
+;;
+;; If you have minor-mode-alist in your mode line (the default) two labels
+;; may appear. "Ifdef" will appear when hide-ifdef-mode is active. "Hiding"
+;; will appear when text may be hidden ("hide-ifdef-hiding" is non-nil).
+;;
+;; Written by Brian Marick, at Gould, Computer Systems Division, Urbana IL.
+;; Extensively modified by Daniel LaLiberte (while at Gould).
+;;
+;; You may freely modify and distribute this, but keep a record
+;; of modifications and send comments to:
+;; liberte@a.cs.uiuc.edu or ihnp4!uiucdcs!liberte
+;; I will continue to upgrade hide-ifdef-mode
+;; with your contributions.
;;; Code:
;;; hideshow.el --- minor mode cmds to selectively display blocks of code
-;;; Copyright (C) 1994,1995 Free Software Foundation
-
-;;; Author: Thien-Thi Nguyen <ttn@netcom.com>
-;;; Version: 3.4
-;;; Keywords: C C++ lisp tools editing
-;;; Time-of-Day-Author-Most-Likely-to-be-Recalcitrant: early morning
-
-;;; This file is part of GNU Emacs.
-
-;;; GNU Emacs is free software; you can redistribute it and/or modify it
-;;; under the terms of the GNU General Public License as published by the
-;;; Free Software Foundation; either version 2 of the License, or (at your
-;;; option) any later version.
-;;;
-;;; GNU Emacs is distributed in the hope that it will be useful, but WITHOUT
-;;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-;;; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
-;;; for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License along
-;;; with this program; if not, write to the Free Software Foundation, Inc.,
-;;; 675 Mass Ave, Cambridge, MA 02139, USA.
-
-;;; LCD Archive Entry:
-;;; hideshow|Thien-Thi Nguyen|ttn@netcom.com|
-;;; minor mode commands to selectively display blocks of code|
-;;; 18-Oct-1994|3.4|~/modes/hideshow.el.Z|
+;; Copyright (C) 1994,1995 Free Software Foundation
+
+;; Author: Thien-Thi Nguyen <ttn@netcom.com>
+;; Version: 3.4
+;; Keywords: C C++ lisp tools editing
+;; Time-of-Day-Author-Most-Likely-to-be-Recalcitrant: early morning
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;; LCD Archive Entry:
+;; hideshow|Thien-Thi Nguyen|ttn@netcom.com|
+;; minor mode commands to selectively display blocks of code|
+;; 18-Oct-1994|3.4|~/modes/hideshow.el.Z|
;;; Commentary:
-;;; This file provides `hs-minor-mode'. When active, six commands:
-;;; hs-{hide,show}-{all,block}, hs-show-region and hs-minor-mode
-;;; are available. They implement block hiding and showing. Blocks are
-;;; defined in mode-specific way. In c-mode or c++-mode, they are simply
-;;; curly braces, while in lisp-ish modes they are parens. Multi-line
-;;; comments (c-mode) can also be hidden. The command M-x hs-minor-mode
-;;; toggles the minor mode or sets it (similar to outline minor mode).
-;;; See documentation for each command for more info.
-;;;
-;;; The variable `hs-unbalance-handler-method' controls hideshow's behavior
-;;; in the case of "unbalanced parentheses". See doc for more info.
-
-;;; Suggested usage:
-
-;;; (load-library "hideshow")
-;;; (defun my-hs-setup () "enables hideshow and binds some commands"
-;;; (hs-minor-mode 1)
-;;; (define-key hs-minor-mode-map "\C-ch" 'hs-hide-block)
-;;; (define-key hs-minor-mode-map "\C-cs" 'hs-show-block)
-;;; (define-key hs-minro-mode-map "\C-cH" 'hs-hide-all)
-;;; (define-key hs-minro-mode-map "\C-cS" 'hs-show-all)
-;;; (define-key hs-minor-mode-map "\C-cR" 'hs-show-region))
-;;; (add-hook 'X-mode-hook 'my-hs-setup t) ; other modes similarly
-;;;
-;;; where X = {emacs-lisp,c,c++,perl,...}. See the doc for the variable
-;;; `hs-special-modes-alist' if you'd like to use hideshow w/ other modes.
-
-;;; Etc:
-
-;;; Bug reports and fixes welcome (comments, too). Thanks go to
-;;; Dean Andrews <adahome@ix.netcom.com>
-;;; Preston F. Crow <preston.f.crow@dartmouth.edu>
-;;; Gael Marziou <gael@gnlab030.grenoble.hp.com>
-;;; Keith Sheffield <sheff@edcsgw2.cr.usgs.gov>
-;;; Jan Djarv <jan.djarv@sa.erisoft.se>
-;;; Lars Lindberg <qhslali@aom.ericsson.se>
-;;; Alf-Ivar Holm <alfh@ifi.uio.no>
-;;; for valuable feedback, code and bug reports.
+;; This file provides `hs-minor-mode'. When active, six commands:
+;; hs-{hide,show}-{all,block}, hs-show-region and hs-minor-mode
+;; are available. They implement block hiding and showing. Blocks are
+;; defined in mode-specific way. In c-mode or c++-mode, they are simply
+;; curly braces, while in lisp-ish modes they are parens. Multi-line
+;; comments (c-mode) can also be hidden. The command M-x hs-minor-mode
+;; toggles the minor mode or sets it (similar to outline minor mode).
+;; See documentation for each command for more info.
+;;
+;; The variable `hs-unbalance-handler-method' controls hideshow's behavior
+;; in the case of "unbalanced parentheses". See doc for more info.
+
+;; Suggested usage:
+
+;; (load-library "hideshow")
+;; (defun my-hs-setup () "enables hideshow and binds some commands"
+;; (hs-minor-mode 1)
+;; (define-key hs-minor-mode-map "\C-ch" 'hs-hide-block)
+;; (define-key hs-minor-mode-map "\C-cs" 'hs-show-block)
+;; (define-key hs-minro-mode-map "\C-cH" 'hs-hide-all)
+;; (define-key hs-minro-mode-map "\C-cS" 'hs-show-all)
+;; (define-key hs-minor-mode-map "\C-cR" 'hs-show-region))
+;; (add-hook 'X-mode-hook 'my-hs-setup t) ; other modes similarly
+;;
+;; where X = {emacs-lisp,c,c++,perl,...}. See the doc for the variable
+;; `hs-special-modes-alist' if you'd like to use hideshow w/ other modes.
+
+;; Etc:
+
+;; Bug reports and fixes welcome (comments, too). Thanks go to
+;; Dean Andrews <adahome@ix.netcom.com>
+;; Preston F. Crow <preston.f.crow@dartmouth.edu>
+;; Gael Marziou <gael@gnlab030.grenoble.hp.com>
+;; Keith Sheffield <sheff@edcsgw2.cr.usgs.gov>
+;; Jan Djarv <jan.djarv@sa.erisoft.se>
+;; Lars Lindberg <qhslali@aom.ericsson.se>
+;; Alf-Ivar Holm <alfh@ifi.uio.no>
+;; for valuable feedback, code and bug reports.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; inf-lisp.el --- an inferior-lisp mode
-;;; Copyright (C) 1988, 1993, 1994 Free Software Foundation, Inc.
+
+;; Copyright (C) 1988, 1993, 1994 Free Software Foundation, Inc.
;; Author: Olin Shivers <shivers@cs.cmu.edu>
;; Keywords: processes, lisp
-;;; This file is part of GNU Emacs.
+;; This file is part of GNU Emacs.
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Hacked from tea.el by Olin Shivers (shivers@cs.cmu.edu). 8/88
-
-;;; This file defines a a lisp-in-a-buffer package (inferior-lisp
-;;; mode) built on top of comint mode. This version is more
-;;; featureful, robust, and uniform than the Emacs 18 version. The
-;;; key bindings are also more compatible with the bindings of Hemlock
-;;; and Zwei (the Lisp Machine emacs).
-
-;;; Since this mode is built on top of the general command-interpreter-in-
-;;; a-buffer mode (comint mode), it shares a common base functionality,
-;;; and a common set of bindings, with all modes derived from comint mode.
-;;; This makes these modes easier to use.
-
-;;; For documentation on the functionality provided by comint mode, and
-;;; the hooks available for customising it, see the file comint.el.
-;;; For further information on inferior-lisp mode, see the comments below.
-
-;;; Needs fixin:
-;;; The load-file/compile-file default mechanism could be smarter -- it
-;;; doesn't know about the relationship between filename extensions and
-;;; whether the file is source or executable. If you compile foo.lisp
-;;; with compile-file, then the next load-file should use foo.bin for
-;;; the default, not foo.lisp. This is tricky to do right, particularly
-;;; because the extension for executable files varies so much (.o, .bin,
-;;; .lbin, .mo, .vo, .ao, ...).
-;;;
-;;; It would be nice if inferior-lisp (and inferior scheme, T, ...) modes
-;;; had a verbose minor mode wherein sending or compiling defuns, etc.
-;;; would be reflected in the transcript with suitable comments, e.g.
-;;; ";;; redefining fact". Several ways to do this. Which is right?
-;;;
-;;; When sending text from a source file to a subprocess, the process-mark can
-;;; move off the window, so you can lose sight of the process interactions.
-;;; Maybe I should ensure the process mark is in the window when I send
-;;; text to the process? Switch selectable?
+;; Hacked from tea.el by Olin Shivers (shivers@cs.cmu.edu). 8/88
+
+;; This file defines a a lisp-in-a-buffer package (inferior-lisp
+;; mode) built on top of comint mode. This version is more
+;; featureful, robust, and uniform than the Emacs 18 version. The
+;; key bindings are also more compatible with the bindings of Hemlock
+;; and Zwei (the Lisp Machine emacs).
+
+;; Since this mode is built on top of the general command-interpreter-in-
+;; a-buffer mode (comint mode), it shares a common base functionality,
+;; and a common set of bindings, with all modes derived from comint mode.
+;; This makes these modes easier to use.
+
+;; For documentation on the functionality provided by comint mode, and
+;; the hooks available for customising it, see the file comint.el.
+;; For further information on inferior-lisp mode, see the comments below.
+
+;; Needs fixin:
+;; The load-file/compile-file default mechanism could be smarter -- it
+;; doesn't know about the relationship between filename extensions and
+;; whether the file is source or executable. If you compile foo.lisp
+;; with compile-file, then the next load-file should use foo.bin for
+;; the default, not foo.lisp. This is tricky to do right, particularly
+;; because the extension for executable files varies so much (.o, .bin,
+;; .lbin, .mo, .vo, .ao, ...).
+;;
+;; It would be nice if inferior-lisp (and inferior scheme, T, ...) modes
+;; had a verbose minor mode wherein sending or compiling defuns, etc.
+;; would be reflected in the transcript with suitable comments, e.g.
+;; ";;; redefining fact". Several ways to do this. Which is right?
+;;
+;; When sending text from a source file to a subprocess, the process-mark can
+;; move off the window, so you can lose sight of the process interactions.
+;; Maybe I should ensure the process mark is in the window when I send
+;; text to the process? Switch selectable?
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Commentary:
-;;; USAGE
-;;; =====
-
-;;; Emacs should enter Pascal mode when you find a Pascal source file.
-;;; When you have entered Pascal mode, you may get more info by pressing
-;;; C-h m. You may also get online help describing various functions by:
-;;; C-h f <Name of function you want described>
-
-;;; If you want to customize Pascal mode to fit you better, you may add
-;;; these lines (the values of the variables presented here are the defaults):
-;;;
-;;; ;; User customization for Pascal mode
-;;; (setq pascal-indent-level 3
-;;; pascal-case-indent 2
-;;; pascal-auto-newline nil
-;;; pascal-tab-always-indent t
-;;; pascal-auto-endcomments t
-;;; pascal-auto-lineup '(all)
-;;; pascal-toggle-completions nil
-;;; pascal-type-keywords '("array" "file" "packed" "char"
-;;; "integer" "real" "string" "record")
-;;; pascal-start-keywords '("begin" "end" "function" "procedure"
-;;; "repeat" "until" "while" "read" "readln"
-;;; "reset" "rewrite" "write" "writeln")
-;;; pascal-separator-keywords '("downto" "else" "mod" "div" "then"))
-
-;;; KNOWN BUGS / BUGREPORTS
-;;; =======================
-;;; As far as I know, there are no bugs in the current version of this
-;;; package. This may not be true however, since I never use this mode
-;;; myself and therefore would never notice them anyway. If you do
-;;; find any bugs, you may submit them to: espensk@stud.cs.uit.no
-;;; as well as to bug-gnu-emacs@prep.ai.mit.edu.
+;; USAGE
+;; =====
+
+;; Emacs should enter Pascal mode when you find a Pascal source file.
+;; When you have entered Pascal mode, you may get more info by pressing
+;; C-h m. You may also get online help describing various functions by:
+;; C-h f <Name of function you want described>
+
+;; If you want to customize Pascal mode to fit you better, you may add
+;; these lines (the values of the variables presented here are the defaults):
+;;
+;; ;; User customization for Pascal mode
+;; (setq pascal-indent-level 3
+;; pascal-case-indent 2
+;; pascal-auto-newline nil
+;; pascal-tab-always-indent t
+;; pascal-auto-endcomments t
+;; pascal-auto-lineup '(all)
+;; pascal-toggle-completions nil
+;; pascal-type-keywords '("array" "file" "packed" "char"
+;; "integer" "real" "string" "record")
+;; pascal-start-keywords '("begin" "end" "function" "procedure"
+;; "repeat" "until" "while" "read" "readln"
+;; "reset" "rewrite" "write" "writeln")
+;; pascal-separator-keywords '("downto" "else" "mod" "div" "then"))
+
+;; KNOWN BUGS / BUGREPORTS
+;; =======================
+;; As far as I know, there are no bugs in the current version of this
+;; package. This may not be true however, since I never use this mode
+;; myself and therefore would never notice them anyway. If you do
+;; find any bugs, you may submit them to: espensk@stud.cs.uit.no
+;; as well as to bug-gnu-emacs@prep.ai.mit.edu.
\f
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; sh-script.el --- shell-script editing commands for Emacs
+
;; Copyright (C) 1993, 1994, 1995, 1996 by Free Software Foundation, Inc.
;; Author: Daniel.Pfeiffer@Informatik.START.dbp.de, fax (+49 69) 7588-2389
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;; LCD Archive Entry:
;; ps-print|James C. Thompson|thompson@wg2.waii.com|
;;; rcompile.el --- run a compilation on a remote machine
-;;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
;; Author: Albert <alon@milcse.rtsg.mot.com>
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This package is for running a remote compilation and using emacs to parse
-;;; the error messages. It works by rsh'ing the compilation to a remote host
-;;; and parsing the output. If the file visited at the time remote-compile was
-;;; called was loaded remotely (ange-ftp), the host and user name are obtained
-;;; by the calling ange-ftp-ftp-name on the current directory. In this case the
-;;; next-error command will also ange-ftp the files over. This is achieved
-;;; automatically because the compilation-parse-errors function uses
-;;; default-directory to build it's file names. If however the file visited was
-;;; loaded locally, remote-compile prompts for a host and user and assumes the
-;;; files mounted locally (otherwise, how was the visited file loaded).
-
-;;; See the user defined variables section for more info.
-
-;;; I was contemplating redefining "compile" to "remote-compile" automatically
-;;; if the file visited was ange-ftp'ed but decided against it for now. If you
-;;; feel this is a good idea, let me know and I'll consider it again.
-
-;;; Installation:
-
-;;; To use rcompile, you also need to give yourself permission to connect to
-;;; the remote host. You do this by putting lines like:
-
-;;; monopoly alon
-;;; vme33
-;;;
-;;; in a file named .rhosts in the home directory (of the remote machine).
-;;; Be careful what you put in this file. A line like:
-;;;
-;;; +
-;;;
-;;; Will allow anyone access to your account without a password. I suggest you
-;;; read the rhosts(5) manual page before you edit this file (if you are not
-;;; familiar with it already)
+;; This package is for running a remote compilation and using emacs to parse
+;; the error messages. It works by rsh'ing the compilation to a remote host
+;; and parsing the output. If the file visited at the time remote-compile was
+;; called was loaded remotely (ange-ftp), the host and user name are obtained
+;; by the calling ange-ftp-ftp-name on the current directory. In this case the
+;; next-error command will also ange-ftp the files over. This is achieved
+;; automatically because the compilation-parse-errors function uses
+;; default-directory to build it's file names. If however the file visited was
+;; loaded locally, remote-compile prompts for a host and user and assumes the
+;; files mounted locally (otherwise, how was the visited file loaded).
+
+;; See the user defined variables section for more info.
+
+;; I was contemplating redefining "compile" to "remote-compile" automatically
+;; if the file visited was ange-ftp'ed but decided against it for now. If you
+;; feel this is a good idea, let me know and I'll consider it again.
+
+;; Installation:
+
+;; To use rcompile, you also need to give yourself permission to connect to
+;; the remote host. You do this by putting lines like:
+
+;; monopoly alon
+;; vme33
+;;
+;; in a file named .rhosts in the home directory (of the remote machine).
+;; Be careful what you put in this file. A line like:
+;;
+;; +
+;;
+;; Will allow anyone access to your account without a password. I suggest you
+;; read the rhosts(5) manual page before you edit this file (if you are not
+;; familiar with it already)
\f
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Reposition-window makes an entire function definition or comment visible,
-;;; or, if it is already visible, places it at the top of the window;
-;;; additional invocations toggle the visibility of comments preceding the
-;;; code. For the gory details, see the documentation for reposition-window;
-;;; rather than reading that, you may just want to play with it.
-
-;;; This tries pretty hard to do the recentering correctly; the precise
-;;; action depends on what the buffer looks like. If you find a situation
-;;; where it doesn't behave well, let me know. This function is modeled
-;;; after one of the same name in ZMACS, but the code is all-new and the
-;;; behavior in some situations differs.
+;; Reposition-window makes an entire function definition or comment visible,
+;; or, if it is already visible, places it at the top of the window;
+;; additional invocations toggle the visibility of comments preceding the
+;; code. For the gory details, see the documentation for reposition-window;
+;; rather than reading that, you may just want to play with it.
+
+;; This tries pretty hard to do the recentering correctly; the precise
+;; action depends on what the buffer looks like. If you find a situation
+;; where it doesn't behave well, let me know. This function is modeled
+;; after one of the same name in ZMACS, but the code is all-new and the
+;; behavior in some situations differs.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; rlogin.el --- remote login interface
+;; Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
+
;; Author: Noah Friedman
;; Maintainer: Noah Friedman <friedman@prep.ai.mit.edu>
;; Keywords: unix, comm
-;; Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
-;;
-;; This program is free software; you can redistribute it and/or modify
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to: The Free Software Foundation,
-;; Inc.; 675 Massachusetts Avenue.; Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
-;; $Id: rlogin.el,v 1.29 1995/06/08 13:03:15 roland Exp friedman $
+;; $Id: rlogin.el,v 1.30 1995/10/27 22:34:50 friedman Exp erik $
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Maintainer: friedman@prep.ai.mit.edu
;; Keywords: minibuffer, window, frame, display
;; Status: Known to work in FSF GNU Emacs 19.26 and later.
-;; $Id: rsz-mini.el,v 1.9 1995/08/03 17:38:07 rms Exp kwzh $
+;; $Id: rsz-mini.el,v 1.10 1996/01/09 23:21:29 kwzh Exp erik $
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; s-region.el --- set region using shift key.
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: Morten Welinder (terra@diku.dk)
;; Keywords: terminals
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Commentary:
;; Automatically save place in files, so that visiting them later
;; (even during a different Emacs session) automatically moves point
;; Thanks to Stefan Schoef, who sent a patch with the
;; `save-place-version-control' stuff in it.
+;;; Code:
+
;; this is what I was using during testing:
;; (define-key ctl-x-map "p" 'toggle-save-place)
;;; scroll-bar.el --- window system-independent scroll bar support.
-;;; Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: hardware
-;;; This file is part of GNU Emacs.
+;; This file is part of GNU Emacs.
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
-;;; Code:
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; Window-system-independent bindings of mouse clicks on the scroll bar.
;; Presently emulates the scroll-bar behavior of xterm.
+
;;; Code:
(require 'mouse)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This Lisp code is run in Emacs when it is to operate as
-;;; a server for other processes.
+;; This Lisp code is run in Emacs when it is to operate as
+;; a server for other processes.
-;;; Load this library and do M-x server-edit to enable Emacs as a server.
-;;; Emacs runs the program ../arch-lib/emacsserver as a subprocess
-;;; for communication with clients. If there are no client buffers to edit,
-;;; server-edit acts like (switch-to-buffer (other-buffer))
+;; Load this library and do M-x server-edit to enable Emacs as a server.
+;; Emacs runs the program ../arch-lib/emacsserver as a subprocess
+;; for communication with clients. If there are no client buffers to edit,
+;; server-edit acts like (switch-to-buffer (other-buffer))
-;;; When some other program runs "the editor" to edit a file,
-;;; "the editor" can be the Emacs client program ../lib-src/emacsclient.
-;;; This program transmits the file names to Emacs through
-;;; the server subprocess, and Emacs visits them and lets you edit them.
+;; When some other program runs "the editor" to edit a file,
+;; "the editor" can be the Emacs client program ../lib-src/emacsclient.
+;; This program transmits the file names to Emacs through
+;; the server subprocess, and Emacs visits them and lets you edit them.
-;;; Note that any number of clients may dispatch files to emacs to be edited.
+;; Note that any number of clients may dispatch files to emacs to be edited.
-;;; When you finish editing a Server buffer, again call server-edit
-;;; to mark that buffer as done for the client and switch to the next
-;;; Server buffer. When all the buffers for a client have been edited
-;;; and exited with server-edit, the client "editor" will return
-;;; to the program that invoked it.
+;; When you finish editing a Server buffer, again call server-edit
+;; to mark that buffer as done for the client and switch to the next
+;; Server buffer. When all the buffers for a client have been edited
+;; and exited with server-edit, the client "editor" will return
+;; to the program that invoked it.
-;;; Your editing commands and Emacs's display output go to and from
-;;; the terminal in the usual way. Thus, server operation is possible
-;;; only when Emacs can talk to the terminal at the time you invoke
-;;; the client. This is possible in four cases:
+;; Your editing commands and Emacs's display output go to and from
+;; the terminal in the usual way. Thus, server operation is possible
+;; only when Emacs can talk to the terminal at the time you invoke
+;; the client. This is possible in four cases:
-;;; 1. On a window system, where Emacs runs in one window and the
-;;; program that wants to use "the editor" runs in another.
+;; 1. On a window system, where Emacs runs in one window and the
+;; program that wants to use "the editor" runs in another.
-;;; 2. On a multi-terminal system, where Emacs runs on one terminal and the
-;;; program that wants to use "the editor" runs on another.
+;; 2. On a multi-terminal system, where Emacs runs on one terminal and the
+;; program that wants to use "the editor" runs on another.
-;;; 3. When the program that wants to use "the editor" is running
-;;; as a subprocess of Emacs.
+;; 3. When the program that wants to use "the editor" is running
+;; as a subprocess of Emacs.
-;;; 4. On a system with job control, when Emacs is suspended, the program
-;;; that wants to use "the editor" will stop and display
-;;; "Waiting for Emacs...". It can then be suspended, and Emacs can be
-;;; brought into the foreground for editing. When done editing, Emacs is
-;;; suspended again, and the client program is brought into the foreground.
+;; 4. On a system with job control, when Emacs is suspended, the program
+;; that wants to use "the editor" will stop and display
+;; "Waiting for Emacs...". It can then be suspended, and Emacs can be
+;; brought into the foreground for editing. When done editing, Emacs is
+;; suspended again, and the client program is brought into the foreground.
-;;; The buffer local variable "server-buffer-clients" lists
-;;; the clients who are waiting for this buffer to be edited.
-;;; The global variable "server-clients" lists all the waiting clients,
-;;; and which files are yet to be edited for each.
+;; The buffer local variable "server-buffer-clients" lists
+;; the clients who are waiting for this buffer to be edited.
+;; The global variable "server-clients" lists all the waiting clients,
+;; and which files are yet to be edited for each.
;;; Code:
\f
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
-;;; LCD Archive Entry:
-;;; shadowfile|Boris Goldowsky|boris@gnu.ai.mit.edu|
-;;; Helps you keep identical copies of files in multiple places.|
-;;; $Date: 1995/10/30 17:22:28 $ |$Revision: 1.5 $|~/misc/shadowfile.el.Z|
-
-;;; Commentary:
-;;;
-;;; This package helps you to keep identical copies of files in more than one
-;;; place - possibly on different machines. When you save a file, it checks
-;;; whether it is on the list of files with "shadows", and if so, it tries to
-;;; copy it when you exit emacs (or use the shadow-copy-files command).
-
-;;; Installation & Use:
-;;;
-;;; Put (require 'shadowfile) in your .emacs; add clusters (if necessary)
-;;; and file groups with shadow-define-cluster, shadow-define-literal-group,
-;;; and shadow-define-regexp-group (see the documentation for these functions
-;;; for information on how and when to use them). After doing this once,
-;;; everything should be automatic.
-;;; The lists of clusters and shadows are saved in a file called
-;;; .shadows, so that they can be remembered from one emacs session to
-;;; another, even (as much as possible) if the emacs session terminates
-;;; abnormally. The files needing to be copied are stored in .shadow_todo; if
-;;; a file cannot be copied for any reason, it will stay on the list to be
-;;; tried again next time. The .shadows file should itself have shadows on
-;;; all your accounts so that the information in it is consistent everywhere,
-;;; but .shadow_todo is local information and should have no shadows.
-;;; If you do not want to copy a particular file, you can answer "no"
-;;; and be asked again next time you hit C-x 4 s or exit emacs. If you do not
-;;; want to be asked again, use shadow-cancel, and you will not be asked until
-;;; you change the file and save it again. If you do not want to shadow
-;;; that file ever again, you can edit it out of the .shadows buffer.
-;;; Anytime you edit the .shadows buffer, you must type M-x shadow-read-files
-;;; to load in the new information, or your changes will be overwritten!
-
-;;; Bugs & Warnings:
-;;;
-;;; - It is bad to have two emacses both running shadowfile at the same
-;;; time. It tries to detect this condition, but is not always successful.
-;;;
-;;; - You have to be careful not to edit a file in two locations
-;;; before shadowfile has had a chance to copy it; otherwise
-;;; "updating shadows" will overwrite one of the changed versions.
-;;;
-;;; - It ought to check modification times of both files to make sure
-;;; it is doing the right thing. This will have to wait until
-;;; file-newer-than-file-p works between machines.
-;;;
-;;; - It will not make directories for you, it just fails to copy files
-;;; that belong in non-existent directories.
-;;;
-;;; Please report any bugs to me (boris@gnu.ai.mit.edu). Also let me know
-;;; if you have suggestions or would like to be informed of updates.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;; LCD Archive Entry:
+;; shadowfile|Boris Goldowsky|boris@gnu.ai.mit.edu|
+;; Helps you keep identical copies of files in multiple places.|
+;; $Date: 1995/10/30 17:23:17 $ |$Revision: 1.6 $|~/misc/shadowfile.el.Z|
+
+;; Commentary:
+
+;; This package helps you to keep identical copies of files in more than one
+;; place - possibly on different machines. When you save a file, it checks
+;; whether it is on the list of files with "shadows", and if so, it tries to
+;; copy it when you exit emacs (or use the shadow-copy-files command).
+
+;; Installation & Use:
+
+;; Put (require 'shadowfile) in your .emacs; add clusters (if necessary)
+;; and file groups with shadow-define-cluster,
+;; shadow-define-literal-group, and shadow-define-regexp-group (see the
+;; documentation for these functions for information on how and when to
+;; use them). After doing this once, everything should be automatic.
+
+;; The lists of clusters and shadows are saved in a file called .shadows,
+;; so that they can be remembered from one emacs session to another, even
+;; (as much as possible) if the emacs session terminates abnormally. The
+;; files needing to be copied are stored in .shadow_todo; if a file cannot
+;; be copied for any reason, it will stay on the list to be tried again
+;; next time. The .shadows file should itself have shadows on all your
+;; accounts so that the information in it is consistent everywhere, but
+;; .shadow_todo is local information and should have no shadows.
+
+;; If you do not want to copy a particular file, you can answer "no" and
+;; be asked again next time you hit C-x 4 s or exit emacs. If you do not
+;; want to be asked again, use shadow-cancel, and you will not be asked
+;; until you change the file and save it again. If you do not want to
+;; shadow that file ever again, you can edit it out of the .shadows
+;; buffer. Anytime you edit the .shadows buffer, you must type M-x
+;; shadow-read-files to load in the new information, or your changes will
+;; be overwritten!
+
+;; Bugs & Warnings:
+;;
+;; - It is bad to have two emacses both running shadowfile at the same
+;; time. It tries to detect this condition, but is not always successful.
+;;
+;; - You have to be careful not to edit a file in two locations
+;; before shadowfile has had a chance to copy it; otherwise
+;; "updating shadows" will overwrite one of the changed versions.
+;;
+;; - It ought to check modification times of both files to make sure
+;; it is doing the right thing. This will have to wait until
+;; file-newer-than-file-p works between machines.
+;;
+;; - It will not make directories for you, it just fails to copy files
+;; that belong in non-existent directories.
+;;
+;; Please report any bugs to me (boris@gnu.ai.mit.edu). Also let me know
+;; if you have suggestions or would like to be informed of updates.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Please send me bug reports, bug fixes, and extensions, so that I can
-;;; merge them into the master source.
-;;; - Olin Shivers (shivers@cs.cmu.edu)
-;;; - Simon Marshall (simon@gnu.ai.mit.edu)
+;; Please send me bug reports, bug fixes, and extensions, so that I can
+;; merge them into the master source.
+;; - Olin Shivers (shivers@cs.cmu.edu)
+;; - Simon Marshall (simon@gnu.ai.mit.edu)
-;;; This file defines a a shell-in-a-buffer package (shell mode) built
-;;; on top of comint mode. This is actually cmushell with things
-;;; renamed to replace its counterpart in Emacs 18. cmushell is more
-;;; featureful, robust, and uniform than the Emacs 18 version.
+;; This file defines a a shell-in-a-buffer package (shell mode) built
+;; on top of comint mode. This is actually cmushell with things
+;; renamed to replace its counterpart in Emacs 18. cmushell is more
+;; featureful, robust, and uniform than the Emacs 18 version.
-;;; Since this mode is built on top of the general command-interpreter-in-
-;;; a-buffer mode (comint mode), it shares a common base functionality,
-;;; and a common set of bindings, with all modes derived from comint mode.
-;;; This makes these modes easier to use.
+;; Since this mode is built on top of the general command-interpreter-in-
+;; a-buffer mode (comint mode), it shares a common base functionality,
+;; and a common set of bindings, with all modes derived from comint mode.
+;; This makes these modes easier to use.
-;;; For documentation on the functionality provided by comint mode, and
-;;; the hooks available for customising it, see the file comint.el.
-;;; For further information on shell mode, see the comments below.
+;; For documentation on the functionality provided by comint mode, and
+;; the hooks available for customising it, see the file comint.el.
+;; For further information on shell mode, see the comments below.
-;;; Needs fixin:
-;;; When sending text from a source file to a subprocess, the process-mark can
-;;; move off the window, so you can lose sight of the process interactions.
-;;; Maybe I should ensure the process mark is in the window when I send
-;;; text to the process? Switch selectable?
+;; Needs fixin:
+;; When sending text from a source file to a subprocess, the process-mark can
+;; move off the window, so you can lose sight of the process interactions.
+;; Maybe I should ensure the process mark is in the window when I send
+;; text to the process? Switch selectable?
;; YOUR .EMACS FILE
;;=============================================================================
;; (eval-after-load "shell"
;; '(define-key shell-mode-map "\M-#" 'shells-dynamic-spell))
\f
-;;; Brief Command Documentation:
-;;;============================================================================
-;;; Comint Mode Commands: (common to shell and all comint-derived modes)
-;;;
-;;; m-p comint-previous-input Cycle backwards in input history
-;;; m-n comint-next-input Cycle forwards
-;;; m-r comint-previous-matching-input Previous input matching a regexp
-;;; m-s comint-next-matching-input Next input that matches
-;;; m-c-l comint-show-output Show last batch of process output
-;;; return comint-send-input
-;;; c-d comint-delchar-or-maybe-eof Delete char unless at end of buff.
-;;; c-c c-a comint-bol Beginning of line; skip prompt
-;;; c-c c-u comint-kill-input ^u
-;;; c-c c-w backward-kill-word ^w
-;;; c-c c-c comint-interrupt-subjob ^c
-;;; c-c c-z comint-stop-subjob ^z
-;;; c-c c-\ comint-quit-subjob ^\
-;;; c-c c-o comint-kill-output Delete last batch of process output
-;;; c-c c-r comint-show-output Show last batch of process output
-;;; c-c c-h comint-dynamic-list-input-ring List input history
-;;; send-invisible Read line w/o echo & send to proc
-;;; comint-continue-subjob Useful if you accidentally suspend
-;;; top-level job
-;;; comint-mode-hook is the comint mode hook.
-
-;;; Shell Mode Commands:
-;;; shell Fires up the shell process
-;;; tab comint-dynamic-complete Complete filename/command/history
-;;; m-? comint-dynamic-list-filename-completions
-;;; List completions in help buffer
-;;; m-c-f shell-forward-command Forward a shell command
-;;; m-c-b shell-backward-command Backward a shell command
-;;; dirs Resync the buffer's dir stack
-;;; dirtrack-toggle Turn dir tracking on/off
-;;; comint-strip-ctrl-m Remove trailing ^Ms from output
-;;;
-;;; The shell mode hook is shell-mode-hook
-;;; comint-prompt-regexp is initialised to shell-prompt-pattern, for backwards
-;;; compatibility.
+;; Brief Command Documentation:
+;;============================================================================
+;; Comint Mode Commands: (common to shell and all comint-derived modes)
+;;
+;; m-p comint-previous-input Cycle backwards in input history
+;; m-n comint-next-input Cycle forwards
+;; m-r comint-previous-matching-input Previous input matching a regexp
+;; m-s comint-next-matching-input Next input that matches
+;; m-c-l comint-show-output Show last batch of process output
+;; return comint-send-input
+;; c-d comint-delchar-or-maybe-eof Delete char unless at end of buff.
+;; c-c c-a comint-bol Beginning of line; skip prompt
+;; c-c c-u comint-kill-input ^u
+;; c-c c-w backward-kill-word ^w
+;; c-c c-c comint-interrupt-subjob ^c
+;; c-c c-z comint-stop-subjob ^z
+;; c-c c-\ comint-quit-subjob ^\
+;; c-c c-o comint-kill-output Delete last batch of process output
+;; c-c c-r comint-show-output Show last batch of process output
+;; c-c c-h comint-dynamic-list-input-ring List input history
+;; send-invisible Read line w/o echo & send to proc
+;; comint-continue-subjob Useful if you accidentally suspend
+;; top-level job
+;; comint-mode-hook is the comint mode hook.
+
+;; Shell Mode Commands:
+;; shell Fires up the shell process
+;; tab comint-dynamic-complete Complete filename/command/history
+;; m-? comint-dynamic-list-filename-completions
+;; List completions in help buffer
+;; m-c-f shell-forward-command Forward a shell command
+;; m-c-b shell-backward-command Backward a shell command
+;; dirs Resync the buffer's dir stack
+;; dirtrack-toggle Turn dir tracking on/off
+;; comint-strip-ctrl-m Remove trailing ^Ms from output
+;;
+;; The shell mode hook is shell-mode-hook
+;; comint-prompt-regexp is initialised to shell-prompt-pattern, for backwards
+;; compatibility.
-;;; Read the rest of this file for more information.
+;; Read the rest of this file for more information.
\f
-;;; Customization and Buffer Variables
-;;; ===========================================================================
-;;;
-
;;; Code:
(require 'comint)
+;;; Customization and Buffer Variables
+
;;;###autoload
(defvar shell-prompt-pattern "^[^#$%>\n]*[#$%>] *"
"Regexp to match prompts in the inferior shell.
"Additional expressions to highlight in Shell mode.")
\f
;;; Basic Procedures
-;;; ===========================================================================
-;;;
(defun shell-mode ()
"Major mode for interacting with an inferior shell.
;;;###autoload (add-hook 'same-window-buffer-names "*shell*")
\f
;;; Directory tracking
-;;; ===========================================================================
+;;;
;;; This code provides the shell mode input sentinel
;;; SHELL-DIRECTORY-TRACKER
;;; that tracks cd, pushd, and popd commands issued to the shell, and
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; skeleton.el --- Lisp language extension for writing statement skeletons
+
;; Copyright (C) 1993, 1994, 1995 by Free Software Foundation, Inc.
;; Author: Daniel.Pfeiffer@Informatik.START.dbp.de, fax (+49 69) 7588-2389
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This package provides the sorting facilities documented in the Emacs
-;;; user's manual.
+;; This package provides the sorting facilities documented in the Emacs
+;; user's manual.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; subr.el --- basic lisp subroutines for Emacs
-;;; Copyright (C) 1985, 1986, 1992, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1986, 1992, 1994, 1995 Free Software Foundation, Inc.
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Submitted Mar. 1987, Jeff Peck
-;;; Sun Microsystems Inc. <peck@sun.com>
-;;; Conceived Nov. 1986, Stan Jefferson,
-;;; Computer Science Lab, SRI International.
-;;; GoodIdeas Feb. 1987, Steve Greenbaum
-;;; & UpClicks Reasoning Systems, Inc.
-;;;
-;;;
-;;; Functions for manipulating via the mouse and mouse-map definitions
-;;; for accessing them. Also definitions of mouse menus.
-;;; This file you should freely modify to reflect you personal tastes.
-;;;
-;;; First half of file defines functions to implement mouse commands,
-;;; Don't delete any of those, just add what ever else you need.
-;;; Second half of file defines mouse bindings, do whatever you want there.
-
-;;;
-;;; Mouse Functions.
-;;;
-;;; These functions follow the sun-mouse-handler convention of being called
-;;; with three arguments: (window x-pos y-pos)
-;;; This makes it easy for a mouse executed command to know where the mouse is.
-;;; Use the macro "eval-in-window" to execute a function
-;;; in a temporarily selected window.
-;;;
-;;; If you have a function that must be called with other arguments
-;;; bind the mouse button to an s-exp that contains the necessary parameters.
-;;; See "minibuffer" bindings for examples.
-;;;
+;; Submitted Mar. 1987, Jeff Peck
+;; Sun Microsystems Inc. <peck@sun.com>
+;; Conceived Nov. 1986, Stan Jefferson,
+;; Computer Science Lab, SRI International.
+;; GoodIdeas Feb. 1987, Steve Greenbaum
+;; & UpClicks Reasoning Systems, Inc.
+;;
+;;
+;; Functions for manipulating via the mouse and mouse-map definitions
+;; for accessing them. Also definitions of mouse menus.
+;; This file you should freely modify to reflect you personal tastes.
+;;
+;; First half of file defines functions to implement mouse commands,
+;; Don't delete any of those, just add what ever else you need.
+;; Second half of file defines mouse bindings, do whatever you want there.
+
+;;
+;; Mouse Functions.
+;;
+;; These functions follow the sun-mouse-handler convention of being called
+;; with three arguments: (window x-pos y-pos)
+;; This makes it easy for a mouse executed command to know where the mouse is.
+;; Use the macro "eval-in-window" to execute a function
+;; in a temporarily selected window.
+;;
+;; If you have a function that must be called with other arguments
+;; bind the mouse button to an s-exp that contains the necessary parameters.
+;; See "minibuffer" bindings for examples.
+;;
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; talk.el --- Allow several users to talk to each other through Emacs.
;; Copyright (C) 1995 Free Software Foundation, Inc.
+
;; Keywords: comm, frames
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This is a multi-user talk package that runs in Emacs.
-;;; Use talk-connect to bring a new person into the conversation.
+;; This is a multi-user talk package that runs in Emacs.
+;; Use talk-connect to bring a new person into the conversation.
;;; Code:
;;; tar-mode.el --- simple editing of tar files from GNU emacs
-;;; Copyright (C) 1990, 1991, 1993, 1994, 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1990, 1991, 1993, 1994, 1995 Free Software Foundation, Inc.
;; Author: Jamie Zawinski <jwz@lucid.com>
;; Created: 04 Apr 1990
;; Keywords: unix
-;;; This file is part of GNU Emacs.
-;;;
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; This package attempts to make dealing with Unix 'tar' archives easier.
-;;; When this code is loaded, visiting a file whose name ends in '.tar' will
-;;; cause the contents of that archive file to be displayed in a Dired-like
-;;; listing. It is then possible to use the customary Dired keybindings to
-;;; extract sub-files from that archive, either by reading them into their own
-;;; editor buffers, or by copying them directly to arbitrary files on disk.
-;;; It is also possible to delete sub-files from within the tar file and write
-;;; the modified archive back to disk, or to edit sub-files within the archive
-;;; and re-insert the modified files into the archive. See the documentation
-;;; string of tar-mode for more info.
-
-;;; This code now understands the extra fields that GNU tar adds to tar files.
-
-;;; This interacts correctly with "uncompress.el" in the Emacs library,
-;;; which you get with
-;;;
-;;; (autoload 'uncompress-while-visiting "uncompress")
-;;; (setq auto-mode-alist (cons '("\\.Z$" . uncompress-while-visiting)
-;;; auto-mode-alist))
-;;;
-;;; Do not attempt to use tar-mode.el with crypt.el, you will lose.
-
-;;; *************** TO DO ***************
-;;;
-;;; o chmod should understand "a+x,og-w".
-;;;
-;;; o It's not possible to add a NEW file to a tar archive; not that
-;;; important, but still...
-;;;
-;;; o The code is less efficient that it could be - in a lot of places, I
-;;; pull a 512-character string out of the buffer and parse it, when I could
-;;; be parsing it in place, not garbaging a string. Should redo that.
-;;;
-;;; o I'd like a command that searches for a string/regexp in every subfile
-;;; of an archive, where <esc> would leave you in a subfile-edit buffer.
-;;; (Like the Meta-R command of the Zmacs mail reader.)
-;;;
-;;; o Sometimes (but not always) reverting the tar-file buffer does not
-;;; re-grind the listing, and you are staring at the binary tar data.
-;;; Typing 'g' again immediately after that will always revert and re-grind
-;;; it, though. I have no idea why this happens.
-;;;
-;;; o Tar-mode interacts poorly with crypt.el and zcat.el because the tar
-;;; write-file-hook actually writes the file. Instead it should remove the
-;;; header (and conspire to put it back afterwards) so that other write-file
-;;; hooks which frob the buffer have a chance to do their dirty work. There
-;;; might be a problem if the tar write-file-hook does not come *first* on
-;;; the list.
-;;;
-;;; o Block files, sparse files, continuation files, and the various header
-;;; types aren't editable. Actually I don't know that they work at all.
-
-;;; Rationale:
-
-;;; Why does tar-mode edit the file itself instead of using tar?
-
-;;; That means that you can edit tar files which you don't have room for
-;;; on your local disk.
-
-;;; I don't know about recent features in gnu tar, but old versions of tar
-;;; can't replace a file in the middle of a tar file with a new version.
-;;; Tar-mode can. I don't think tar can do things like chmod the subfiles.
-;;; An implementation which involved unpacking and repacking the file into
-;;; some scratch directory would be very wasteful, and wouldn't be able to
-;;; preserve the file owners.
+;; This package attempts to make dealing with Unix 'tar' archives easier.
+;; When this code is loaded, visiting a file whose name ends in '.tar' will
+;; cause the contents of that archive file to be displayed in a Dired-like
+;; listing. It is then possible to use the customary Dired keybindings to
+;; extract sub-files from that archive, either by reading them into their own
+;; editor buffers, or by copying them directly to arbitrary files on disk.
+;; It is also possible to delete sub-files from within the tar file and write
+;; the modified archive back to disk, or to edit sub-files within the archive
+;; and re-insert the modified files into the archive. See the documentation
+;; string of tar-mode for more info.
+
+;; This code now understands the extra fields that GNU tar adds to tar files.
+
+;; This interacts correctly with "uncompress.el" in the Emacs library,
+;; which you get with
+;;
+;; (autoload 'uncompress-while-visiting "uncompress")
+;; (setq auto-mode-alist (cons '("\\.Z$" . uncompress-while-visiting)
+;; auto-mode-alist))
+;;
+;; Do not attempt to use tar-mode.el with crypt.el, you will lose.
+
+;; *************** TO DO ***************
+;;
+;; o chmod should understand "a+x,og-w".
+;;
+;; o It's not possible to add a NEW file to a tar archive; not that
+;; important, but still...
+;;
+;; o The code is less efficient that it could be - in a lot of places, I
+;; pull a 512-character string out of the buffer and parse it, when I could
+;; be parsing it in place, not garbaging a string. Should redo that.
+;;
+;; o I'd like a command that searches for a string/regexp in every subfile
+;; of an archive, where <esc> would leave you in a subfile-edit buffer.
+;; (Like the Meta-R command of the Zmacs mail reader.)
+;;
+;; o Sometimes (but not always) reverting the tar-file buffer does not
+;; re-grind the listing, and you are staring at the binary tar data.
+;; Typing 'g' again immediately after that will always revert and re-grind
+;; it, though. I have no idea why this happens.
+;;
+;; o Tar-mode interacts poorly with crypt.el and zcat.el because the tar
+;; write-file-hook actually writes the file. Instead it should remove the
+;; header (and conspire to put it back afterwards) so that other write-file
+;; hooks which frob the buffer have a chance to do their dirty work. There
+;; might be a problem if the tar write-file-hook does not come *first* on
+;; the list.
+;;
+;; o Block files, sparse files, continuation files, and the various header
+;; types aren't editable. Actually I don't know that they work at all.
+
+;; Rationale:
+
+;; Why does tar-mode edit the file itself instead of using tar?
+
+;; That means that you can edit tar files which you don't have room for
+;; on your local disk.
+
+;; I don't know about recent features in gnu tar, but old versions of tar
+;; can't replace a file in the middle of a tar file with a new version.
+;; Tar-mode can. I don't think tar can do things like chmod the subfiles.
+;; An implementation which involved unpacking and repacking the file into
+;; some scratch directory would be very wasteful, and wouldn't be able to
+;; preserve the file owners.
;;; Code:
;;; TCP/IP stream emulation for GNU Emacs
+
;; Copyright (C) 1988, 1989, 1993 Free Software Foundation, Inc.
-;;; Author: Masanobu Umeda
-;;; Maintainer: umerin@mse.kyutech.ac.jp
+;; Author: Masanobu Umeda
+;; Maintainer: umerin@mse.kyutech.ac.jp
;; This file is part of GNU Emacs.
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; telnet.el --- run a telnet session from within an Emacs buffer
-;;; Copyright (C) 1985, 1988, 1992, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1988, 1992, 1994 Free Software Foundation, Inc.
;; Author: William F. Schelter
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; tempo.el --- Flexible template insertion
+
;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Author: David K}gedal <davidk@lysator.liu.se >
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; The changelog is at the end of this file.
+;; The changelog is at the end of this file.
-;;; Please send me bug reports, bug fixes, and extensions, so that I can
-;;; merge them into the master source.
-;;; - Per Bothner (bothner@cygnus.com)
+;; Please send me bug reports, bug fixes, and extensions, so that I can
+;; merge them into the master source.
+;; - Per Bothner (bothner@cygnus.com)
-;;; This file defines a general command-interpreter-in-a-buffer package
-;;; (term mode). The idea is that you can build specific process-in-a-buffer
-;;; modes on top of term mode -- e.g., lisp, shell, scheme, T, soar, ....
-;;; This way, all these specific packages share a common base functionality,
-;;; and a common set of bindings, which makes them easier to use (and
-;;; saves code, implementation time, etc., etc.).
+;; This file defines a general command-interpreter-in-a-buffer package
+;; (term mode). The idea is that you can build specific process-in-a-buffer
+;; modes on top of term mode -- e.g., lisp, shell, scheme, T, soar, ....
+;; This way, all these specific packages share a common base functionality,
+;; and a common set of bindings, which makes them easier to use (and
+;; saves code, implementation time, etc., etc.).
-;;; For hints on converting existing process modes (e.g., tex-mode,
-;;; background, dbx, gdb, kermit, prolog, telnet) to use term-mode
-;;; instead of shell-mode, see the notes at the end of this file.
+;; For hints on converting existing process modes (e.g., tex-mode,
+;; background, dbx, gdb, kermit, prolog, telnet) to use term-mode
+;; instead of shell-mode, see the notes at the end of this file.
\f
-;;; Brief Command Documentation:
-;;;============================================================================
-;;; Term Mode Commands: (common to all derived modes, like cmushell & cmulisp
-;;; mode)
-;;;
-;;; m-p term-previous-input Cycle backwards in input history
-;;; m-n term-next-input Cycle forwards
-;;; m-r term-previous-matching-input Previous input matching a regexp
-;;; m-s comint-next-matching-input Next input that matches
-;;; return term-send-input
-;;; c-c c-a term-bol Beginning of line; skip prompt.
-;;; c-d term-delchar-or-maybe-eof Delete char unless at end of buff.
-;;; c-c c-u term-kill-input ^u
-;;; c-c c-w backward-kill-word ^w
-;;; c-c c-c term-interrupt-subjob ^c
-;;; c-c c-z term-stop-subjob ^z
-;;; c-c c-\ term-quit-subjob ^\
-;;; c-c c-o term-kill-output Delete last batch of process output
-;;; c-c c-r term-show-output Show last batch of process output
-;;; c-c c-h term-dynamic-list-input-ring List input history
-;;;
-;;; Not bound by default in term-mode
-;;; term-send-invisible Read a line w/o echo, and send to proc
-;;; (These are bound in shell-mode)
-;;; term-dynamic-complete Complete filename at point.
-;;; term-dynamic-list-completions List completions in help buffer.
-;;; term-replace-by-expanded-filename Expand and complete filename at point;
-;;; replace with expanded/completed name.
-;;; term-kill-subjob No mercy.
-;;; term-show-maximum-output Show as much output as possible.
-;;; term-continue-subjob Send CONT signal to buffer's process
-;;; group. Useful if you accidentally
-;;; suspend your process (with C-c C-z).
-
-;;; term-mode-hook is the term mode hook. Basically for your keybindings.
-;;; term-load-hook is run after loading in this package.
-
-;;; Code:
-
-;;; This is passed to the inferior in the EMACS environment variable,
-;;; so it is important to increase it if there are protocol-relevant changes.
+;; Brief Command Documentation:
+;;============================================================================
+;; Term Mode Commands: (common to all derived modes, like cmushell & cmulisp
+;; mode)
+;;
+;; m-p term-previous-input Cycle backwards in input history
+;; m-n term-next-input Cycle forwards
+;; m-r term-previous-matching-input Previous input matching a regexp
+;; m-s comint-next-matching-input Next input that matches
+;; return term-send-input
+;; c-c c-a term-bol Beginning of line; skip prompt.
+;; c-d term-delchar-or-maybe-eof Delete char unless at end of buff.
+;; c-c c-u term-kill-input ^u
+;; c-c c-w backward-kill-word ^w
+;; c-c c-c term-interrupt-subjob ^c
+;; c-c c-z term-stop-subjob ^z
+;; c-c c-\ term-quit-subjob ^\
+;; c-c c-o term-kill-output Delete last batch of process output
+;; c-c c-r term-show-output Show last batch of process output
+;; c-c c-h term-dynamic-list-input-ring List input history
+;;
+;; Not bound by default in term-mode
+;; term-send-invisible Read a line w/o echo, and send to proc
+;; (These are bound in shell-mode)
+;; term-dynamic-complete Complete filename at point.
+;; term-dynamic-list-completions List completions in help buffer.
+;; term-replace-by-expanded-filename Expand and complete filename at point;
+;; replace with expanded/completed name.
+;; term-kill-subjob No mercy.
+;; term-show-maximum-output Show as much output as possible.
+;; term-continue-subjob Send CONT signal to buffer's process
+;; group. Useful if you accidentally
+;; suspend your process (with C-c C-z).
+
+;; term-mode-hook is the term mode hook. Basically for your keybindings.
+;; term-load-hook is run after loading in this package.
+
+;; Code:
+
+;; This is passed to the inferior in the EMACS environment variable,
+;; so it is important to increase it if there are protocol-relevant changes.
(defconst term-protocol-version "0.95")
(require 'ring)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
+
;; Major mode for editing and validating BibTeX files.
;; Usage:
;; previous: alarson@src.honeywell.com)
;;; Code:
+
;; User Options:
(defvar bibtex-field-left-delimiter "{"
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; ispell.el --- spell checking using Ispell
-;;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
-
-;;; Authors : Ken Stevens <k.stevens@ieee.org>
-;;; Note: version numbers and time stamp are not updated
-;;; when this file is edited for release with GNU Emacs.
-;;; Last Modified On: Tue Jun 13 12:05:28 EDT 1995
-;;; Update Revision : 2.37
-;;; Syntax : emacs-lisp
-;;; Status : Release with 3.1.12+ ispell.
-;;; Version : International Ispell Version 3.1 by Geoff Kuenning.
-;;; Bug Reports : ispell-el-bugs@itcorp.com
-
-;;; Note: version numbers and time stamp are not updated
-;;; when this file is edited for release with GNU Emacs.
-
-;;; This file is part of GNU Emacs.
-;;;
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-;;;
-;;; Commentary:
-;;;
-;;; INSTRUCTIONS
-;;;
-;;; This code contains a section of user-settable variables that you should
-;;; inspect prior to installation. Look past the end of the history list.
-;;; Set them up for your locale and the preferences of the majority of the
-;;; users. Otherwise the users may need to set a number of variables
-;;; themselves.
-;;; You particularly may want to change the default dictionary for your
-;;; country and language.
-;;;
-;;;
-;;; To fully install this, add this file to your Emacs Lisp directory and
-;;; compile it with M-X byte-compile-file. Then add the following to the
-;;; appropriate init file:
-;;;
-;;; (autoload 'ispell-word "ispell"
-;;; "Check the spelling of word in buffer." t)
-;;; (global-set-key "\e$" 'ispell-word)
-;;; (autoload 'ispell-region "ispell"
-;;; "Check the spelling of region." t)
-;;; (autoload 'ispell-buffer "ispell"
-;;; "Check the spelling of buffer." t)
-;;; (autoload 'ispell-complete-word "ispell"
-;;; "Look up current word in dictionary and try to complete it." t)
-;;; (autoload 'ispell-change-dictionary "ispell"
-;;; "Change ispell dictionary." t)
-;;; (autoload 'ispell-message "ispell"
-;;; "Check spelling of mail message or news post.")
-;;;
-;;; Depending on the mail system you use, you may want to include these:
-;;;
-;;; (add-hook 'news-inews-hook 'ispell-message)
-;;; (add-hook 'mail-send-hook 'ispell-message)
-;;; (add-hook 'mh-before-send-letter-hook 'ispell-message)
-;;;
-;;;
-;;; Ispell has a TeX parser and a nroff parser (the default).
-;;; The parsing is controlled by the variable ispell-parser. Currently
-;;; it is just a "toggle" between TeX and nroff, but if more parsers are
-;;; added it will be updated. See the variable description for more info.
-;;;
-;;;
-;;; TABLE OF CONTENTS
-;;;
-;;; ispell-word
-;;; ispell-region
-;;; ispell-buffer
-;;; ispell-message
-;;; ispell-continue
-;;; ispell-complete-word
-;;; ispell-complete-word-interior-frag
-;;; ispell-change-dictionary
-;;; ispell-kill-ispell
-;;; ispell-pdict-save
-;;;
-;;;
-;;; Commands in ispell-region:
-;;; Character replacement: Replace word with choice. May query-replace.
-;;; ' ': Accept word this time.
-;;; 'i': Accept word and insert into private dictionary.
-;;; 'a': Accept word for this session.
-;;; 'A': Accept word and place in buffer-local dictionary.
-;;; 'r': Replace word with typed-in value. Rechecked.
-;;; 'R': Replace word with typed-in value. Query-replaced in buffer. Rechecked.
-;;; '?': Show these commands
-;;; 'x': Exit spelling buffer. Move cursor to original point.
-;;; 'X': Exit spelling buffer. Leave cursor at the current point.
-;;; 'q': Quit spelling session (Kills ispell process).
-;;; 'l': Look up typed-in replacement in alternate dictionary. Wildcards okay.
-;;; 'u': Like 'i', but the word is lower-cased first.
-;;; 'm': Like 'i', but allows one to include dictionary completion info.
-;;; 'C-l': redraws screen
-;;; 'C-r': recursive edit
-;;; 'C-z': suspend emacs or iconify frame
-;;;
-;;; Buffer-Local features:
-;;; There are a number of buffer-local features that can be used to customize
-;;; ispell for the current buffer. This includes language dictionaries,
-;;; personal dictionaries, parsing, and local word spellings. Each of these
-;;; local customizations are done either through local variables, or by
-;;; including the keyword and argument(s) at the end of the buffer (usually
-;;; prefixed by the comment characters). See the end of this file for
-;;; examples. The local keywords and variables are:
-;;;
-;;; ispell-dictionary-keyword language-dictionary
-;;; uses local variable ispell-local-dictionary
-;;; ispell-pdict-keyword personal-dictionary
-;;; uses local variable ispell-local-pdict
-;;; ispell-parsing-keyword mode-arg extended-char-arg
-;;; ispell-words-keyword any number of local word spellings
-;;;
-;;;
-;;; BUGS:
-;;; Highlighting in version 19 still doesn't work on tty's.
-;;; On some versions of emacs, growing the minibuffer fails.
-;;;
-;;; HISTORY
-;;;
-;;; Revision 2.37 1995/6/13 12:05:28 stevens
-;;; Removed autoload from ispell-dictionary-alist. *choices* mode-line shows
-;;; misspelled word. Block skip for pgp & forwarded messages added.
-;;; RMS: the autoload changes had problems and I removed them.
-;;;
-;;; Revision 2.36 1995/2/6 17:39:38 stevens
-;;; Properly adjust screen with different ispell-choices-win-default-height
-;;; settings. Skips SGML entity references.
-;;;
-;;; Revision 2.35 1995/1/13 14:16:46 stevens
-;;; Skips SGML tags, ispell-change-dictionary fix for add-hook, assure personal
-;;; dictionary is saved when called from the menu
-;;;
-;;; Revision 2.34 1994/12/08 13:17:41 stevens
-;;; Interaction corrected to function with all 3.1 ispell versions.
-;;;
-;;; Revision 2.33 1994/11/24 02:31:20 stevens
-;;; Repaired bug introduced in 2.32 that corrupts buffers when correcting.
-;;; Improved buffer scrolling. Nondestructive buffer selections allowed.
-;;;
-;;; Revision 2.32 1994/10/31 21:10:08 geoff
-;;; Many revisions accepted from RMS/FSF. I think (though I don't know) that
-;;; this represents an 'official' version.
-;;;
-;;; Revision 2.31 1994/5/31 10:18:17 stevens
-;;; Repaired comments. buffer-local commands executed in `ispell-word' now.
-;;; German dictionary described for extended character mode. Dict messages.
-;;;
-;;; Revision 2.30 1994/5/20 22:18:36 stevens
-;;; Continue ispell from ispell-word, C-z functionality fixed.
-;;;
-;;; Revision 2.29 1994/5/12 09:44:33 stevens
-;;; Restored ispell-use-ptys-p, ispell-message aborts sends with interrupt.
-;;; defined fn ispell
-;;;
-;;; Revision 2.28 1994/4/28 16:24:40 stevens
-;;; Window checking when ispell-message put on gnus-inews-article-hook jwz.
-;;; prefixed ispell- to highlight functions and horiz-scroll fn.
-;;; Try and respect case of word in ispell-complete-word.
-;;; Ignore non-char events. Ispell-use-ptys-p commented out. Lucid menu.
-;;; Better interrupt handling. ispell-message improvements from Ethan.
-;;;
-;;; Revision 2.27
-;;; version 18 explicit C-g handling disabled as it didn't work. Added
-;;; ispell-extra-args for ispell customization (jwz)
-;;;
-;;; Revision 2.26 1994/2/15 16:11:14 stevens
-;;; name changes for copyright assignment. Added word-frags in complete-word.
-;;; Horizontal scroll (John Conover). Query-replace matches words now. bugs.
-;;;
-;;; Revision 2.25
-;;; minor mods, upgraded ispell-message
-;;;
-;;; Revision 2.24
-;;; query-replace more robust, messages, defaults, ispell-change-dict.
-;;;
-;;; Revision 2.23 1993/11/22 23:47:03 stevens
-;;; ispell-message, Fixed highlighting, added menu-bar, fixed ispell-help, ...
-;;;
-;;; Revision 2.22
-;;; Added 'u' command. Fixed default in ispell-local-dictionary.
-;;; fixed affix rules display. Tib skipping more robust. Contributions by
-;;; Per Abraham (parser selection), Denis Howe, and Eberhard Mattes.
-;;;
-;;; Revision 2.21 1993/06/30 14:09:04 stevens
-;;; minor bugs. (nroff word skipping fixed)
-;;;
-;;; Revision 2.20 1993/06/30 14:09:04 stevens
-;;;
-;;; Debugging and contributions by: Boris Aronov, Rik Faith, Chris Moore,
-;;; Kevin Rodgers, Malcolm Davis.
-;;; Particular thanks to Michael Lipp, Jamie Zawinski, Phil Queinnec
-;;; and John Heidemann for suggestions and code.
-;;; Major update including many tweaks.
-;;; Many changes were integrations of suggestions.
-;;; lookup-words rehacked to use call-process (Jamie).
-;;; ispell-complete-word rehacked to be compatible with the rest of the
-;;; system for word searching and to include multiple wildcards,
-;;; and it's own dictionary.
-;;; query-replace capability added. New options 'X', 'R', and 'A'.
-;;; buffer-local modes for dictionary, word-spelling, and formatter-parsing.
-;;; Many random bugs, like commented comments being skipped, fix to
-;;; keep-choices-win, fix for math mode, added pipe mode choice,
-;;; fixed 'q' command, ispell-word checks previous word and leave cursor
-;;; in same location. Fixed tib code which could drop spelling regions.
-;;; Cleaned up setq calls for efficiency. Gave more context on window overlays.
-;;; Assure context on ispell-command-loop. Window lossage in look cmd fixed.
-;;; Due to pervasive opinion, common-lisp package syntax removed. Display
-;;; problem when not highlighting.
-;;;
-;;; Revision 2.19 1992/01/10 10:54:08 geoff
-;;; Make another attempt at fixing the "Bogus, dude" problem. This one is
-;;; less elegant, but has the advantage of working.
-;;;
-;;; Revision 2.18 1992/01/07 10:04:52 geoff
-;;; Fix the "Bogus, Dude" problem in ispell-word.
-;;;
-;;; Revision 2.17 1991/09/12 00:01:42 geoff
-;;; Add some changes to make ispell-complete-word work better, though
-;;; still not perfectly.
-;;;
-;;; Revision 2.16 91/09/04 18:00:52 geoff
-;;; More updates from Sebastian, to make the multiple-dictionary support
-;;; more flexible.
-;;;
-;;; Revision 2.15 91/09/04 17:30:02 geoff
-;;; Sebastian Kremer's tib support
-;;;
-;;; Revision 2.14 91/09/04 16:19:37 geoff
-;;; Don't do set-window-start if the move-to-window-line moved us
-;;; downward, rather than upward. This prevents getting the buffer all
-;;; confused. Also, don't use the "not-modified" function to clear the
-;;; modification flag; instead use set-buffer-modified-p. This prevents
-;;; extra messages from flashing.
-;;;
-;;; Revision 2.13 91/09/04 14:35:41 geoff
-;;; Fix a spelling error in a comment. Add code to handshake with the
-;;; ispell process before sending anything to it.
-;;;
-;;; Revision 2.12 91/09/03 20:14:21 geoff
-;;; Add Sebastian Kremer's multiple-language support.
-;;;
-;;;
-;;; Walt Buehring
-;;; Texas Instruments - Computer Science Center
-;;; ARPA: Buehring%TI-CSL@CSNet-Relay
-;;; UUCP: {smu, texsun, im4u, rice} ! ti-csl ! buehring
-;;;
-;;; ispell-region and associated routines added by
-;;; Perry Smith
-;;; pedz@bobkat
-;;; Tue Jan 13 20:18:02 CST 1987
-;;;
-;;; extensively modified by Mark Davies and Andrew Vignaux
-;;; {mark,andrew}@vuwcomp
-;;; Sun May 10 11:45:04 NZST 1987
-;;;
-;;; Ken Stevens ARPA: k.stevens@ieee.org
-;;; Tue Jan 3 16:59:07 PST 1989
-;;; This file has overgone a major overhaul to be compatible with ispell
-;;; version 2.1. Most of the functions have been totally rewritten, and
-;;; many user-accessible variables have been added. The syntax table has
-;;; been removed since it didn't work properly anyway, and a filter is
-;;; used rather than a buffer. Regular expressions are used based on
-;;; ispell's internal definition of characters (see ispell(4)).
-;;; Some new updates:
-;;; - Updated to version 3.0 to include terse processing.
-;;; - Added a variable for the look command.
-;;; - Fixed a bug in ispell-word when cursor is far away from the word
-;;; that is to be checked.
-;;; - Ispell places the incorrect word or guess in the minibuffer now.
-;;; - fixed a bug with 'l' option when multiple windows are on the screen.
-;;; - lookup-words just didn't work with the process filter. Fixed.
-;;; - Rewrote the process filter to make it cleaner and more robust
-;;; in the event of a continued line not being completed.
-;;; - Made ispell-init-process more robust in handling errors.
-;;; - Fixed bug in continuation location after a region has been modified by
-;;; correcting a misspelling.
-;;; Mon 17 Sept 1990
-;;;
-;;; Sebastian Kremer <sk@thp.uni-koeln.de>
-;;; Wed Aug 7 14:02:17 MET DST 1991
-;;; - Ported ispell-complete-word from Ispell 2 to Ispell 3.
-;;; - Added ispell-kill-ispell command.
-;;; - Added ispell-dictionary and ispell-dictionary-alist variables to
-;;; support other than default language. See their docstrings and
-;;; command ispell-change-dictionary.
-;;; - (ispelled it :-)
-;;; - Added ispell-skip-tib variable to support the tib bibliography
-;;; program.
-;;;
-;;;
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+;; Authors : Ken Stevens <k.stevens@ieee.org>
+;; Last Modified On: Tue Jun 13 12:05:28 EDT 1995
+;; Update Revision : 2.37
+;; Syntax : emacs-lisp
+;; Status : Release with 3.1.12+ ispell.
+;; Version : International Ispell Version 3.1 by Geoff Kuenning.
+;; Bug Reports : ispell-el-bugs@itcorp.com
+;; This file is part of GNU Emacs.
-;;; **********************************************************************
-;;; The following variables should be set according to personal preference
-;;; and location of binaries:
-;;; **********************************************************************
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;; Note: version numbers and time stamp are not updated
+;; when this file is edited for release with GNU Emacs.
+
+;;; Commentary:
+;; INSTRUCTIONS
+;;
+;; This code contains a section of user-settable variables that you should
+;; inspect prior to installation. Look past the end of the history list.
+;; Set them up for your locale and the preferences of the majority of the
+;; users. Otherwise the users may need to set a number of variables
+;; themselves.
+;; You particularly may want to change the default dictionary for your
+;; country and language.
+;;
+;;
+;; To fully install this, add this file to your Emacs Lisp directory and
+;; compile it with M-X byte-compile-file. Then add the following to the
+;; appropriate init file:
+;;
+;; (autoload 'ispell-word "ispell"
+;; "Check the spelling of word in buffer." t)
+;; (global-set-key "\e$" 'ispell-word)
+;; (autoload 'ispell-region "ispell"
+;; "Check the spelling of region." t)
+;; (autoload 'ispell-buffer "ispell"
+;; "Check the spelling of buffer." t)
+;; (autoload 'ispell-complete-word "ispell"
+;; "Look up current word in dictionary and try to complete it." t)
+;; (autoload 'ispell-change-dictionary "ispell"
+;; "Change ispell dictionary." t)
+;; (autoload 'ispell-message "ispell"
+;; "Check spelling of mail message or news post.")
+;;
+;; Depending on the mail system you use, you may want to include these:
+;;
+;; (add-hook 'news-inews-hook 'ispell-message)
+;; (add-hook 'mail-send-hook 'ispell-message)
+;; (add-hook 'mh-before-send-letter-hook 'ispell-message)
+;;
+;;
+;; Ispell has a TeX parser and a nroff parser (the default).
+;; The parsing is controlled by the variable ispell-parser. Currently
+;; it is just a "toggle" between TeX and nroff, but if more parsers are
+;; added it will be updated. See the variable description for more info.
+;;
+;;
+;; TABLE OF CONTENTS
+;;
+;; ispell-word
+;; ispell-region
+;; ispell-buffer
+;; ispell-message
+;; ispell-continue
+;; ispell-complete-word
+;; ispell-complete-word-interior-frag
+;; ispell-change-dictionary
+;; ispell-kill-ispell
+;; ispell-pdict-save
+;;
+;;
+;; Commands in ispell-region:
+;; Character replacement: Replace word with choice. May query-replace.
+;; ' ': Accept word this time.
+;; 'i': Accept word and insert into private dictionary.
+;; 'a': Accept word for this session.
+;; 'A': Accept word and place in buffer-local dictionary.
+;; 'r': Replace word with typed-in value. Rechecked.
+;; 'R': Replace word with typed-in value. Query-replaced in buffer. Rechecked.
+;; '?': Show these commands
+;; 'x': Exit spelling buffer. Move cursor to original point.
+;; 'X': Exit spelling buffer. Leave cursor at the current point.
+;; 'q': Quit spelling session (Kills ispell process).
+;; 'l': Look up typed-in replacement in alternate dictionary. Wildcards okay.
+;; 'u': Like 'i', but the word is lower-cased first.
+;; 'm': Like 'i', but allows one to include dictionary completion info.
+;; 'C-l': redraws screen
+;; 'C-r': recursive edit
+;; 'C-z': suspend emacs or iconify frame
+;;
+;; Buffer-Local features:
+;; There are a number of buffer-local features that can be used to customize
+;; ispell for the current buffer. This includes language dictionaries,
+;; personal dictionaries, parsing, and local word spellings. Each of these
+;; local customizations are done either through local variables, or by
+;; including the keyword and argument(s) at the end of the buffer (usually
+;; prefixed by the comment characters). See the end of this file for
+;; examples. The local keywords and variables are:
+;;
+;; ispell-dictionary-keyword language-dictionary
+;; uses local variable ispell-local-dictionary
+;; ispell-pdict-keyword personal-dictionary
+;; uses local variable ispell-local-pdict
+;; ispell-parsing-keyword mode-arg extended-char-arg
+;; ispell-words-keyword any number of local word spellings
+;;
+;;
+;; BUGS:
+;; Highlighting in version 19 still doesn't work on tty's.
+;; On some versions of emacs, growing the minibuffer fails.
+;;
+;; HISTORY
+;;
+;; Revision 2.37 1995/6/13 12:05:28 stevens
+;; Removed autoload from ispell-dictionary-alist. *choices* mode-line shows
+;; misspelled word. Block skip for pgp & forwarded messages added.
+;; RMS: the autoload changes had problems and I removed them.
+;;
+;; Revision 2.36 1995/2/6 17:39:38 stevens
+;; Properly adjust screen with different ispell-choices-win-default-height
+;; settings. Skips SGML entity references.
+;;
+;; Revision 2.35 1995/1/13 14:16:46 stevens
+;; Skips SGML tags, ispell-change-dictionary fix for add-hook, assure personal
+;; dictionary is saved when called from the menu
+;;
+;; Revision 2.34 1994/12/08 13:17:41 stevens
+;; Interaction corrected to function with all 3.1 ispell versions.
+;;
+;; Revision 2.33 1994/11/24 02:31:20 stevens
+;; Repaired bug introduced in 2.32 that corrupts buffers when correcting.
+;; Improved buffer scrolling. Nondestructive buffer selections allowed.
+;;
+;; Revision 2.32 1994/10/31 21:10:08 geoff
+;; Many revisions accepted from RMS/FSF. I think (though I don't know) that
+;; this represents an 'official' version.
+;;
+;; Revision 2.31 1994/5/31 10:18:17 stevens
+;; Repaired comments. buffer-local commands executed in `ispell-word' now.
+;; German dictionary described for extended character mode. Dict messages.
+;;
+;; Revision 2.30 1994/5/20 22:18:36 stevens
+;; Continue ispell from ispell-word, C-z functionality fixed.
+;;
+;; Revision 2.29 1994/5/12 09:44:33 stevens
+;; Restored ispell-use-ptys-p, ispell-message aborts sends with interrupt.
+;; defined fn ispell
+;;
+;; Revision 2.28 1994/4/28 16:24:40 stevens
+;; Window checking when ispell-message put on gnus-inews-article-hook jwz.
+;; prefixed ispell- to highlight functions and horiz-scroll fn.
+;; Try and respect case of word in ispell-complete-word.
+;; Ignore non-char events. Ispell-use-ptys-p commented out. Lucid menu.
+;; Better interrupt handling. ispell-message improvements from Ethan.
+;;
+;; Revision 2.27
+;; version 18 explicit C-g handling disabled as it didn't work. Added
+;; ispell-extra-args for ispell customization (jwz)
+;;
+;; Revision 2.26 1994/2/15 16:11:14 stevens
+;; name changes for copyright assignment. Added word-frags in complete-word.
+;; Horizontal scroll (John Conover). Query-replace matches words now. bugs.
+;;
+;; Revision 2.25
+;; minor mods, upgraded ispell-message
+;;
+;; Revision 2.24
+;; query-replace more robust, messages, defaults, ispell-change-dict.
+;;
+;; Revision 2.23 1993/11/22 23:47:03 stevens
+;; ispell-message, Fixed highlighting, added menu-bar, fixed ispell-help, ...
+;;
+;; Revision 2.22
+;; Added 'u' command. Fixed default in ispell-local-dictionary.
+;; fixed affix rules display. Tib skipping more robust. Contributions by
+;; Per Abraham (parser selection), Denis Howe, and Eberhard Mattes.
+;;
+;; Revision 2.21 1993/06/30 14:09:04 stevens
+;; minor bugs. (nroff word skipping fixed)
+;;
+;; Revision 2.20 1993/06/30 14:09:04 stevens
+;;
+;; Debugging and contributions by: Boris Aronov, Rik Faith, Chris Moore,
+;; Kevin Rodgers, Malcolm Davis.
+;; Particular thanks to Michael Lipp, Jamie Zawinski, Phil Queinnec
+;; and John Heidemann for suggestions and code.
+;; Major update including many tweaks.
+;; Many changes were integrations of suggestions.
+;; lookup-words rehacked to use call-process (Jamie).
+;; ispell-complete-word rehacked to be compatible with the rest of the
+;; system for word searching and to include multiple wildcards,
+;; and it's own dictionary.
+;; query-replace capability added. New options 'X', 'R', and 'A'.
+;; buffer-local modes for dictionary, word-spelling, and formatter-parsing.
+;; Many random bugs, like commented comments being skipped, fix to
+;; keep-choices-win, fix for math mode, added pipe mode choice,
+;; fixed 'q' command, ispell-word checks previous word and leave cursor
+;; in same location. Fixed tib code which could drop spelling regions.
+;; Cleaned up setq calls for efficiency. Gave more context on window overlays.
+;; Assure context on ispell-command-loop. Window lossage in look cmd fixed.
+;; Due to pervasive opinion, common-lisp package syntax removed. Display
+;; problem when not highlighting.
+;;
+;; Revision 2.19 1992/01/10 10:54:08 geoff
+;; Make another attempt at fixing the "Bogus, dude" problem. This one is
+;; less elegant, but has the advantage of working.
+;;
+;; Revision 2.18 1992/01/07 10:04:52 geoff
+;; Fix the "Bogus, Dude" problem in ispell-word.
+;;
+;; Revision 2.17 1991/09/12 00:01:42 geoff
+;; Add some changes to make ispell-complete-word work better, though
+;; still not perfectly.
+;;
+;; Revision 2.16 91/09/04 18:00:52 geoff
+;; More updates from Sebastian, to make the multiple-dictionary support
+;; more flexible.
+;;
+;; Revision 2.15 91/09/04 17:30:02 geoff
+;; Sebastian Kremer's tib support
+;;
+;; Revision 2.14 91/09/04 16:19:37 geoff
+;; Don't do set-window-start if the move-to-window-line moved us
+;; downward, rather than upward. This prevents getting the buffer all
+;; confused. Also, don't use the "not-modified" function to clear the
+;; modification flag; instead use set-buffer-modified-p. This prevents
+;; extra messages from flashing.
+;;
+;; Revision 2.13 91/09/04 14:35:41 geoff
+;; Fix a spelling error in a comment. Add code to handshake with the
+;; ispell process before sending anything to it.
+;;
+;; Revision 2.12 91/09/03 20:14:21 geoff
+;; Add Sebastian Kremer's multiple-language support.
+;;
+;;
+;; Walt Buehring
+;; Texas Instruments - Computer Science Center
+;; ARPA: Buehring%TI-CSL@CSNet-Relay
+;; UUCP: {smu, texsun, im4u, rice} ! ti-csl ! buehring
+;;
+;; ispell-region and associated routines added by
+;; Perry Smith
+;; pedz@bobkat
+;; Tue Jan 13 20:18:02 CST 1987
+;;
+;; extensively modified by Mark Davies and Andrew Vignaux
+;; {mark,andrew}@vuwcomp
+;; Sun May 10 11:45:04 NZST 1987
+;;
+;; Ken Stevens ARPA: k.stevens@ieee.org
+;; Tue Jan 3 16:59:07 PST 1989
+;; This file has overgone a major overhaul to be compatible with ispell
+;; version 2.1. Most of the functions have been totally rewritten, and
+;; many user-accessible variables have been added. The syntax table has
+;; been removed since it didn't work properly anyway, and a filter is
+;; used rather than a buffer. Regular expressions are used based on
+;; ispell's internal definition of characters (see ispell(4)).
+;; Some new updates:
+;; - Updated to version 3.0 to include terse processing.
+;; - Added a variable for the look command.
+;; - Fixed a bug in ispell-word when cursor is far away from the word
+;; that is to be checked.
+;; - Ispell places the incorrect word or guess in the minibuffer now.
+;; - fixed a bug with 'l' option when multiple windows are on the screen.
+;; - lookup-words just didn't work with the process filter. Fixed.
+;; - Rewrote the process filter to make it cleaner and more robust
+;; in the event of a continued line not being completed.
+;; - Made ispell-init-process more robust in handling errors.
+;; - Fixed bug in continuation location after a region has been modified by
+;; correcting a misspelling.
+;; Mon 17 Sept 1990
+;;
+;; Sebastian Kremer <sk@thp.uni-koeln.de>
+;; Wed Aug 7 14:02:17 MET DST 1991
+;; - Ported ispell-complete-word from Ispell 2 to Ispell 3.
+;; - Added ispell-kill-ispell command.
+;; - Added ispell-dictionary and ispell-dictionary-alist variables to
+;; support other than default language. See their docstrings and
+;; command ispell-change-dictionary.
+;; - (ispelled it :-)
+;; - Added ispell-skip-tib variable to support the tib bibliography
+;; program.
+
+
+;; **********************************************************************
+;; The following variables should be set according to personal preference
+;; and location of binaries:
+;; **********************************************************************
+
+;; ******* THIS FILE IS WRITTEN FOR ISPELL VERSION 3.1
-;;; ******* THIS FILE IS WRITTEN FOR ISPELL VERSION 3.1
;;; Code:
(defvar ispell-highlight-p t
-;;; ispell.el --- this is the GNU EMACS interface to GNU ISPELL version 4.
+;;; ispell4.el --- this is the GNU EMACS interface to GNU ISPELL version 4.
-;;Copyright (C) 1990, 1991, 1993 Free Software Foundation, Inc.
+;; Copyright (C) 1990, 1991, 1993 Free Software Foundation, Inc.
;; Keywords: wp
-;;This file is part of GNU Emacs.
-;;
-;;GNU Emacs is free software; you can redistribute it and/or modify
-;;it under the terms of the GNU General Public License as published by
-;;the Free Software Foundation; either version 2, or (at your option)
-;;any later version.
-;;
-;;GNU Emacs is distributed in the hope that it will be useful,
-;;but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;GNU General Public License for more details.
-;;
-;;You should have received a copy of the GNU General Public License
-;;along with GNU Emacs; see the file COPYING. If not, write to
-;;the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; outline.el --- outline mode commands for Emacs
+
;; Copyright (C) 1986, 1993, 1994 Free Software Foundation, Inc.
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; outline.el --- outline mode commands for Emacs
+
;; Copyright (C) 1986, 1993, 1994, 1995 Free Software Foundation, Inc.
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; page-ext.el --- extended page handling commands
-;; You may use these commands to handle an address list or other
-;; small data base.
-
;; Copyright (C) 1990, 1991, 1993, 1994 Free Software Foundation
;; Maintainer: Robert J. Chassell <bob@gnu.ai.mit.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Commentary:
+
+;; You may use these commands to handle an address list or other
+;; small data base.
\f
;;; Summary
-; The current page commands are:
-
-; forward-page C-x ]
-; backward-page C-x [
-; narrow-to-page C-x p
-; count-lines-page C-x l
-; mark-page C-x C-p (change this to C-x C-p C-m)
-; sort-pages not bound
-; what-page not bound
-
-; The new page handling commands all use `C-x C-p' as a prefix. This
-; means that the key binding for `mark-page' must be changed.
-; Otherwise, no other changes are made to the current commands or
-; their bindings.
-
-; New page handling commands:
-
-; next-page C-x C-p C-n
-; previous-page C-x C-p C-p
-; search-pages C-x C-p C-s
-; add-new-page C-x C-p C-a
-; sort-pages-buffer C-x C-p s
-; set-page-delimiter C-x C-p C-l
-; pages-directory C-x C-p C-d
-; pages-directory-for-addresses C-x C-p d
-; pages-directory-goto C-c C-c
+;; The current page commands are:
+
+;; forward-page C-x ]
+;; backward-page C-x [
+;; narrow-to-page C-x p
+;; count-lines-page C-x l
+;; mark-page C-x C-p (change this to C-x C-p C-m)
+;; sort-pages not bound
+;; what-page not bound
+
+;; The new page handling commands all use `C-x C-p' as a prefix. This
+;; means that the key binding for `mark-page' must be changed.
+;; Otherwise, no other changes are made to the current commands or
+;; their bindings.
+
+;; New page handling commands:
+
+;; next-page C-x C-p C-n
+;; previous-page C-x C-p C-p
+;; search-pages C-x C-p C-s
+;; add-new-page C-x C-p C-a
+;; sort-pages-buffer C-x C-p s
+;; set-page-delimiter C-x C-p C-l
+;; pages-directory C-x C-p C-d
+;; pages-directory-for-addresses C-x C-p d
+;; pages-directory-goto C-c C-c
\f
;;; Using the page commands
-; The page commands are helpful in several different contexts. For
-; example, programmers often divide source files into sections using the
-; `page-delimiter'; you can use the `pages-directory' command to list
-; the sections.
-
-; You may change the buffer local value of the `page-delimiter' with
-; the `set-page-delimiter' command. This command is bound to `C-x C-p
-; C-l' The command prompts you for a new value for the page-delimiter.
-; Called with a prefix-arg, the command resets the value of the
-; page-delimiter to its original value.
-
-; You may set several user options:
-;
-; The `pages-directory-buffer-narrowing-p' variable causes the
-; `pages-directory-goto' command to narrow to the destination page.
-;
-; The `pages-directory-for-adding-page-narrowing-p' variable, causes the
-; `add-new-page' command to narrow to the new entry.
-;
-; The `pages-directory-for-adding-new-page-before-current-page-p' variable
-; causes the `add-new-page' command to insert a new page before current
-; page.
-;
-; These variables are true by default.
-;
-; Additional, addresses-related user options are described in the next page
-; of this file.
+;; The page commands are helpful in several different contexts. For
+;; example, programmers often divide source files into sections using the
+;; `page-delimiter'; you can use the `pages-directory' command to list
+;; the sections.
+
+;; You may change the buffer local value of the `page-delimiter' with
+;; the `set-page-delimiter' command. This command is bound to `C-x C-p
+;; C-l' The command prompts you for a new value for the page-delimiter.
+;; Called with a prefix-arg, the command resets the value of the
+;; page-delimiter to its original value.
+
+;; You may set several user options:
+;;
+;; The `pages-directory-buffer-narrowing-p' variable causes the
+;; `pages-directory-goto' command to narrow to the destination page.
+;;
+;; The `pages-directory-for-adding-page-narrowing-p' variable, causes the
+;; `add-new-page' command to narrow to the new entry.
+;;
+;; The `pages-directory-for-adding-new-page-before-current-page-p' variable
+;; causes the `add-new-page' command to insert a new page before current
+;; page.
+;;
+;; These variables are true by default.
+;;
+;; Additional, addresses-related user options are described in the next page
+;; of this file.
\f
;;; Handling an address list or small data base
-; You may use the page commands to handle an address list or other
-; small data base. Put each address or entry on its own page. The
-; first line of text in each page is a `header line' and is listed by
-; the `pages-directory' or `pages-directory-for-addresses' command.
-
-; Specifically:
-;
-; 1. Begin each entry with a `page-delimiter' (which is, by default,
-; `^L' at the beginning of the line).
-;
-; 2. The first line of text in each entry is the `heading line'; it
-; will appear in the pages-directory-buffer which is constructed
-; using the `C-x C-p C-d' (pages-directory) command or the `C-x
-; C-p d' (pages-directory-for-addresses) command.
-;
-; The heading line may be on the same line as the page-delimiter
-; or it may follow after. It is the first non-blank line on the
-; page. Conventionally, the heading line is placed on the line
-; immediately following the line containing page-delimiter.
-;
-; 3. Follow the heading line with the body of the entry. The body
-; extends up to the next `page-delimiter'. The body may be of any
-; length. It is conventional to place a blank line after the last
-; line of the body.
-
-; For example, a file might look like this:
-;
-; FSF
-; Free Software Foundation
-; 675 Massachusetts Avenue
-; Cambridge, MA 02139 USA
-; (617) 876-3296
-; gnu@prep.ai.mit.edu
-;
-; \f
-; House Subcommittee on Intellectual Property,
-; U.S. House of Representatives,
-; Washington, DC 20515
-;
-; Congressional committee concerned with permitting or preventing
-; monopolistic restrictions on the use of software technology.
-;
-; \f
-; George Lakoff
-; ``Women, Fire, and Dangerous Things:
-; What Categories Reveal about the Mind''
-; 1987, Univ. of Chicago Press
-;
-; About philosophy, Whorfian effects, and linguistics.
-;
-; \f
-; OBI (On line text collection.)
-; Open Book Initiative
-; c/o Software Tool & Die
-; 1330 Beacon St, Brookline, MA 02146 USA
-; (617) 739-0202
-; obi@world.std.com
-
-; In this example, the heading lines are:
-;
-; FSF
-; House Subcommittee on Intellectual Property
-; George Lakoff
-; OBI (On line text collection.)
-
-; The `C-x C-p s' (sort-pages-buffer) command sorts the entries in the
-; buffer alphabetically.
-
-; You may use any of the page commands, including the `next-page',
-; `previous-page', `add-new-page', `mark-page', and `search-pages'
-; commands.
-
-; You may use either the `C-x C-p d' (pages-directory-for-addresses)
-; or the `C-x C-p C-d' (pages-directory) command to construct and
-; display a directory of all the heading lines.
-
-; In the directory, you may position the cursor over a heading line
-; and type `C-c C-c' (pages-directory-goto) to go to the entry to
-; which it refers in the pages buffer.
-
-; You can type `C-c C-p C-a' (add-new-page) to add a new entry in the
-; pages buffer or address file. This is the same command you use to
-; add a new entry when you are in the pages buffer or address file.
-
-; If you wish, you may create several different directories,
-; one for each different buffer.
+;; You may use the page commands to handle an address list or other
+;; small data base. Put each address or entry on its own page. The
+;; first line of text in each page is a `header line' and is listed by
+;; the `pages-directory' or `pages-directory-for-addresses' command.
+
+;; Specifically:
+;;
+;; 1. Begin each entry with a `page-delimiter' (which is, by default,
+;; `^L' at the beginning of the line).
+;;
+;; 2. The first line of text in each entry is the `heading line'; it
+;; will appear in the pages-directory-buffer which is constructed
+;; using the `C-x C-p C-d' (pages-directory) command or the `C-x
+;; C-p d' (pages-directory-for-addresses) command.
+;;
+;; The heading line may be on the same line as the page-delimiter
+;; or it may follow after. It is the first non-blank line on the
+;; page. Conventionally, the heading line is placed on the line
+;; immediately following the line containing page-delimiter.
+;;
+;; 3. Follow the heading line with the body of the entry. The body
+;; extends up to the next `page-delimiter'. The body may be of any
+;; length. It is conventional to place a blank line after the last
+;; line of the body.
+
+;; For example, a file might look like this:
+;;
+;; FSF
+;; Free Software Foundation
+;; 675 Massachusetts Avenue
+;; Cambridge, MA 02139 USA
+;; (617) 876-3296
+;; gnu@prep.ai.mit.edu
+;;
+;; \f
+;; House Subcommittee on Intellectual Property,
+;; U.S. House of Representatives,
+;; Washington, DC 20515
+;;
+;; Congressional committee concerned with permitting or preventing
+;; monopolistic restrictions on the use of software technology.
+;;
+;; \f
+;; George Lakoff
+;; ``Women, Fire, and Dangerous Things:
+;; What Categories Reveal about the Mind''
+;; 1987, Univ. of Chicago Press
+;;
+;; About philosophy, Whorfian effects, and linguistics.
+;;
+;; \f
+;; OBI (On line text collection.)
+;; Open Book Initiative
+;; c/o Software Tool & Die
+;; 1330 Beacon St, Brookline, MA 02146 USA
+;; (617) 739-0202
+;; obi@world.std.com
+
+;; In this example, the heading lines are:
+;;
+;; FSF
+;; House Subcommittee on Intellectual Property
+;; George Lakoff
+;; OBI (On line text collection.)
+
+;; The `C-x C-p s' (sort-pages-buffer) command sorts the entries in the
+;; buffer alphabetically.
+
+;; You may use any of the page commands, including the `next-page',
+;; `previous-page', `add-new-page', `mark-page', and `search-pages'
+;; commands.
+
+;; You may use either the `C-x C-p d' (pages-directory-for-addresses)
+;; or the `C-x C-p C-d' (pages-directory) command to construct and
+;; display a directory of all the heading lines.
+
+;; In the directory, you may position the cursor over a heading line
+;; and type `C-c C-c' (pages-directory-goto) to go to the entry to
+;; which it refers in the pages buffer.
+
+;; You can type `C-c C-p C-a' (add-new-page) to add a new entry in the
+;; pages buffer or address file. This is the same command you use to
+;; add a new entry when you are in the pages buffer or address file.
+
+;; If you wish, you may create several different directories,
+;; one for each different buffer.
;; `pages-directory-for-addresses' in detail
-; The `pages-directory-for-addresses' assumes a default addresses
-; file. You do not need to specify the addresses file but merely type
-; `C-x C-p d' from any buffer. The command finds the file, constructs
-; a directory for it, and switches you to the directory. If you call
-; the command with a prefix arg, `C-u C-x C-p d', it prompts you for a
-; file name.
+;; The `pages-directory-for-addresses' assumes a default addresses
+;; file. You do not need to specify the addresses file but merely type
+;; `C-x C-p d' from any buffer. The command finds the file, constructs
+;; a directory for it, and switches you to the directory. If you call
+;; the command with a prefix arg, `C-u C-x C-p d', it prompts you for a
+;; file name.
-; You may customize the addresses commands:
+;; You may customize the addresses commands:
-; The `pages-addresses-file-name' variable determines the name of
-; the addresses file; by default it is "~/addresses".
+;; The `pages-addresses-file-name' variable determines the name of
+;; the addresses file; by default it is "~/addresses".
-; The `pages-directory-for-addresses-goto-narrowing-p' variable
-; determines whether `pages-directory-goto' narrows the addresses
-; buffer to the entry, which it does by default.
+;; The `pages-directory-for-addresses-goto-narrowing-p' variable
+;; determines whether `pages-directory-goto' narrows the addresses
+;; buffer to the entry, which it does by default.
-; The `pages-directory-for-addresses-buffer-keep-windows-p' variable
-; determines whether `pages-directory-for-addresses' deletes other
-; windows to show as many lines as possible on the screen or works
-; in the usual Emacs manner and keeps other windows. Default is to
-; keep other windows.
+;; The `pages-directory-for-addresses-buffer-keep-windows-p' variable
+;; determines whether `pages-directory-for-addresses' deletes other
+;; windows to show as many lines as possible on the screen or works
+;; in the usual Emacs manner and keeps other windows. Default is to
+;; keep other windows.
-; The `pages-directory-for-adding-addresses-narrowing-p' variable
-; determines whether `pages-directory-for-addresses' narrows the
-; addresses buffer to a new entry when you are adding that entry.
-; Default is to narrow to new entry, which means you see a blank
-; screen before you write the new entry.
+;; The `pages-directory-for-adding-addresses-narrowing-p' variable
+;; determines whether `pages-directory-for-addresses' narrows the
+;; addresses buffer to a new entry when you are adding that entry.
+;; Default is to narrow to new entry, which means you see a blank
+;; screen before you write the new entry.
;; `pages-directory' in detail
-; Call the `pages-directory' command from the buffer for which you
-; want a directory created; it creates a directory for the buffer and
-; pops you to the directory.
-
-; The `pages-directory' command has several options:
-
-; Called with a prefix arg, `C-u C-x C-p C-d', the `pages-directory'
-; prompts you for a regular expression and only lists only those
-; header lines that are part of pages that contain matches to the
-; regexp. In the example above, `C-u C-x C-p C-d 617 RET' would
-; match the telephone area code of the first and fourth entries, so
-; only the header lines of those two entries would appear in the
-; pages-directory-buffer.
-;
-; Called with a numeric argument, the `pages-directory' command
-; lists the number of lines in each page. This is helpful when you
-; are printing hardcopy.
-
-; Called with a negative numeric argument, the `pages-directory'
-; command lists the lengths of pages whose contents match a regexp.
+;; Call the `pages-directory' command from the buffer for which you
+;; want a directory created; it creates a directory for the buffer and
+;; pops you to the directory.
+
+;; The `pages-directory' command has several options:
+
+;; Called with a prefix arg, `C-u C-x C-p C-d', the `pages-directory'
+;; prompts you for a regular expression and only lists only those
+;; header lines that are part of pages that contain matches to the
+;; regexp. In the example above, `C-u C-x C-p C-d 617 RET' would
+;; match the telephone area code of the first and fourth entries, so
+;; only the header lines of those two entries would appear in the
+;; pages-directory-buffer.
+;;
+;; Called with a numeric argument, the `pages-directory' command
+;; lists the number of lines in each page. This is helpful when you
+;; are printing hardcopy.
+
+;; Called with a negative numeric argument, the `pages-directory'
+;; command lists the lengths of pages whose contents match a regexp.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; Change Log:
-; HISTORY
-; 9/88, created H.Kautz
-; modified 1/19/89, allow books with editor but no author;
-; added %O ordering field;
-; appended illegal multiple fields, instead of
-; discarding;
-; added rule, a tech report whose %R number
-; contains "ISBN" is really a book
-; added rule, anything with an editor is a book
-; or a proceedings
-; added 'manual type, for items with institution
-; but no author or editor
-; fixed bug so trailing blanks are trimmed
-; added 'proceedings type
-; used "organization" field for proceedings
-; modified 2/16/89, updated help messages
-; modified 2/23/89, include capitalize stop words in r2b stop words,
-; fixed problems with contractions (e.g. it's),
-; caught multiple stop words in a row
-; modified 3/1/89, fixed capitalize-title for first words all caps
-; modified 3/15/89, allow use of " to delimit fields
-; modified 4/18/89, properly "quote" special characters on output
+;; HISTORY
+;; 9/88, created H.Kautz
+;; modified 1/19/89, allow books with editor but no author;
+;; added %O ordering field;
+;; appended illegal multiple fields, instead of
+;; discarding;
+;; added rule, a tech report whose %R number
+;; contains "ISBN" is really a book
+;; added rule, anything with an editor is a book
+;; or a proceedings
+;; added 'manual type, for items with institution
+;; but no author or editor
+;; fixed bug so trailing blanks are trimmed
+;; added 'proceedings type
+;; used "organization" field for proceedings
+;; modified 2/16/89, updated help messages
+;; modified 2/23/89, include capitalize stop words in r2b stop words,
+;; fixed problems with contractions (e.g. it's),
+;; caught multiple stop words in a row
+;; modified 3/1/89, fixed capitalize-title for first words all caps
+;; modified 3/15/89, allow use of " to delimit fields
+;; modified 4/18/89, properly "quote" special characters on output
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;
+
;; Functions to look up references in bibliography files given lists of
;; keywords, similar to refer(1). I don't use tags since tags on .bib files
;; only picks up the cite key, where as refer-find-entry looks for occurrences
;; the (forward-paragraph 1) call in refer-find-entry-in-file.
;;; ChangeLog:
-;;
+
;; 01/08/89 Ashwin Ram <Ram-Ashwin@cs.yale.edu>
;; Initial release.
;;
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; texinfmt.el --- format Texinfo files into Info files.
-;; Copyright (C) 1985, 1986, 1988,
-;; 1990, 1991, 1992, 1993 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993 Free Software
+;; Foundation, Inc.
;; Maintainer: Robert J. Chassell <bug-texinfo@prep.ai.mit.edu>
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; texinfo.el --- major mode for editing Texinfo files
-;; Copyright (C) 1985, '88, '89,
-;; '90, '91, '92, '93 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1988, 1989, 1990, 1991, 1992, 1993 Free Software
+;; Foundation, Inc.
;; Author: Robert J. Chassell
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
\f
;;; Autoloads:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Known bug: update commands fail to ignore @ignore.
+;; Known bug: update commands fail to ignore @ignore.
-;;; Summary: how to use the updating commands
+;; Summary: how to use the updating commands
-; The node and menu updating functions automatically
+;; The node and menu updating functions automatically
-; * insert missing `@node' lines,
-; * insert the `Next', `Previous' and `Up' pointers of a node,
-; * insert or update the menu for a section,
-; * create a master menu for a Texinfo source file.
-;
-; Passed an argument, the `texinfo-update-node' and
-; `texinfo-make-menu' functions do their jobs in the region.
-;
-; In brief, the functions for creating or updating nodes and menus, are:
-;
-; texinfo-update-node (&optional region-p)
-; texinfo-every-node-update ()
-; texinfo-sequential-node-update (&optional region-p)
-;
-; texinfo-make-menu (&optional region-p)
-; texinfo-all-menus-update ()
-; texinfo-master-menu ()
-;
-; texinfo-insert-node-lines (&optional title-p)
-;
-; texinfo-indent-menu-description (column &optional region-p)
+;; * insert missing `@node' lines,
+;; * insert the `Next', `Previous' and `Up' pointers of a node,
+;; * insert or update the menu for a section,
+;; * create a master menu for a Texinfo source file.
+;;
+;; Passed an argument, the `texinfo-update-node' and
+;; `texinfo-make-menu' functions do their jobs in the region.
+;;
+;; In brief, the functions for creating or updating nodes and menus, are:
+;;
+;; texinfo-update-node (&optional region-p)
+;; texinfo-every-node-update ()
+;; texinfo-sequential-node-update (&optional region-p)
+;;
+;; texinfo-make-menu (&optional region-p)
+;; texinfo-all-menus-update ()
+;; texinfo-master-menu ()
+;;
+;; texinfo-insert-node-lines (&optional title-p)
+;;
+;; texinfo-indent-menu-description (column &optional region-p)
-; The `texinfo-column-for-description' variable specifies the column to
-; which menu descriptions are indented.
+;; The `texinfo-column-for-description' variable specifies the column to
+;; which menu descriptions are indented.
-; Texinfo file structure
-; ----------------------
+;; Texinfo file structure
+;; ----------------------
-; To use the updating commands, you must structure your Texinfo file
-; hierarchically. Each `@node' line, with the exception of the top
-; node, must be accompanied by some kind of section line, such as an
-; `@chapter' or `@section' line. Each node-line/section-line
-; combination must look like this:
+;; To use the updating commands, you must structure your Texinfo file
+;; hierarchically. Each `@node' line, with the exception of the top
+;; node, must be accompanied by some kind of section line, such as an
+;; `@chapter' or `@section' line. Each node-line/section-line
+;; combination must look like this:
-; @node Lists and Tables, Cross References, Structuring, Top
-; @comment node-name, next, previous, up
-; @chapter Making Lists and Tables
+;; @node Lists and Tables, Cross References, Structuring, Top
+;; @comment node-name, next, previous, up
+;; @chapter Making Lists and Tables
-; or like this (without the `@comment' line):
+;; or like this (without the `@comment' line):
-; @node Lists and Tables, Cross References, Structuring, Top
-; @chapter Making Lists and Tables
+;; @node Lists and Tables, Cross References, Structuring, Top
+;; @chapter Making Lists and Tables
-; If the file has a `top' node, it must be called `top' or `Top' and
-; be the first node in the file.
+;; If the file has a `top' node, it must be called `top' or `Top' and
+;; be the first node in the file.
\f
;;; The update node functions described in detail
-; The `texinfo-update-node' function without an argument inserts
-; the correct next, previous and up pointers for the node in which
-; point is located (i.e., for the node preceding point).
+;; The `texinfo-update-node' function without an argument inserts
+;; the correct next, previous and up pointers for the node in which
+;; point is located (i.e., for the node preceding point).
-; With an argument, the `texinfo-update-node' function inserts the
-; correct next, previous and up pointers for the nodes inside the
-; region.
+;; With an argument, the `texinfo-update-node' function inserts the
+;; correct next, previous and up pointers for the nodes inside the
+;; region.
-; It does not matter whether the `@node' line has pre-existing
-; `Next', `Previous', or `Up' pointers in it. They are removed.
+;; It does not matter whether the `@node' line has pre-existing
+;; `Next', `Previous', or `Up' pointers in it. They are removed.
-; The `texinfo-every-node-update' function runs `texinfo-update-node'
-; on the whole buffer.
+;; The `texinfo-every-node-update' function runs `texinfo-update-node'
+;; on the whole buffer.
-; The `texinfo-sequential-node-update' function inserts the
-; immediately following and preceding node into the `Next' or
-; `Previous' pointers regardless of their hierarchical level. This is
-; only useful for certain kinds of text, like a novel, which you go
-; through sequentially.
+;; The `texinfo-sequential-node-update' function inserts the
+;; immediately following and preceding node into the `Next' or
+;; `Previous' pointers regardless of their hierarchical level. This is
+;; only useful for certain kinds of text, like a novel, which you go
+;; through sequentially.
\f
;;; The menu making functions described in detail
-; The `texinfo-make-menu' function without an argument creates or
-; updates a menu for the section encompassing the node that follows
-; point. With an argument, it makes or updates menus for the nodes
-; within or part of the marked region.
-
-; Whenever an existing menu is updated, the descriptions from
-; that menu are incorporated into the new menu. This is done by copying
-; descriptions from the existing menu to the entries in the new menu
-; that have the same node names. If the node names are different, the
-; descriptions are not copied to the new menu.
-
-; Menu entries that refer to other Info files are removed since they
-; are not a node within current buffer. This is a deficiency.
-
-; The `texinfo-all-menus-update' function runs `texinfo-make-menu'
-; on the whole buffer.
-
-; The `texinfo-master-menu' function creates an extended menu located
-; after the top node. (The file must have a top node.) The function
-; first updates all the regular menus in the buffer (incorporating the
-; descriptions from pre-existing menus), and then constructs a master
-; menu that includes every entry from every other menu. (However, the
-; function cannot update an already existing master menu; if one
-; exists, it must be removed before calling the function.)
-
-; The `texinfo-indent-menu-description' function indents every
-; description in the menu following point, to the specified column.
-; Non-nil argument (prefix, if interactive) means indent every
-; description in every menu in the region. This function does not
-; indent second and subsequent lines of a multi-line description.
-
-; The `texinfo-insert-node-lines' function inserts `@node' before the
-; `@chapter', `@section', and such like lines of a region in a Texinfo
-; file where the `@node' lines are missing.
-;
-; With a non-nil argument (prefix, if interactive), the function not
-; only inserts `@node' lines but also inserts the chapter or section
-; titles as the names of the corresponding nodes; and inserts titles
-; as node names in pre-existing `@node' lines that lack names.
-;
-; Since node names should be more concise than section or chapter
-; titles, node names so inserted will need to be edited manually.
+;; The `texinfo-make-menu' function without an argument creates or
+;; updates a menu for the section encompassing the node that follows
+;; point. With an argument, it makes or updates menus for the nodes
+;; within or part of the marked region.
+
+;; Whenever an existing menu is updated, the descriptions from
+;; that menu are incorporated into the new menu. This is done by copying
+;; descriptions from the existing menu to the entries in the new menu
+;; that have the same node names. If the node names are different, the
+;; descriptions are not copied to the new menu.
+
+;; Menu entries that refer to other Info files are removed since they
+;; are not a node within current buffer. This is a deficiency.
+
+;; The `texinfo-all-menus-update' function runs `texinfo-make-menu'
+;; on the whole buffer.
+
+;; The `texinfo-master-menu' function creates an extended menu located
+;; after the top node. (The file must have a top node.) The function
+;; first updates all the regular menus in the buffer (incorporating the
+;; descriptions from pre-existing menus), and then constructs a master
+;; menu that includes every entry from every other menu. (However, the
+;; function cannot update an already existing master menu; if one
+;; exists, it must be removed before calling the function.)
+
+;; The `texinfo-indent-menu-description' function indents every
+;; description in the menu following point, to the specified column.
+;; Non-nil argument (prefix, if interactive) means indent every
+;; description in every menu in the region. This function does not
+;; indent second and subsequent lines of a multi-line description.
+
+;; The `texinfo-insert-node-lines' function inserts `@node' before the
+;; `@chapter', `@section', and such like lines of a region in a Texinfo
+;; file where the `@node' lines are missing.
+;;
+;; With a non-nil argument (prefix, if interactive), the function not
+;; only inserts `@node' lines but also inserts the chapter or section
+;; titles as the names of the corresponding nodes; and inserts titles
+;; as node names in pre-existing `@node' lines that lack names.
+;;
+;; Since node names should be more concise than section or chapter
+;; titles, node names so inserted will need to be edited manually.
\f
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;;; Commentary:
-;;
+
;; This file provides routines for getting the `thing' at the location of
;; point, whatever that `thing' happens to be. The `thing' is defined by
;; it's beginning and end positions in the buffer.
;; (thing-at-point 'line)
;; (thing-at-point 'page)
-;;; Code: =================================================================
+;;; Code:
(provide 'thingatpt)
-;;=== Basic movement ======================================================
+;; Basic movement
;;;###autoload
(defun forward-thing (THING &optional N)
(funcall forward-op (or N 1))
(error "Can't determine how to move over %ss" THING))))
-;;=== General routines ====================================================
+;; General routines
;;;###autoload
(defun bounds-of-thing-at-point (THING)
(if bounds
(buffer-substring (car bounds) (cdr bounds)))))
-;;=== Go to beginning/end =================================================
+;; Go to beginning/end
(defun beginning-of-thing (THING)
(let ((bounds (bounds-of-thing-at-point THING)))
(or bounds (error "No %s here" THING))
(goto-char (cdr bounds))))
-;;=== Special cases =======================================================
+;; Special cases
-;;--- Lines ---
+;; Lines
;; bolp will be false when you click on the last line in the buffer
;; and it has no final newline.
(put 'line 'beginning-op
(function (lambda () (if (bolp) (forward-line -1) (beginning-of-line)))))
-;;--- Sexps ---
+;; Sexps
(defun in-string-p ()
(let ((orig (point)))
(put 'sexp 'end-op 'end-of-sexp)
-;;--- Lists ---
+;; Lists
(put 'list 'end-op (function (lambda () (up-list 1))))
(put 'list 'beginning-op 'backward-sexp)
-;;--- Filenames ---
+;; Filenames
(defvar file-name-chars "~/A-Za-z0-9---_.${}#%,"
"Characters allowable in filenames.")
(put 'filename 'beginning-op
(function (lambda () (skip-chars-backward file-name-chars (point-min)))))
-;;--- Whitespace ---
+;; Whitespace
(defun forward-whitespace (ARG)
(interactive "p")
(skip-chars-backward " \t")))
(setq ARG (1+ ARG)))))
-;;--- Buffer ---
+;; Buffer
(put 'buffer 'end-op 'end-of-buffer)
(put 'buffer 'beginning-op 'beginning-of-buffer)
-;;--- Symbols ---
+;; Symbols
(defun forward-symbol (ARG)
(interactive "p")
(skip-syntax-backward "w_"))
(setq ARG (1+ ARG)))))
-;;--- Syntax blocks ---
+;; Syntax blocks
(defun forward-same-syntax (&optional arg)
(interactive "p")
(skip-syntax-forward (char-to-string (char-syntax (char-after (point)))))
(setq arg (1- arg))))
-;;=== Aliases =============================================================
+;; Aliases
(defun word-at-point () (thing-at-point 'word))
(defun sentence-at-point () (thing-at-point 'sentence))
;;; time-stamp.el --- Maintain last change time stamps in files edited by Emacs
-;;; Copyright 1989, 1993, 1994, 1995 Free Software Foundation, Inc.
-;;; Maintainer's Time-stamp: <95/12/28 19:48:49 gildea>
+;; Copyright 1989, 1993, 1994, 1995 Free Software Foundation, Inc.
+
+;; Maintainer's Time-stamp: <95/12/28 19:48:49 gildea>
;; Maintainer: Stephen Gildea <gildea@lcs.mit.edu>
;; Keywords: tools
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; If you put a time stamp template anywhere in the first 8 lines of a file,
-;;; it can be updated every time you save the file. See the top of
-;;; time-stamp.el for a sample. The template looks like one of the following:
-;;; Time-stamp: <>
-;;; Time-stamp: " "
-;;; The time stamp is written between the brackets or quotes, resulting in
-;;; Time-stamp: <95/01/18 10:20:51 gildea>
-;;; Here is an example that puts the file name and time stamp in the binary:
-;;; static char *time_stamp = "sdmain.c Time-stamp: <>";
-
-;;; To activate automatic time stamping in GNU Emacs 19, add this code
-;;; to your .emacs file:
-;;; (add-hook 'write-file-hooks 'time-stamp)
-;;;
-;;; In Emacs 18 you will need to do this instead:
-;;; (if (not (memq 'time-stamp write-file-hooks))
-;;; (setq write-file-hooks
-;;; (cons 'time-stamp write-file-hooks)))
-;;; (autoload 'time-stamp "time-stamp" "Update the time stamp in a buffer." t)
-
-;;; See the documentation for the function `time-stamp' for more details.
-
-;;; Change Log:
-
-;;; Originally based on the 19 Dec 88 version of
-;;; date.el by John Sturdy <mcvax!harlqn.co.uk!jcgs@uunet.uu.net>
-;;; version 2, January 1995: replaced functions with %-escapes
-;;; $Id: time-stamp.el,v 1.15 1995/10/31 00:01:15 kwzh Exp kwzh $
+;; If you put a time stamp template anywhere in the first 8 lines of a file,
+;; it can be updated every time you save the file. See the top of
+;; time-stamp.el for a sample. The template looks like one of the following:
+;; Time-stamp: <>
+;; Time-stamp: " "
+;; The time stamp is written between the brackets or quotes, resulting in
+;; Time-stamp: <95/01/18 10:20:51 gildea>
+;; Here is an example that puts the file name and time stamp in the binary:
+;; static char *time_stamp = "sdmain.c Time-stamp: <>";
+
+;; To activate automatic time stamping in GNU Emacs 19, add this code
+;; to your .emacs file:
+;; (add-hook 'write-file-hooks 'time-stamp)
+;;
+;; In Emacs 18 you will need to do this instead:
+;; (if (not (memq 'time-stamp write-file-hooks))
+;; (setq write-file-hooks
+;; (cons 'time-stamp write-file-hooks)))
+;; (autoload 'time-stamp "time-stamp" "Update the time stamp in a buffer." t)
+
+;; See the documentation for the function `time-stamp' for more details.
+
+;; Change Log:
+
+;; Originally based on the 19 Dec 88 version of
+;; date.el by John Sturdy <mcvax!harlqn.co.uk!jcgs@uunet.uu.net>
+;; version 2, January 1995: replaced functions with %-escapes
+;; $Id: time-stamp.el,v 1.16 1996/01/06 01:03:24 kwzh Exp erik $
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
-;;; Facilities to display current time/date and a new-mail indicator
-;;; in the Emacs mode line. The single entry point is `display-time'.
+;; Facilities to display current time/date and a new-mail indicator
+;; in the Emacs mode line. The single entry point is `display-time'.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
-;;; Commentary ============================================================
+;;; Commentary:
-;;; To use this package add
+;; To use this package add
-;;; (autoload 'tmm-menubar 'tmm "Text mode substitute for menubar" t)
-;;; (global-set-key [f10] 'tmm-menubar)
+;; (autoload 'tmm-menubar 'tmm "Text mode substitute for menubar" t)
+;; (global-set-key [f10] 'tmm-menubar)
+;; to your .emacs file. You can also add your own access to different
+;; menus available in Window System Emacs modeling definition after
+;; tmm-menubar.
-;;; to your .emacs file. You can also add your own access to different
-;;; menus available in Window System Emacs modeling definition after
-;;; tmm-menubar.
+;;; Code:
(require 'electric)
(add-hook 'calendar-load-hook (lambda () (require 'cal-menu)))
-
(provide 'tmm)
-
;;; tmm.el ends here
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; winnt.el --- Lisp routines for Windows NT.
+
;; Copyright (C) 1994 Free Software Foundation, Inc.
;; Author: Geoff Voelker (voelker@cs.washington.edu)
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; window.el --- GNU Emacs window commands aside from those written in C.
-;;; Copyright (C) 1985, 1989, 1992, 1993, 1994 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1989, 1992, 1993, 1994 Free Software Foundation, Inc.
;; Maintainer: FSF
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;;; x-apollo.el --- Apollo support functions
+
;; Copyright (C) 1995 Free Software Foundation, Inc.
-;;; This file is part of GNU Emacs.
-;;;
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
-;;;
-;;; GNU Emacs is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;;; GNU General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Emacs; see the file COPYING. If not, write to
-;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
\f
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Code:
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;;; xt-mouse.el --- Support the mouse when emacs run in an xterm.
+
;; Copyright (C) 1994 Free Software Foundation
;; Author: Per Abrahamsen <abraham@iesd.auc.dk>
;; Keywords: mouse, terminals
-;; This program is free software; you can redistribute it and/or modify
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
+
+;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
-;;
+
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, write to the Free Software
-;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Comments: