Update copyright for years from Emacs 21 to present (mainly adding
[bpt/emacs.git] / etc / NEWS.18
CommitLineData
a933dad1 1GNU Emacs NEWS -- history of user-visible changes. 17-Aug-1988
0a33da51 2Copyright (C) 1988, 2006, 2007 Free Software Foundation, Inc.
a933dad1
DL
3See the end for copying conditions.
4
9a21d88b
KS
5This file is about changes in emacs version 18.
6
7
a933dad1
DL
8\f
9Changes in version 18.52.
10
11* X windows version 10 is supported under system V.
12
13* Pop-up menus are now supported with the same Lisp interface in
14both version 10 and 11 of X windows.
15
16* C-x 4 a is a new command to edit a change-log entry in another window.
17
18* The emacs client program now allows an option +NNN to specify the
19line number to go to in the file whose name follows. Thus,
20 emacsclient foo.c +45 bar.c
21will find the files `foo.c' and `bar.c', going to line 45 in `bar.c'.
22
23* Dired allows empty directories to be deleted like files.
24
25* When the terminal type is used to find a terminal-specific file to
26run, Emacs now tries the entire terminal type first. If that doesn't
27yield a file that exists, the last hyphen and what follows it is
28stripped. If that doesn't yield a file that exists, the previous
29hyphen is stripped, and so on until all hyphens are gone. For
30example, if the terminal type is `aaa-48-foo', Emacs will try first
31`term/aaa-48-foo.el', then `term/aaa-48.el' and finally `term/aaa.el'.
32
33Underscores now receive the same treatment as hyphens.
34
35* Texinfo features: @defun, etc. texinfo-show-structure.
36New template commands. texinfo-format-region.
37
38* The special "local variable" `eval' is now ignored if you are running
39as root.
40
41* New command `c-macro-expand' shows the result of C macro expansion
42in the region. It works using the C preprocessor, so its results
43are completely accurate.
44
45* Errors in trying to auto save now flash error messages for a few seconds.
46
47* Killing a buffer now sends SIGHUP to the buffer's process.
48
49* New hooks.
50
51** `spell-region' now allows you to filter the text before spelling-checking.
52If the value of `spell-filter' is non-nil, it is called, with no arguments,
53looking at a temporary buffer containing a copy of the text to be checked.
54It can alter the text freely before the spell program sees it.
55
56** The variable `lpr-command' now specifies the command to be used when
57you use the commands to print text (such as M-x print-buffer).
58
59** Posting netnews now calls the value of `news-inews-hook' (if not nil)
60as a function of no arguments before the actual posting.
61
62** Rmail now calls the value of `rmail-show-message-hook' (if not nil)
63as a function of no arguments, each time a new message is selected.
64
65** `kill-emacs' calls the value of `kill-emacs-hook' as a function of no args.
66
67* New libraries.
68See the source code of each library for more information.
69
70** icon.el: a major mode for editing programs written in Icon.
71
72** life.el: a simulator for the cellular automaton "life". Load the
73library and run M-x life.
74
75** doctex.el: a library for converting the Emacs `etc/DOC' file of
76documentation strings into TeX input.
77
78** saveconf.el: a library which records the arrangement of windows and
79buffers when you exit Emacs, and automatically recreates the same
80setup the next time you start Emacs.
81
82** uncompress.el: a library that automatically uncompresses files
83when you visit them.
84
85** c-fill.el: a mode for editing filled comments in C.
86
87** kermit.el: an extended version of shell-mode designed for running kermit.
88
89** spook.el: a library for adding some "distract the NSA" keywords to every
90message you send.
91
92** hideif.el: a library for hiding parts of a C program based on preprocessor
93conditionals.
94
95** autoinsert.el: a library to put in some initial text when you visit
96a nonexistent file. The text used depends on the major mode, and
97comes from a directory of files created by you.
98
99* New programming features.
100
101** The variable `window-system-version' now contains the version number
102of the window system you are using (if appropriate). When using X windows,
103its value is either 10 or 11.
104
105** (interactive "N") uses the prefix argument if any; otherwise, it reads
106a number using the minibuffer.
107
108** VMS: there are two new functions `vms-system-info' and `shrink-to-icon'.
109The former allows you to get many kinds of system status information.
110See its self-documentation for full details.
111The second is used with the window system: it iconifies the Emacs window.
112
113** VMS: the new function `define-logical-name' allows you to create
114job-wide logical names. The old function `define-dcl-symbol' has been
115removed.
9a21d88b
KS
116
117
a933dad1
DL
118\f
119Changes in version 18.50.
120
121* X windows version 11 is supported.
122
123Define X11 in config.h if you want X version 11 instead of version 10.
124
125* The command M-x gdb runs the GDB debugger as an inferior.
126It asks for the filename of the executable you want to debug.
127
128GDB runs as an inferior with I/O through an Emacs buffer. All the
129facilities of Shell mode are available. In addition, each time your
130program stops, and each time you select a new stack frame, the source
131code is displayed in another window with an arrow added to the line
132where the program is executing.
133
134Special GDB-mode commands include M-s, M-n, M-i, M-u, M-d, and C-c C-f
135which send the GDB commands `step', `next', `stepi', `up', `down'
136and `finish'.
137
138In any source file, the commands C-x SPC tells GDB to set a breakpoint
139on the current line.
140
141* M-x calendar displays a three-month calendar.
142
143* C-u 0 C-x C-s never makes a backup file.
144
145This is a way you can explicitly request not to make a backup.
146
147* `term-setup-hook' is for users only.
148
149Emacs never uses this variable for internal purposes, so you can freely
150set it in your `.emacs' file to make Emacs do something special after
151loading any terminal-specific setup file from `lisp/term'.
152
153* `copy-keymap' now copies recursive submaps.
154
155* New overlay-arrow feature.
156
157If you set the variable `overlay-arrow-string' to a string
158and `overlay-arrow-position' to a marker, that string is displayed on
159the screen at the position of that marker, hiding whatever text would
160have appeared there. If that position isn't on the screen, or if
161the buffer the marker points into isn't displayed, there is no effect.
162
163* -batch mode can read from the terminal.
164
165It now works to use `read-char' to do terminal input in a noninteractive
166Emacs run. End of file causes Emacs to exit.
167
168* Variables `data-bytes-used' and `data-bytes-free' removed.
169
170These variables cannot really work because the 24-bit range of an
171integer in (most ports of) GNU Emacs is not large enough to hold their
172values on many systems.
9a21d88b
KS
173
174
a933dad1
DL
175\f
176Changes in version 18.45, since version 18.41.
177
178* C indentation parameter `c-continued-brace-offset'.
179
180This parameter's value is added to the indentation of any
181line that is in a continuation context and starts with an open-brace.
182For example, it applies to the open brace shown here:
183
184 if (x)
185 {
186
187The default value is zero.
188
189* Dabbrev expansion (Meta-/) preserves case.
190
191When you use Meta-/ to search the buffer for an expansion of an
192abbreviation, if the expansion found is all lower case except perhaps
193for its first letter, then the case pattern of the abbreviation
194is carried over to the expansion that replaces it.
195
196* TeX-mode syntax.
197
198\ is no longer given "escape character" syntax in TeX mode. It now
199has the syntax of an ordinary punctuation character. As a result,
200\[...\] and such like are considered to balance each other.
201
202* Mail-mode automatic Reply-to field.
203
204If the variable `mail-default-reply-to' is non-`nil', then each time
205you start to compose a message, a Reply-to field is inserted with
206its contents taken from the value of `mail-default-reply-to'.
207
208* Where is your .emacs file?
209
210If you run Emacs under `su', so your real and effective uids are
211different, Emacs uses the home directory associated with the real uid
212(the name you actually logged in under) to find the .emacs file.
213
214Otherwise, Emacs uses the environment variable HOME to find the .emacs
215file.
216
217The .emacs file is not loaded at all if -batch is specified.
218
219* Prolog mode is the default for ".pl" files.
220
221* File names are not case-sensitive on VMS.
222
223On VMS systems, all file names that you specify are converted to upper
224case. You can use either upper or lower case indiscriminately.
225
226* VMS-only function 'define-dcl-symbol'.
227
228This is a new name for the function formerly called
229`define-logical-name'.
9a21d88b
KS
230
231
a933dad1
DL
232\f
233Editing Changes in Emacs 18
234
235* Additional systems and machines are supported.
236
237GNU Emacs now runs on Vax VMS. However, many facilities that are normally
238implemented by running subprocesses do not work yet. This includes listing
239a directory and sending mail. There are features for running subprocesses
240but they are incompatible with those on Unix. I hope that some of
241the VMS users can reimplement these features for VMS (compatibly for
242the user, if possible).
243
244VMS wizards are also asked to work on making the subprocess facilities
245more upward compatible with those on Unix, and also to rewrite their
246internals to use the same Lisp objects that are used on Unix to
247represent processes.
248
249In addition, the TI Nu machine running Unix system V, the AT&T 3b, and
250the Wicat, Masscomp, Integrated Solutions, Alliant, Amdahl uts, Mips,
251Altos 3068 and Gould Unix systems are now supported. The IBM PC-RT is
252supported under 4.2, but not yet under system V. The GEC 93 is close
253to working. The port for the Elxsi is partly merged. See the file
254MACHINES for full status information and machine-specific installation
255advice.
256
257* Searching is faster.
258
259Forward search for a text string, or for a regexp that is equivalent
260to a text string, is now several times faster. Motion by lines and
261counting lines is also faster.
262
263* Memory usage improvements.
264
265It is no longer possible to run out of memory during garbage
266collection. As a result, running out of memory is never fatal. This
267is due to a new garbage collection algorithm which compactifies
268strings in place rather than copying them. Another consequence of the
269change is a reduction in total memory usage and a slight increase in
270garbage collection speed.
271
272* Display changes.
273
274** Editing above top of screen.
275
276When you delete or kill or alter text that reaches to the top of the
277screen or above it, so that display would start in the middle of a
278line, Emacs will usually attempt to scroll the text so that display
279starts at the beginning of a line again.
280
281** Yanking in the minibuffer.
282
283The message "Mark Set" is no longer printed when the minibuffer is
284active. This is convenient with many commands, including C-y, that
285normally print such a message.
286
287** Cursor appears in last line during y-or-n questions.
288
289Questions that want a `y' or `n' answer now move the cursor
290to the last line, following the question.
291
292* Library loading changes.
293
294`load' now considers all possible suffixes (`.elc', `.el' and none)
295for each directory in `load-path' before going on to the next directory.
296It now accepts an optional fourth argument which, if non-nil, says to
297use no suffixes; then the file name must be given in full. The search
298of the directories in `load-path' goes on as usual in this case, but
299it too can be prevented by passing an absolute file name.
300
301The value of `load-path' no longer by default includes nil (meaning to
302look in the current default directory). The idea is that `load' should
303be used to search the path only for libraries to be found in the standard
304places. If you want to override system libraries with your own, place
305your own libraries in one special directory and add that directory to the
306front of `load-path'.
307
308The function `load' is no longer a command; that is to say, `M-x load'
309is no longer allowed. Instead, there are two commands for loading files.
310`M-x load-library' is equivalent to the old meaning of `M-x load'.
311`M-x load-file' reads a file name with completion and defaulting
312and then loads exactly that file, with no searching and no suffixes.
313
314* Emulation of other editors.
315
316** `edt-emulation-on' starts emulating DEC's EDT editor.
317
318Do `edt-emulation-off' to return Emacs to normal.
319
320** `vi-mode' and `vip-mode' starts emulating vi.
321
322These are two different vi emulations provided by GNU Emacs users.
323We are interested in feedback as to which emulation is preferable.
324
325See the documentation and source code for these functions
326for more information.
327
328** `set-gosmacs-bindings' emulates Gosling Emacs.
329
330This command changes many global bindings to resemble those of
331Gosling Emacs. The previous bindings are saved and can be restored using
332`set-gnu-bindings'.
333
334* Emulation of a display terminal.
335
336Within Emacs it is now possible to run programs (such as emacs or
337supdup) which expect to do output to a visual display terminal.
338
339See the function `terminal-emulator' for more information.
340
341* New support for keypads and function keys.
342
343There is now a first attempt at terminal-independent support for
344keypad and function keys.
345
346Emacs now defines a standard set of key-names for function and keypad
347keys, and provides standard hooks for defining them. Most of the
348standard key-names have default definitions built into Emacs; you can
349override these in a terminal-independent manner. The default definitions
350and the conventions for redefining them are in the file `lisp/keypad.el'.
351
352These keys on the terminal normally work by sending sequences of
353characters starting with ESC. The exact sequences used vary from
354terminal to terminal. Emacs interprets them in two stages:
355in the first stage, terminal-dependent sequences are mapped into
356the standard key-names; then second stage maps the standard key-names
357into their definitions in a terminal-independent fashion.
358
359The terminal-specific file `term/$TERM.el' now is responsible only for
360establishing the mapping from the terminal's escape sequences into
361standard key-names. It no longer knows what Emacs commands are
362assigned to the standard key-names.
363
364One other change in terminal-specific files: if the value of the TERM
365variable contains a hyphen, only the part before the first hyphen is
366used in forming the name of the terminal-specific file. Thus, for
367terminal type `aaa-48', the file loaded is now `term/aaa.el' rather
368than `term/aaa-48.el'.
369
370* New startup command line options.
371
372`-i FILE' or `-insert FILE' in the command line to Emacs tells Emacs to
373insert the contents of FILE into the current buffer at that point in
374command line processing. This is like using the command M-x insert-file.
375
376`-funcall', `-load', `-user' and `-no-init-file' are new synonyms for
377`-f', `-l', `-u' and `-q'.
378
379`-nw' means don't use a window system. If you are using a terminal
380emulator on the X window system and you want to run Emacs to work through
381the terminal emulator instead of working directly with the window system,
382use this switch.
383
384* Buffer-sorting commands.
385
386Various M-x commands whose names start with `sort-' sort parts of
387the region:
388
389sort-lines divides the region into lines and sorts them alphabetically.
390sort-pages divides into pages and sorts them alphabetically.
391sort-paragraphs divides into paragraphs and sorts them alphabetically.
392sort-fields divides into lines and sorts them alphabetically
393 according to one field in the line.
394 The numeric argument specifies which field (counting
395 from field 1 at the beginning of the line). Fields in a line
396 are separated by whitespace.
397sort-numeric-fields
398 is similar but converts the specified fields to numbers
399 and sorts them numerically.
400sort-columns divides into lines and sorts them according to the contents
401 of a specified range of columns.
402
403Refer to the self-documentation of these commands for full usage information.
404
405* Changes in various commands.
406
407** `tags-query-replace' and `tags-search' change.
408
409These functions now display the name of the file being searched at the moment.
410
411** `occur' output now serves as a menu. `occur-menu' command deleted.
412
413`M-x occur' now allows you to move quickly to any of the occurrences
414listed. Select the `*Occur*' buffer that contains the output of `occur',
415move point to the occurrence you want, and type C-c C-c.
416This will move point to the same occurrence in the buffer that the
417occurrences were found in.
418
419The command `occur-menu' is thus obsolete, and has been deleted.
420
421One way to get a list of matching lines without line numbers is to
422copy the text to another buffer and use the command `keep-lines'.
423
424** Incremental search changes.
425
426Ordinary and regexp incremental searches now have distinct default
427search strings. Thus, regexp searches recall only previous regexp
428searches.
429
430If you exit an incremental search when the search string is empty,
431the old default search string is kept. The default does not become
432empty.
433
434Reversing the direction of an incremental search with C-s or C-r
435when the search string is empty now does not get the default search
436string. It leaves the search string empty. A second C-s or C-r
437will get the default search string. As a result, you can do a reverse
438incremental regexp search with C-M-s C-r.
439
440If you add a `*', `?' or `\|' to an incremental search regexp,
441point will back up if that is appropriate. For example, if
442you have searched for `ab' and add a `*', point moves to the
443first match for `ab*', which may be before the match for `ab'
444that was previously found.
445
446If an incremental search is failing and you ask to repeat it,
447it will start again from the beginning of the buffer (or the end,
448if it is a backward search).
449
450The search-controlling parameters `isearch-slow-speed' and
451`isearch-slow-window-lines' have now been renamed to start with
452`search' instead of `isearch'. Now all the parameters' names start
453with `search'.
454
455If `search-slow-window-lines' is negative, the slow search window
456is put at the top of the screen, and the absolute value or the
457negative number specifies the height of it.
458
459** Undo changes
460
461The undo command now will mark the buffer as unmodified only when it is
462identical to the contents of the visited file.
463
464** C-M-v in minibuffer.
465
466If while in the minibuffer you request help in a way that uses a
467window to display something, then until you exit the minibuffer C-M-v
468in the minibuffer window scrolls the window of help.
469
470For example, if you request a list of possible completions, C-M-v can
471be used reliably to scroll the completion list.
472
473** M-TAB command.
474
475Meta-TAB performs completion on the Emacs Lisp symbol names. The sexp
476in the buffer before point is compared against all existing nontrivial
477Lisp symbols and completed as far as is uniquely determined by them.
478Nontrivial symbols are those with either function definitions, values
479or properties.
480
481If there are multiple possibilities for the very next character, a
482list of possible completions is displayed.
483
484** Dynamic abbreviation package.
485
486The new command Meta-/ expands an abbreviation in the buffer before point
487by searching the buffer for words that start with the abbreviation.
488
489** Changes in saving kbd macros.
490
491The commands `write-kbd-macro' and `append-kbd-macro' have been
492deleted. The way to save a keyboard macro is to use the new command
493`insert-kbd-macro', which inserts Lisp code to define the macro as
494it is currently defined into the buffer before point. Visit a Lisp
495file such as your Emacs init file `~/.emacs', insert the macro
496definition (perhaps deleting an old definition for the same macro)
497and then save the file.
498
499** C-x ' command.
500
501The new command C-x ' (expand-abbrev) expands the word before point as
502an abbrev, even if abbrev-mode is not turned on.
503
504** Sending to inferior Lisp.
505
506The command C-M-x in Lisp mode, which sends the current defun to
507an inferior Lisp process, now works by writing the text into a temporary
508file and actually sending only a `load'-form to load the file.
509As a result, it avoids the Unix bugs that used to strike when the
510text was above a certain length.
511
512With a prefix argument, this command now makes the inferior Lisp buffer
513appear on the screen and scrolls it so that the bottom is showing.
514
515Two variables `inferior-lisp-load-command' and `inferior-lisp-prompt',
516exist to customize these feature for different Lisp implementations.
517
518** C-x p now disabled.
519
520The command C-x p, a nonrecomended command which narrows to the current
521page, is now initially disabled like C-x n.
522
523* Dealing with files.
524
525** C-x C-v generalized
526
527This command is now allowed even if the current buffer is not visiting
528a file. As usual, it kills the current buffer and replaces it with a
529newly found file.
530
531** M-x recover-file improved; auto save file names changed.
532
533M-x recover-file now checks whether the last auto-save file is more
534recent than the real visited file before offering to read in the
535auto-save file. If the auto-save file is newer, a directory listing
536containing the two files is displayed while you are asked whether you
537want the auto save file.
538
539Visiting a file also makes this check. If the auto-save file is more recent,
540a message is printed suggesting that you consider using M-x recover file.
541
542Auto save file names now by default have a `#' at the end as well
543as at the beginning. This is so that `*.c' in a shell command
544will never match auto save files.
545
546On VMS, auto save file names are made by appending `_$' at the front
547and `$' at the end.
548
549When you change the visited file name of a buffer, the auto save file
550is now renamed to belong to the new visited file name.
551
552You can customize the way auto save file names are made by redefining
553the two functions `make-auto-save-file-name' and `auto-save-file-name-p',
554both of which are defined in `files.el'.
555
556** Modifying a buffer whose file is changed on disk is detected instantly.
557
558On systems where clash detection (locking of files being edited) is
559implemented, Emacs also checks the first time you modify a buffer
560whether the file has changed on disk since it was last visited or saved.
561If it has, you are asked to confirm that you want to change the buffer.
562
563** Exiting Emacs offers to save `*mail*'.
564
565Emacs can now know about buffers that it should offer to save on exit
566even though they are not visiting files. This is done for any buffer
567which has a non-nil local value of `buffer-offer-save'. By default,
568Mail mode provides such a local value.
569
570** Backup file changes.
571
572If a backup file cannot be written in the directory of the visited file
573due to fascist file protection, a backup file is now written in your home
574directory as `~/%backup%~'. Only one such file is made, ever, so only
575the most recently made such backup is available.
576
577When backup files are made by copying, the last-modification time of the
578original file is now preserved in the backup copy.
579
580** Visiting remote files.
581
582On an internet host, you can now visit and save files on any other
583internet host directly from Emacs with the commands M-x ftp-find-file
584and M-x ftp-write-file. Specify an argument of the form HOST:FILENAME.
585Since standard internet FTP is used, the other host may be any kind
586of machine and is not required to have any special facilities.
587
588The first time any one remote host is accessed, you will be asked to
589give the user name and password for use on that host. FTP is reinvoked
590each time you ask to use it, but previously specified user names and
591passwords are remembered automatically.
592
593** Dired `g' command.
594
595`g' in Dired mode is equivalent to M-x revert-buffer; it causes the
596current contents of the same directory to be read in.
597
598* Changes in major modes.
599
600** C mode indentation change.
601
602The binding of Linefeed is no longer changed by C mode. It once again
603has its normal meaning, which is to insert a newline and then indent
604afterward.
605
606The old definition did one additional thing: it reindented the line
607before the new newline. This has been removed because it made the
608command twice as slow. The only time it was really useful was after the
609insertion of an `else', since the fact of starting with `else' may change
610the way that line is indented. Now you will have to type TAB again
611yourself to reindent the `else' properly.
612
613If the variable `c-tab-always-indent' is set to `nil', the TAB command
614in C mode, with no argument, will just insert a tab character if there
615is non-whitespace preceding point on the current line. Giving it a
616prefix argument will force reindentation of the line (as well as
617of the compound statement that begins after point, if any).
618
619** Fortran mode now exists.
620
621This mode provides commands for motion and indentation of Fortran code,
622plus built-in abbrevs for Fortran keywords. For details, see the manual
623or the on-line documentation of the command `fortran-mode'.
624
625** Scribe mode now exists.
626
627This mode does something useful for editing files of Scribe input.
628It is used automatically for files with names ending in ".mss".
629
630** Modula2 and Prolog modes now exist.
631
632These modes are for editing programs in the languages of the same names.
633They can be selected with M-x modula-2-mode and M-x prolog-mode.
634
635** Telnet mode changes.
636
637The telnet mode special commands have now been assigned to C-c keys.
638Most of them are the same as in Shell mode.
639
640** Picture mode changes.
641
642The special picture-mode commands to specify the direction of cursor
643motion after insertion have been moved to C-c keys. The commands to
644specify diagonal motion were already C-c keys; they are unchanged.
645The keys to specify horizontal or vertical motion are now
646C-c < (left), C-c > (right), C-c ^ (up) and C-c . (down).
647
648** Nroff mode comments.
649
650Comments are now supported in Nroff mode. The standard comment commands
651such as M-; and C-x ; know how to insert, align and delete comments
652that start with backslash-doublequote.
653
654** LaTeX mode.
655
656LaTeX mode now exists. Use M-x latex-mode to select this mode, and
657M-x plain-tex-mode to select the previously existing mode for Plain
658TeX. M-x tex-mode attempts to examine the contents of the buffer and
659choose between latex-mode and plain-tex-mode accordingly; if the
660buffer is empty or it cannot tell, the variable `TeX-default-mode'
661controls the choice. Its value should be the symbol for the mode to
662be used.
663
664The facilities for running TeX on all or part of the buffer
665work with LaTeX as well.
666
667Some new commands available in both modes:
668
669C-c C-l recenter the window showing the TeX output buffer
670 so most recent line of output can be seen.
671C-c C-k kill the TeX subprocess.
672C-c C-q show the printer queue.
673C-c C-f close a block (appropriate for LaTeX only).
674 If the current line contains a \begin{...},
675 this inserts an \end{...} on the following line
676 and puts point on a blank line between them.
677
678** Outline mode changes.
679
680Invisible lines in outline mode are now indicated by `...' at the
681end of the previous visible line.
682
683The special outline heading motion commands are now all on C-c keys.
684A few new ones have been added. Here is a full list:
685
686C-c C-n Move to next visible heading (formerly M-})
687C-c C-p Move to previous visible heading (formerly M-{)
688C-c C-f Move to next visible heading at the same level.
689 Thus, if point is on a level-2 heading line,
690 this command moves to the next visible level-2 heading.
691C-c C-b Move to previous visible heading at the same level.
692C-c C-u Move up to previous visible heading at a higher level.
693
694The variable `outline-regexp' now controls recognition of heading lines.
695Any line whose beginning matches this regexp is a heading line.
696The depth in outline structure is determined by the length of
697the string that matches.
698
699A line starting with a ^L (formfeed) is now by default considered
700a header line.
701
702* Mail reading and sending.
703
704** MH-E changes.
705
706MH-E has been extensively modified and improved since the v17 release.
707It contains many new features, including commands to: extracted failed
708messages, kill a draft message, undo changes to a mail folder, monitor
709delivery of a letter, print multiple messages, page digests backwards,
710insert signatures, and burst digests. Also, many commands have been
711made to able to deal with named sequences of messages, instead of
712single messages. MH-E also has had numerous bugs fixed and commands
713made to run faster. Furthermore, its keybindings have been changed to
714be compatible with Rmail and the rest of GNU Emacs.
715
716** Mail mode changes.
717
718The C-c commands of mail mode have been rearranged:
719
720C-c s, C-c c, C-c t and C-c b (move point to various header fields)
721have been reassigned as C-c C-f C-s, C-c C-f C-c, C-c C-f C-t and C-c
722C-f C-b. C-c C-f is for "field".
723
724C-c y, C-c w and C-c q have been changed to C-c C-y, C-c C-w and C-c C-q.
725
726Thus, C-c LETTER is always unassigned.
727
728** Rmail C-r command changed to w.
729
730The Rmail command to edit the current message is now `w'. This change
731has been made because people frequently type C-r while in Rmail hoping
732to do a reverse incremental search. That now works.
733
734* Rnews changes.
735
736** Caesar rotation added.
737
738The function news-caesar-buffer-body performs encryption and
739decryption of the body of a news message. It defaults to the USENET
740standard of 13, and accepts any numeric arg between 1 to 25 and -25 to -1.
741The function is bound to C-c C-r in both news-mode and news-reply-mode.
742
743** rmail-output command added.
744
745The C-o command has been bound to rmail-output in news-mode.
746This allows one to append an article to a file which is in either Unix
747mail or RMAIL format.
748
749** news-reply-mode changes.
750
751The C-c commands of news reply mode have been rearranged and changed,
752so that C-c LETTER is always unassigned:
753
754C-c y, C-c w and C-c q have been changed to C-c C-y, C-c C-w and C-c C-q.
755
756C-c c, C-c t, and C-c b (move to various mail header fields) have been
757deleted (they make no sense for posting and replying to USENET).
758
759C-c s (move to Subject: header field) has been reassigned as C-c C-f
760C-s. C-c C-f is for "field". Several additional move to news header
761field commands have been added.
762
763The local news-reply-mode bindings now look like this:
764
765C-c C-s news-inews (post the message) C-c C-c news-inews
766C-c C-f move to a header field (and create it if there isn't):
767 C-c C-f C-n move to Newsgroups: C-c C-f C-s move to Subj:
768 C-c C-f C-f move to Followup-To: C-c C-f C-k move to Keywords:
769 C-c C-f C-d move to Distribution: C-c C-f C-a move to Summary:
770C-c C-y news-reply-yank-original (insert current message, in NEWS).
771C-c C-q mail-fill-yanked-message (fill what was yanked).
772C-c C-r caesar rotate all letters by 13 places in the article's body (rot13).
773
774* Existing Emacs usable as a server.
775
776Programs such as mailers that invoke "the editor" as an inferior
777to edit some text can now be told to use an existing Emacs process
778instead of creating a new editor.
779
780To do this, you must have an Emacs process running and capable of
781doing terminal I/O at the time you want to invoke it. This means that
782either you are using a window system and give Emacs a separate window
783or you run the other programs as inferiors of Emacs (such as, using
784M-x shell).
785
786First prepare the existing Emacs process by loading the `server'
787library and executing M-x server-start. (Your .emacs can do this
788automatically.)
789
790Now tell the other programs to use, as "the editor", the Emacs client
791program (etc/emacsclient, located in the same directory as this file).
792This can be done by setting the environment variable EDITOR.
793
794When another program invokes the emacsclient as "the editor", the
795client actually transfers the file names to be edited to the existing
796Emacs, which automatically visits the files.
797
798When you are done editing a buffer for a client, do C-x # (server-edit).
799This marks that buffer as done, and selects the next buffer that the client
800asked for. When all the buffers requested by a client are marked in this
801way, Emacs tells the client program to exit, so that the program that
802invoked "the editor" will resume execution.
803
804You can only have one server Emacs at a time, but multiple client programs
805can put in requests at the same time.
806
807The client/server work only on Berkeley Unix, since they use the Berkeley
808sockets mechanism for their communication.
9a21d88b 809
a933dad1
DL
810\f
811Changes in Lisp programming in Emacs version 18.
812
813* Init file changes.
814
815** Suffixes no longer accepted on `.emacs'.
816
817Emacs will no longer load a file named `.emacs.el' or `emacs.elc'
818in place of `.emacs'. This is so that it will take less time to
819find `.emacs'. If you want to compile your init file, give it another
820name and make `.emacs' a link to the `.elc' file, or make it contain
821a call to `load' to load the `.elc' file.
822
823** `default-profile' renamed to `default', and loaded after `.emacs'.
824
825It used to be the case that the file `default-profile' was loaded if
826and only if `.emacs' was not found.
827
828Now the name `default-profile' is not used at all. Instead, a library
829named `default' is loaded after the `.emacs' file. `default' is loaded
830whether the `.emacs' file exists or not. However, loading of `default'
831can be prevented if the `.emacs' file sets `inhibit-default-init' to non-nil.
832
833In fact, you would call the default file `default.el' and probably would
834byte-compile it to speed execution.
835
836Note that for most purposes you are better off using a `site-init' library
837since that will be loaded before the runnable Emacs is dumped. By using
838a `site-init' library, you avoid taking up time each time Emacs is started.
839
840** inhibit-command-line has been eliminated.
841
842This variable used to exist for .emacs files to set. It has been
843eliminated because you can get the same effect by setting
844command-line-args to nil and setting inhibit-startup-message to t.
845
846* `apply' is more general.
847
848`apply' now accepts any number of arguments. The first one is a function;
849the rest are individual arguments to pass to that function, except for the
850last, which is a list of arguments to pass.
851
852Previously, `apply' required exactly two arguments. Its old behavior
853follows as a special case of the new definition.
854
855* New code-letter for `interactive'.
856
857(interactive "NFoo: ") is like (interactive "nFoo: ") in reading
858a number using the minibuffer to serve as the argument; however,
859if a prefix argument was specified, it uses the prefix argument
860value as the argument, and does not use the minibuffer at all.
861
862This is used by the `goto-line' and `goto-char' commands.
863
864* Semantics of variables.
865
866** Built-in per-buffer variables improved.
867
868Several built-in variables which in the past had a different value in
869each buffer now behave exactly as if `make-variable-buffer-local' had
870been done to them.
871
872These variables are `tab-width', `ctl-arrow', `truncate-lines',
873`fill-column', `left-margin', `mode-line-format', `abbrev-mode',
874`overwrite-mode', `case-fold-search', `auto-fill-hook',
875`selective-display', `selective-display-ellipses'.
876
877To be precise, each variable has a default value which shows through
878in most buffers and can be accessed with `default-value' and set with
879`set-default'. Setting the variable with `setq' makes the variable
880local to the current buffer. Changing the default value has retroactive
881effect on all buffers in which the variable is not local.
882
883The variables `default-case-fold-search', etc., are now obsolete.
884They now refer to the default value of the variable, which is not
885quite the same behavior as before, but it should enable old init files
886to continue to work.
887
888** New per-buffer variables.
889
890The variables `fill-prefix', `comment-column' and `indent-tabs-mode'
891are now per-buffer. They work just like `fill-column', etc.
892
893** New function `setq-default'.
894
895`setq-default' sets the default value of a variable, and uses the
896same syntax that `setq' accepts: the variable name is not evaluated
897and need not be quoted.
898
899`(setq-default case-fold-search nil)' would make searches case-sensitive
900in all buffers that do not have local values for `case-fold-search'.
901
902** Functions `global-set' and `global-value' deleted.
903
904These functions were never used except by mistake by users expecting
905the functionality of `set-default' and `default-value'.
906
907* Changes in defaulting of major modes.
908
909When `default-major-mode' is `nil', new buffers are supposed to
910get their major mode from the buffer that is current. However,
911certain major modes (such as Dired mode, Rmail mode, Rmail Summary mode,
912and others) are not reasonable to use in this way.
913
914Now such modes' names have been given non-`nil' `mode-class' properties.
915If the current buffer's mode has such a property, Fundamental mode is
916used as the default for newly created buffers.
917
918* `where-is-internal' requires additional arguments.
919
920This function now accepts three arguments, two of them required:
921DEFINITION, the definition to search for; LOCAL-KEYMAP, the keymap
922to use as the local map when doing the searching, and FIRST-ONLY,
923which is nonzero to return only the first key found.
924
925This function returns a list of keys (strings) whose definitions
926(in the LOCAL-KEYMAP or the current global map) are DEFINITION.
927
928If FIRST-ONLY is non-nil, it returns a single key (string).
929
930This function has changed incompatibly in that now two arguments
931are required when previously only one argument was allowed. To get
932the old behavior of this function, write `(current-local-map)' as
933the expression for the second argument.
934
935The incompatibility is sad, but `nil' is a legitimate value for the
936second argument (it means there is no local keymap), so it cannot also
937serve as a default meaning to use the current local keymap.
938
939* Abbrevs with hooks.
940
941When an abbrev defined with a hook is expanded, it now performs the
942usual replacement of the abbrev with the expansion before running the
943hook. Previously the abbrev itself was deleted but the expansion was
944not inserted.
945
946* Function `scan-buffer' deleted.
947
948Use `search-forward' or `search-backward' in place of `scan-buffer'.
949You will have to rearrange the arguments.
950
951* X window interface improvements.
952
953** Detect release of mouse buttons.
954
955Button-up events can now be detected. See the file `lisp/x-mouse.el'
956for details.
957
958** New pop-up menu facility.
959
960The new function `x-popup-menu' pops up a menu (in a X window)
961and returns an indication of which selection the user made.
962For more information, see its self-documentation.
963
964* M-x disassemble.
965
966This command prints the disassembly of a byte-compiled Emacs Lisp function.
967
968Would anyone like to interface this to the debugger?
969
970* `insert-buffer-substring' can insert part of the current buffer.
971
972The old restriction that the text being inserted had to come from
973a different buffer is now lifted.
974
975When inserting text from the current buffer, the text to be inserted
976is determined from the specified bounds before any copying takes place.
977
978* New function `substitute-key-definition'.
979
980This is a new way to replace one command with another command as the
981binding of whatever keys may happen to refer to it.
982
983(substitute-key-definition OLDDEF NEWDEF KEYMAP) looks through KEYMAP
984for keys defined to run OLDDEF, and rebinds those keys to run NEWDEF
985instead.
986
987* New function `insert-char'.
988
989Insert a specified character, a specified number of times.
990
991* `mark-marker' changed.
992
993When there is no mark, this now returns a marker that points
994nowhere, rather than `nil'.
995
996* `ding' accepts argument.
997
998When given an argument, the function `ding' does not terminate
999execution of a keyboard macro. Normally, `ding' does terminate
1000all macros that are currently executing.
1001
1002* New function `minibuffer-depth'.
1003
1004This function returns the current depth in minibuffer activations.
1005The value is zero when the minibuffer is not in use.
1006Values greater than one are possible if the user has entered the
1007minibuffer recursively.
1008
1009* New function `documentation-property'.
1010
1011(documentation-property SYMBOL PROPNAME) is like (get SYMBOL PROPNAME),
1012except that if the property value is a number `documentation-property'
1013will take that number (or its absolute value) as a character position
1014in the DOC file and return the string found there.
1015
1016(documentation-property VAR 'variable-documentation) is the proper
1017way for a Lisp program to get the documentation of variable VAR.
1018
1019* New documentation-string expansion feature.
1020
1021If a documentation string (for a variable or function) contains text
1022of the form `\<FOO>', it means that all command names specified in
1023`\[COMMAND]' construct from that point on should be turned into keys
1024using the value of the variable FOO as the local keymap. Thus, for example,
1025
1026 `\<emacs-lisp-mode-map>\[eval-defun] evaluates the defun containing point.'
1027
1028will expand into
1029
1030 "ESC C-x evaluates the defun containing point."
1031
1032regardless of the current major mode, because ESC C-x is defined to
1033run `eval-defun' in the keymap `emacs-lisp-mode-map'. The effect is
1034to show the key for `eval-defun' in Emacs Lisp mode regardless of the
1035current major mode.
1036
1037The `\<...>' construct applies to all `\[...]' constructs that follow it,
1038up to the end of the documentation string or the next `\<...>'.
1039
1040Without `\<...>', the keys for commands specified in `\[...]' are found
1041in the current buffer's local map.
1042
1043The current global keymap is always searched second, whether `\<...>'
1044has been used or not.
1045
1046* Multiple hooks allowed in certain contexts.
1047
1048The old hook variables `find-file-hook', `find-file-not-found-hook' and
1049`write-file-hook' have been replaced.
1050
1051The replacements are `find-file-hooks', `find-file-not-found-hooks'
1052and `write-file-hooks'. Each holds a list of functions to be called;
1053by default, `nil', for no functions. The functions are called in
1054order of appearance in the list.
1055
1056In the case of `find-file-hooks', all the functions are executed.
1057
1058In the case of `find-file-not-found-hooks', if any of the functions
1059returns non-`nil', the rest of the functions are not called.
1060
1061In the case of `write-file-hooks', if any of the functions returns
1062non-`nil', the rest of the functions are not called, and the file is
1063considered to have been written already; so actual writing in the
1064usual way is not done. If `write-file-hooks' is local to a buffer,
1065it is set to its global value if `set-visited-file-name' is called
1066(and thus by C-x C-w as well).
1067
1068`find-file-not-found-hooks' and `write-file-hooks' can be used
1069together to implement editing of files that are not stored as Unix
1070files: stored in archives, or inside version control systems, or on
1071other machines running other operating systems and accessible via ftp.
1072
1073* New hooks for suspending Emacs.
1074
1075Suspending Emacs runs the hook `suspend-hook' before suspending
1076and the hook `suspend-resume-hook' if the suspended Emacs is resumed.
1077Running a hook is done by applying the variable's value to no arguments
1078if the variable has a non-`nil' value. If `suspend-hook' returns
1079non-`nil', then suspending is inhibited and so is running the
1080`suspend-resume-hook'. The non-`nil' value means that the `suspend-hook'
1081has done whatever suspending is required.
1082
1083* Disabling commands can print a special message.
1084
1085A command is disabled by giving it a non-`nil' `disabled' property.
1086Now, if this property is a string, it is included in the message
1087printed when the user tries to run the command.
1088
1089* Emacs can open TCP connections.
1090
1091The function `open-network-stream' opens a TCP connection to
1092a specified host and service. Its value is a Lisp object that represents
1093the connection. The object is a kind of "subprocess", and I/O are
1094done like I/O to subprocesses.
1095
1096* Display-related changes.
1097
1098** New mode-line control features.
1099
1100The display of the mode line used to be controlled by a format-string
1101that was the value of the variable `mode-line-format'.
1102
1103This variable still exists, but it now allows more general values,
1104not just strings. Lists, cons cells and symbols are also meaningful.
1105
1106The mode line contents are created by outputting various mode elements
1107one after the other. Here are the kinds of objects that can be
1108used as mode elements, and what they do in the display:
1109
1110 string the contents of the string are output to the mode line,
1111 and %-constructs are replaced by other text.
1112
1113 t or nil ignored; no output results.
1114
1115 symbol the symbol's value is used. If the value is a string,
1116 the string is output verbatim to the mode line
1117 (so %-constructs are not interpreted). Otherwise,
1118 the symbol's value is processed as a mode element.
1119
1120 list (whose first element is a string or list or cons cell)
1121 the elements of the list are treated as as mode elements,
1122 so that the output they generate is concatenated,
1123
1124 list (whose car is a symbol)
1125 if the symbol's value is non-nil, the second element of the
1126 list is treated as a mode element. Otherwise, the third
1127 element (if any) of the list is treated as a mode element.
1128
1129 cons (whose car is a positive integer)
1130 the cdr of the cons is used as a mode element, but
1131 the text it produces is padded, if necessary, to have
1132 at least the width specified by the integer.
1133
1134 cons (whose car is a negative integer)
1135 the cdr of the cons is used as a mode element, but
1136 the text it produces is truncated, if necessary, to have
1137 at most the width specified by the integer.
1138
1139There is always one mode element to start with, that being the value of
1140`mode-line-format', but if this value is a list then it leads to several
1141more mode elements, which can lead to more, and so on.
1142
1143There is one new %-construct for mode elements that are strings:
1144`%n' displays ` Narrow' for a buffer that is narrowed.
1145
1146The default value of `mode-line-format' refers to several other variables.
1147These variables are `mode-name', `mode-line-buffer-identification',
1148`mode-line-process', `mode-line-modified', `global-mode-string' and
1149`minor-mode-alist'. The first four are local in every buffer in which they
1150are changed from the default.
1151
1152mode-name Name of buffer's major mode. Local in every buffer.
1153
1154mode-line-buffer-identification
1155 Normally the list ("Emacs: %17b"), it is responsible
1156 for displaying text to indicate what buffer is being shown
1157 and what kind of editing it is doing. `Emacs' means
1158 that a file of characters is being edited. Major modes
1159 such as Info and Dired which edit or view other kinds
1160 of data often change this value. This variables becomes
1161 local to the current buffer if it is setq'd.
1162
1163mode-line-process
1164 Normally nil, this variable is responsible for displaying
1165 information about the process running in the current buffer.
1166 M-x shell-mode and M-x compile alter this variable.
1167
1168mode-line-modified
1169 This variable is responsible for displaying the indication
1170 of whether the current buffer is modified or read-only.
1171 By default its value is `("--%*%*-")'.
1172
1173minor-mode-alist
1174 This variable is responsible for displaying text for those
1175 minor modes that are currently enabled. Its value
1176 is a list of elements of the form (VARIABLE STRING),
1177 where STRING is to be displayed if VARIABLE's value
1178 (in the buffer whose mode line is being displayed)
1179 is non-nil. This variable is not made local to particular
1180 buffers, but loading some libraries may add elements to it.
1181
1182global-mode-string
1183 This variable is used to display the time, if you ask
1184 for that.
1185
1186The idea of these variables is to eliminate the need for major modes
1187to alter mode-line-format itself.
1188
1189** `window-point' valid for selected window.
1190
1191The value returned by `window-point' used to be incorrect when its
1192argument was the selected window. Now the value is correct.
1193
1194** Window configurations may be saved as Lisp objects.
1195
1196The function `current-window-configuration' returns a special type of
1197Lisp object that represents the current layout of windows: the
1198sizes and positions of windows, which buffers appear in them, and
1199which parts of the buffers appear on the screen.
1200
1201The function `set-window-configuration' takes one argument, which must
1202be a window configuration object, and restores that configuration.
1203
1204** New hook `temp-output-buffer-show-hook'.
1205
1206This hook allows you to control how help buffers are displayed.
1207Whenever `with-output-to-temp-buffer' has executed its body and wants
1208to display the temp buffer, if this variable is bound and non-`nil'
1209then its value is called with one argument, the temp buffer.
1210The hook function is solely responsible for displaying the buffer.
1211The standard manner of display--making the buffer appear in a window--is
1212used only if there is no hook function.
1213
1214** New function `minibuffer-window'.
1215
1216This function returns the window used (sometimes) for displaying
1217the minibuffer. It can be used even when the minibuffer is not active.
1218
1219** New feature to `next-window'.
1220
1221If the optional second argument is neither `nil' nor `t', the minibuffer
1222window is omitted from consideration even when active; if the starting
1223window was the last non-minibuffer window, the value will be the first
1224non-minibuffer window.
1225
1226** New variable `minibuffer-scroll-window'.
1227
1228When this variable is non-`nil', the command `scroll-other-window'
1229uses it as the window to be scrolled. Displays of completion-lists
1230set this variable to the window containing the display.
1231
1232** New argument to `sit-for'.
1233
1234A non-nil second argument to `sit-for' means do not redisplay;
1235just wait for the specified time or until input is available.
1236
1237** Deleted function `set-minor-mode'; minor modes must be changed.
1238
1239The function `set-minor-mode' has been eliminated. The display
1240of minor mode names in the mode line is now controlled by the
1241variable `minor-mode-alist'. To specify display of a new minor
1242mode, it is sufficient to add an element to this list. Once that
1243is done, you can turn the mode on and off just by setting a variable,
1244and the display will show its status automatically.
1245
1246** New variable `cursor-in-echo-area'.
1247
1248If this variable is non-nil, the screen cursor appears on the
1249last line of the screen, at the end of the text displayed there.
1250
1251Binding this variable to t is useful at times when reading single
1252characters of input with `read-char'.
1253
1254** New per-buffer variable `selective-display-ellipses'.
1255
1256If this variable is non-nil, an ellipsis (`...') appears on the screen
1257at the end of each text line that is followed by invisible text.
1258
1259If this variable is nil, no ellipses appear. Then there is no sign
1260on the screen that invisible text is present.
1261
1262Text is made invisible under the control of the variable
1263`selective-display'; this is how Outline mode and C-x $ work.
1264
1265** New variable `no-redraw-on-reenter'.
1266
1267If you set this variable non-nil, Emacs will not clear the screen when
1268you resume it after suspending it. This is for the sake of terminals
1269with multiple screens of memory, where the termcap entry has been set
1270up to switch between screens when Emacs is suspended and resumed.
1271
1272** New argument to `set-screen-height' or `set-screen-width'.
1273
1274These functions now take an optional second argument which says
1275what significance the newly specified height or width has.
1276
1277If the argument is nil, or absent, it means that Emacs should
1278believe that the terminal height or width really is as just specified.
1279
1280If the argument is t, it means Emacs should not believe that the
1281terminal really is this high or wide, but it should use the
1282specific height or width as the number of lines or columns to display.
1283Thus, you could display only 24 lines on a screen known to have 48 lines.
1284
1285What practical difference is there between using only 24 lines for display
1286and really believing that the terminal has 24 lines?
1287
12881. The ``real'' height of the terminal says what the terminal command
1289to move the cursor to the last line will do.
1290
12912. The ``real'' height of the terminal determines how much padding is
1292needed.
1293
1294* File-related changes.
1295
1296** New parameter `backup-by-copying-when-mismatch'.
1297
1298If this variable is non-`nil', then when Emacs is about to save a
1299file, it will create the backup file by copying if that would avoid
1300changing the file's uid or gid.
1301
1302The default value of this variable is `nil', because usually it is
1303useful to have the uid of a file change according to who edited it
1304last. I recommend thet this variable be left normally `nil' and
1305changed with a local variables list in those particular files where
1306the uid needs to be preserved.
1307
1308** New parameter `file-precious-flag'.
1309
1310If this variable is non-`nil', saving the buffer tries to avoid
1311leaving an incomplete file due to disk full or other I/O errors.
1312It renames the old file before saving. If saving is successful,
1313the renamed file is deleted; if saving gets an error, the renamed
1314file is renamed back to the name you visited.
1315
1316Backups are always made by copying for such files.
1317
1318** New variable `buffer-offer-save'.
1319
1320If the value of this variable is non-`nil' in a buffer then exiting
1321Emacs will offer to save the buffer (if it is modified and nonempty)
1322even if the buffer is not visiting a file. This variable is
1323automatically made local to the current buffer whenever it is set.
1324
1325** `rename-file', `copy-file', `add-name-to-file' and `make-symbolic-link'.
1326
1327The third argument to these functions used to be `t' or `nil'; `t'
1328meaning go ahead even if the specified new file name already has a file,
1329and `nil' meaning to get an error.
1330
1331Now if the third argument is a number it means to ask the user for
1332confirmation in this case.
1333
1334** New optional argument to `copy-file'.
1335
1336If `copy-file' receives a non-nil fourth argument, it attempts
1337to give the new copy the same time-of-last-modification that the
1338original file has.
1339
1340** New function `file-newer-than-file-p'.
1341
1342(file-newer-than-file-p FILE1 FILE2) returns non-nil if FILE1 has been
1343modified more recently than FILE2. If FILE1 does not exist, the value
1344is always nil; otherwise, if FILE2 does not exist, the value is t.
1345This is meant for use when FILE2 depends on FILE1, to see if changes
1346in FILE1 make it necessary to recompute FILE2 from it.
1347
1348** Changed function `file-exists-p'.
1349
1350This function is no longer the same as `file-readable-p'.
1351`file-exists-p' can now return t for a file that exists but which
1352the fascists won't allow you to read.
1353
1354** New function `file-locked-p'.
1355
1356This function receives a file name as argument and returns `nil'
1357if the file is not locked, `t' if locked by this Emacs, or a
1358string giving the name of the user who has locked it.
1359
1360** New function `file-name-sans-versions'.
1361
1362(file-name-sans-versions NAME) returns a substring of NAME, with any
1363version numbers or other backup suffixes deleted from the end.
1364
1365** New functions for directory names.
1366
1367Although a directory is really a kind of file, specifying a directory
1368uses a somewhat different syntax from specifying a file.
1369In Emacs, a directory name is used as part of a file name.
1370
1371On Unix, the difference is small: a directory name ends in a slash,
1372while a file name does not: thus, `/usr/rms/' to name a directory,
1373while `/usr/rms' names the file which holds that directory.
1374
1375On VMS, the difference is considerable: `du:[rms.foo]' specifies a
1376directory, but the name of the file that holds that directory is
1377`du:[rms]foo.dir'.
1378
1379There are two new functions for converting between directory names
1380and file names. `directory-file-name' takes a directory name and
1381returns the name of the file in which that directory's data is stored.
1382`file-name-as-directory' takes the name of a file and returns
1383the corresponding directory name. These always understand Unix file name
1384syntax; on VMS, they understand VMS syntax as well.
1385
1386For example, (file-name-as-directory "/usr/rms") returns "/usr/rms/"
1387and (directory-file-name "/usr/rms/") returns "/usr/rms".
1388On VMS, (file-name-as-directory "du:[rms]foo.dir") returns "du:[rms.foo]"
1389and (directory-file-name "du:[rms.foo]") returns "du:[rms]foo.dir".
1390
1391** Value of `file-attributes' changed.
1392
1393The function file-attributes returns a list containing many kinds of
1394information about a file. Now the list has eleven elements.
1395
1396The tenth element is `t' if deleting the file and creating another
1397file of the same name would result in a change in the file's group;
1398`nil' if there would be no change. You can also think of this as
1399comparing the file's group with the default group for files created in
1400the same directory by you.
1401
1402The eleventh element is the inode number of the file.
1403
1404** VMS-only function `file-name-all-versions'.
1405
1406This function returns a list of all the completions, including version
1407number, of a specified version-number-less file name. This is like
1408`file-name-all-completions', except that the latter returns values
1409that do not include version numbers.
1410
1411** VMS-only variable `vms-stmlf-recfm'.
1412
1413On a VMS system, if this variable is non-nil, Emacs will give newly
1414created files the record format `stmlf'. This is necessary for files
1415that must contain lines of arbitrary length, such as compiled Emacs
1416Lisp.
1417
1418When writing a new version of an existing file, Emacs always keeps
1419the same record format as the previous version; so this variable has
1420no effect.
1421
1422This variable has no effect on Unix systems.
1423
1424** `insert-file-contents' on an empty file.
1425
1426This no longer sets the buffer's "modified" flag.
1427
1428** New function (VMS only) `define-logical-name':
1429
1430(define-logical-name LOGICAL TRANSLATION) defines a VMS logical name
1431LOGICAL whose translation is TRANSLATION. The new name applies to
1432the current process only.
1433
1434** Deleted variable `ask-about-buffer-names'.
1435
1436If you want buffer names for files to be generated in a special way,
1437you must redefine `create-file-buffer'.
1438
1439* Subprocess-related changes.
1440
1441** New function `process-list'.
1442
1443This function takes no arguments and returns a list of all
1444of Emacs's asynchronous subprocesses.
1445
1446** New function `process-exit-status'.
1447
1448This function, given a process, process name or buffer as argument,
1449returns the exit status code or signal number of the process.
1450If the process has not yet exited or died, this function returns 0.
1451
1452** Process output ignores `buffer-read-only'.
1453
1454Output from a process will go into the process's buffer even if the
1455buffer is read only.
1456
1457** Switching buffers in filter functions and sentinels.
1458
1459Emacs no longer saves and restore the current buffer around calling
1460the filter and sentinel functions, so these functions can now
1461permanently alter the selected buffer in a straightforward manner.
1462
1463** Specifying environment variables for subprocesses.
1464
1465When a subprocess is started with `start-process' or `call-process',
1466the value of the variable `process-environment' is taken to
1467specify the environment variables to give the subprocess. The
1468value should be a list of strings, each of the form "VAR=VALUE".
1469
1470`process-environment' is initialized when Emacs starts up
1471based on Emacs's environment.
1472
1473** New variable `process-connection-type'.
1474
1475If this variable is `nil', when a subprocess is created, Emacs uses
1476a pipe rather than a pty to communicate with it. Normally this
1477variable is `t', telling Emacs to use a pty if ptys are supported
1478and one is available.
1479
1480** New function `waiting-for-user-input-p'.
1481
1482This function, given a subprocess as argument, returns `t' if that
1483subprocess appears to be waiting for input sent from Emacs,
1484or `nil' otherwise.
1485
1486** New hook `shell-set-directory-error-hook'.
1487
1488The value of this variable is called, with no arguments, whenever
1489Shell mode gets an error trying to keep track of directory-setting
1490commands (such as `cd' and `pushd') used in the shell buffer.
1491
1492* New functions `user-uid' and `user-real-uid'.
1493
1494These functions take no arguments and return, respectively,
1495the effective uid and the real uid of the Emacs process.
1496The value in each case is an integer.
1497
1498* New variable `print-escape-newlines' controls string printing.
1499
1500If this variable is non-`nil', then when a Lisp string is printed
1501by the Lisp printing function `prin1' or `print', newline characters
1502are printed as `\n' rather than as a literal newline.
1503
1504* New function `sysnetunam' on HPUX.
1505
1506This function takes two arguments, a network address PATH and a
1507login string LOGIN, and executes the system call `netunam'.
1508It returns `t' if the call succeeds, otherwise `nil'.
1509\f
1510News regarding installation:
1511
1512* Many `s-...' file names changed.
1513
1514Many `s-...' files have been renamed. All periods in such names,
1515except the ones just before the final `h', have been changed to
1516hyphens. Thus, `s-bsd4.2.h' has been renamed to `s-bsd4-2.h'.
1517
1518This is so a Unix distribution can be moved mechanically to VMS.
1519
1520* `DOCSTR...' file now called `DOC-...'.
1521
1522The file of on-line documentation strings, that used to be
1523`DOCSTR.mm.nn.oo' in this directory, is now called `DOC-mm.nn.oo'.
1524This is so that it can port to VMS using the standard conventions
1525for translating filenames for VMS.
1526
1527This file also now contains the doc strings for variables as
1528well as functions.
1529
1530* Emacs no longer uses floating point arithmetic.
1531
1532This may make it easier to port to some machines.
1533
1534* Macros `XPNTR' and `XSETPNTR'; flag `DATA_SEG_BITS'.
1535
1536These macros exclusively are used to unpack a pointer from a Lisp_Object
1537and to insert a pointer into a Lisp_Object. Redefining them may help
1538port Emacs to machines in which all pointers to data objects have
1539certain high bits set.
1540
1541If `DATA_SEG_BITS' is defined, it should be a number which contains
1542the high bits to be inclusive or'ed with pointers that are unpacked.
1543
1544* New flag `HAVE_X_MENU'.
1545
1546Define this flag in `config.h' in addition to `HAVE_X_WINDOWS'
1547to enable use of the Emacs interface to X Menus. On some operating
1548systems, the rest of the X interface works properly but X Menus
1549do not work; hence this separate flag. See the file `src/xmenu.c'
1550for more information.
1551
1552* Macros `ARRAY_MARK_FLAG' and `DONT_COPY_FLAG'.
1553
1554* `HAVE_ALLOCA' prevents assembly of `alloca.s'.
1555
1556* `SYSTEM_MALLOC' prevents use of GNU `malloc.c'.
1557
1558SYSTEM_MALLOC, if defined, means use the system's own `malloc' routines
1559rather than those that come with Emacs.
1560
1561Use this only if absolutely necessary, because if it is used you do
1562not get warnings when space is getting low.
1563
1564* New flags to control unexec.
1565
1566See the file `unexec.c' for a long comment on the compilation
1567switches that suffice to make it work on many machines.
1568
1569* `PNTR_COMPARISON_TYPE'
1570
1571Pointers that need to be compared for ordering are converted to this type
1572first. Normally this is `unsigned int'.
1573
1574* `HAVE_VFORK', `HAVE_DUP2' and `HAVE_GETTIMEOFDAY'.
1575
1576These flags just say whether certain system calls are available.
1577
1578* New macros control compiler switches, linker switches and libraries.
1579
1580The m- and s- files can now control in a modular fashion the precise
1581arguments passed to `cc' and `ld'.
1582
1583LIBS_STANDARD defines the standard C libraries. Default is `-lc'.
1584LIBS_DEBUG defines the extra libraries to use when debugging. Default `-lg'.
1585LIBS_SYSTEM can be defined by the s- file to specify extra libraries.
1586LIBS_MACHINE can be defined by the m- file to specify extra libraries.
1587LIBS_TERMCAP defines the libraries for Termcap or Terminfo.
1588 It is defined by default in a complicated fashion but the m- or s- file
1589 can override it.
1590
1591LD_SWITCH_SYSTEM can be defined by the s- file to specify extra `ld' switches.
1592 The default is `-X' on BSD systems except those few that use COFF object files.
1593LD_SWITCH_MACHINE can be defined by the m- file to specify extra `ld' switches.
1594
1595C_DEBUG_SWITCH defines the switches to give `cc' when debugging. Default `-g'.
1596C_OPTIMIZE_SWITCH defines the switches to give `cc' to optimize. Default `-O'.
1597C_SWITCH_MACHINE can be defined by the m- file to specify extra `cc' switches.
a933dad1 1598
9a21d88b
KS
1599
1600\f
a933dad1
DL
1601----------------------------------------------------------------------
1602Copyright information:
1603
0a33da51 1604Copyright (C) 1988, 2006, 2007 Free Software Foundation, Inc.
a933dad1
DL
1605
1606 Permission is granted to anyone to make or distribute verbatim copies
1607 of this document as received, in any medium, provided that the
1608 copyright notice and this permission notice are preserved,
1609 thus giving the recipient permission to redistribute in turn.
1610
1611 Permission is granted to distribute modified versions
1612 of this document, or of portions of it,
1613 under the above conditions, provided also that they
1614 carry prominent notices stating who last changed them.
1615\f
1616Local variables:
1617mode: text
1618end:
ab5796a9
MB
1619
1620arch-tag: 8fed393b-c9c5-47d1-afbb-c0e7a135094a