Switch to standard GPL text for license.
[bpt/emacs.git] / etc / NEWS.21
CommitLineData
9a21d88b 1GNU Emacs NEWS -- history of user-visible changes. 2006-05-31
5b87ad55 2
0a33da51 3Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
5b87ad55
GM
4 Free Software Foundation, Inc.
5See the end of the file for license conditions.
6
9a21d88b
KS
7
8This file is about changes in emacs version 21.
9
10
11\f
12* Emacs 21.4 is a bug-fix release with no user-visible changes.
13
14
15\f
16* Installation changes in Emacs 21.3
17
18** Support for GNU/Linux on little-endian MIPS and on IBM S390 has
19been added.
20
21\f
22* Changes in Emacs 21.3
23
24** The obsolete C mode (c-mode.el) has been removed to avoid problems
25with Custom.
26
27** UTF-16 coding systems are available, encoding the same characters
28as mule-utf-8.
29
30** There is a new language environment for UTF-8 (set up automatically
31in UTF-8 locales).
32
33** Translation tables are available between equivalent characters in
34different Emacs charsets -- for instance `e with acute' coming from the
35Latin-1 and Latin-2 charsets. User options `unify-8859-on-encoding-mode'
36and `unify-8859-on-decoding-mode' respectively turn on translation
37between ISO 8859 character sets (`unification') on encoding
38(e.g. writing a file) and decoding (e.g. reading a file). Note that
39`unify-8859-on-encoding-mode' is useful and safe, but
40`unify-8859-on-decoding-mode' can cause text to change when you read
41it and write it out again without edits, so it is not generally advisable.
42By default `unify-8859-on-encoding-mode' is turned on.
43
44** In Emacs running on the X window system, the default value of
45`selection-coding-system' is now `compound-text-with-extensions'.
46
47If you want the old behavior, set selection-coding-system to
48compound-text, which may be significantly more efficient. Using
49compound-text-with-extensions seems to be necessary only for decoding
50text from applications under XFree86 4.2, whose behavior is actually
51contrary to the compound text specification.
52
53
54\f
55* Installation changes in Emacs 21.2
56
57** Support for BSD/OS 5.0 has been added.
58
59** Support for AIX 5.1 was added.
60
61\f
62* Changes in Emacs 21.2
63
64** Emacs now supports compound-text extended segments in X selections.
65
66X applications can use `extended segments' to encode characters in
67compound text that belong to character sets which are not part of the
68list of approved standard encodings for X, e.g. Big5. To paste
69selections with such characters into Emacs, use the new coding system
70compound-text-with-extensions as the value of selection-coding-system.
71
72** The default values of `tooltip-delay' and `tooltip-hide-delay'
73were changed.
74
75** On terminals whose erase-char is ^H (Backspace), Emacs
76now uses normal-erase-is-backspace-mode.
77
78** When the *scratch* buffer is recreated, its mode is set from
79initial-major-mode, which normally is lisp-interaction-mode,
80instead of using default-major-mode.
81
82** The new option `Info-scroll-prefer-subnodes' causes Info to behave
83like the stand-alone Info reader (from the GNU Texinfo package) as far
84as motion between nodes and their subnodes is concerned. If it is t
85(the default), Emacs behaves as before when you type SPC in a menu: it
86visits the subnode pointed to by the first menu entry. If this option
87is nil, SPC scrolls to the end of the current node, and only then goes
88to the first menu item, like the stand-alone reader does.
89
90This change was already in Emacs 21.1, but wasn't advertised in the
91NEWS.
92
93\f
94* Lisp Changes in Emacs 21.2
95
96** The meanings of scroll-up-aggressively and scroll-down-aggressively
97have been interchanged, so that the former now controls scrolling up,
98and the latter now controls scrolling down.
99
100** The variable `compilation-parse-errors-filename-function' can
101be used to transform filenames found in compilation output.
102
103
104\f
105* Installation Changes in Emacs 21.1
106
107See the INSTALL file for information on installing extra libraries and
108fonts to take advantage of the new graphical features and extra
109charsets in this release.
110
111** Support for GNU/Linux on IA64 machines has been added.
112
113** Support for LynxOS has been added.
114
115** There are new configure options associated with the support for
116images and toolkit scrollbars. Use the --help option in `configure'
117to list them.
118
119** You can build a 64-bit Emacs for SPARC/Solaris systems which
120support 64-bit executables and also on Irix 6.5. This increases the
121maximum buffer size. See etc/MACHINES for instructions. Changes to
122build on other 64-bit systems should be straightforward modulo any
123necessary changes to unexec.
124
125** There is a new configure option `--disable-largefile' to omit
126Unix-98-style support for large files if that is available.
127
128** There is a new configure option `--without-xim' that instructs
129Emacs to not use X Input Methods (XIM), if these are available.
130
131** `movemail' defaults to supporting POP. You can turn this off using
132the --without-pop configure option, should that be necessary.
133
134** This version can be built for the Macintosh, but does not implement
135all of the new display features described below. The port currently
136lacks unexec, asynchronous processes, and networking support. See the
137"Emacs and the Mac OS" appendix in the Emacs manual, for the
138description of aspects specific to the Mac.
139
140** Note that the MS-Windows port does not yet implement various of the
141new display features described below.
142
143\f
144* Changes in Emacs 21.1
145
146** Emacs has a new redisplay engine.
147
148The new redisplay handles characters of variable width and height.
149Italic text can be used without redisplay problems. Fonts containing
150oversized characters, i.e. characters larger than the logical height
151of a font can be used. Images of various formats can be displayed in
152the text.
153
154** Emacs has a new face implementation.
155
156The new faces no longer fundamentally use X font names to specify the
157font. Instead, each face has several independent attributes--family,
158height, width, weight and slant--that it may or may not specify.
159These attributes can be merged from various faces, and then together
160specify a font.
161
162Faces are supported on terminals that can display color or fonts.
163These terminal capabilities are auto-detected. Details can be found
164under Lisp changes, below.
165
166** Emacs can display faces on TTY frames.
167
168Emacs automatically detects terminals that are able to display colors.
169Faces with a weight greater than normal are displayed extra-bright, if
170the terminal supports it. Faces with a weight less than normal and
171italic faces are displayed dimmed, if the terminal supports it.
172Underlined faces are displayed underlined if possible. Other face
173attributes such as `overline', `strike-through', and `box' are ignored
174on terminals.
175
176The command-line options `-fg COLOR', `-bg COLOR', and `-rv' are now
177supported on character terminals.
178
179Emacs automatically remaps all X-style color specifications to one of
180the colors supported by the terminal. This means you could have the
181same color customizations that work both on a windowed display and on
182a TTY or when Emacs is invoked with the -nw option.
183
184** New default font is Courier 12pt under X.
185
186** Sound support
187
188Emacs supports playing sound files on GNU/Linux and FreeBSD (Voxware
189driver and native BSD driver, a.k.a. Luigi's driver). Currently
190supported file formats are RIFF-WAVE (*.wav) and Sun Audio (*.au).
191You must configure Emacs with the option `--with-sound=yes' to enable
192sound support.
193
194** Emacs now resizes mini-windows if appropriate.
195
196If a message is longer than one line, or minibuffer contents are
197longer than one line, Emacs can resize the minibuffer window unless it
198is on a frame of its own. You can control resizing and the maximum
199minibuffer window size by setting the following variables:
200
201- User option: max-mini-window-height
202
203Maximum height for resizing mini-windows. If a float, it specifies a
204fraction of the mini-window frame's height. If an integer, it
205specifies a number of lines.
206
207Default is 0.25.
208
209- User option: resize-mini-windows
210
211How to resize mini-windows. If nil, don't resize. If t, always
212resize to fit the size of the text. If `grow-only', let mini-windows
213grow only, until they become empty, at which point they are shrunk
214again.
215
216Default is `grow-only'.
217
218** LessTif support.
219
220Emacs now runs with the LessTif toolkit (see
221<http://www.lesstif.org>). You will need version 0.92.26, or later.
222
223** LessTif/Motif file selection dialog.
224
225When Emacs is configured to use LessTif or Motif, reading a file name
226from a menu will pop up a file selection dialog if `use-dialog-box' is
227non-nil.
228
229** File selection dialog on MS-Windows is supported.
230
231When a file is visited by clicking File->Open, the MS-Windows version
232now pops up a standard file selection dialog where you can select a
233file to visit. File->Save As also pops up that dialog.
234
235** Toolkit scroll bars.
236
237Emacs now uses toolkit scroll bars if available. When configured for
238LessTif/Motif, it will use that toolkit's scroll bar. Otherwise, when
239configured for Lucid and Athena widgets, it will use the Xaw3d scroll
240bar if Xaw3d is available. You can turn off the use of toolkit scroll
241bars by specifying `--with-toolkit-scroll-bars=no' when configuring
242Emacs.
243
244When you encounter problems with the Xaw3d scroll bar, watch out how
245Xaw3d is compiled on your system. If the Makefile generated from
246Xaw3d's Imakefile contains a `-DNARROWPROTO' compiler option, and your
247Emacs system configuration file `s/your-system.h' does not contain a
248define for NARROWPROTO, you might consider adding it. Take
249`s/freebsd.h' as an example.
250
251Alternatively, if you don't have access to the Xaw3d source code, take
252a look at your system's imake configuration file, for example in the
253directory `/usr/X11R6/lib/X11/config' (paths are different on
254different systems). You will find files `*.cf' there. If your
255system's cf-file contains a line like `#define NeedWidePrototypes NO',
256add a `#define NARROWPROTO' to your Emacs system configuration file.
257
258The reason for this is that one Xaw3d function uses `double' or
259`float' function parameters depending on the setting of NARROWPROTO.
260This is not a problem when Imakefiles are used because each system's
261imake configuration file contains the necessary information. Since
262Emacs doesn't use imake, this has do be done manually.
263
264** Tool bar support.
265
266Emacs supports a tool bar at the top of a frame under X. For details
267of how to define a tool bar, see the page describing Lisp-level
268changes. Tool-bar global minor mode controls whether or not it is
269displayed and is on by default. The appearance of the bar is improved
270if Emacs has been built with XPM image support. Otherwise monochrome
271icons will be used.
272
273To make the tool bar more useful, we need contributions of extra icons
274for specific modes (with copyright assignments).
275
276** Tooltips.
277
278Tooltips are small X windows displaying a help string at the current
279mouse position. The Lisp package `tooltip' implements them. You can
280turn them off via the user option `tooltip-mode'.
281
282Tooltips also provides support for GUD debugging. If activated,
283variable values can be displayed in tooltips by pointing at them with
284the mouse in source buffers. You can customize various aspects of the
285tooltip display in the group `tooltip'.
286
287** Automatic Hscrolling
288
289Horizontal scrolling now happens automatically if
290`automatic-hscrolling' is set (the default). This setting can be
291customized.
292
293If a window is scrolled horizontally with set-window-hscroll, or
294scroll-left/scroll-right (C-x <, C-x >), this serves as a lower bound
295for automatic horizontal scrolling. Automatic scrolling will scroll
296the text more to the left if necessary, but won't scroll the text more
297to the right than the column set with set-window-hscroll etc.
298
299** When using a windowing terminal, each Emacs window now has a cursor
300of its own. By default, when a window is selected, the cursor is
301solid; otherwise, it is hollow. The user-option
302`cursor-in-non-selected-windows' controls how to display the
303cursor in non-selected windows. If nil, no cursor is shown, if
304non-nil a hollow box cursor is shown.
305
306** Fringes to the left and right of windows are used to display
307truncation marks, continuation marks, overlay arrows and alike. The
308foreground, background, and stipple of these areas can be changed by
309customizing face `fringe'.
310
311** The mode line under X is now drawn with shadows by default.
312You can change its appearance by modifying the face `mode-line'.
313In particular, setting the `:box' attribute to nil turns off the 3D
314appearance of the mode line. (The 3D appearance makes the mode line
315occupy more space, and thus might cause the first or the last line of
316the window to be partially obscured.)
317
318The variable `mode-line-inverse-video', which was used in older
319versions of emacs to make the mode-line stand out, is now deprecated.
320However, setting it to nil will cause the `mode-line' face to be
321ignored, and mode-lines to be drawn using the default text face.
322
323** Mouse-sensitive mode line.
324
325Different parts of the mode line have been made mouse-sensitive on all
326systems which support the mouse. Moving the mouse to a
327mouse-sensitive part in the mode line changes the appearance of the
328mouse pointer to an arrow, and help about available mouse actions is
329displayed either in the echo area, or in the tooltip window if you
330have enabled one.
331
332Currently, the following actions have been defined:
333
334- Mouse-1 on the buffer name in the mode line goes to the next buffer.
335
336- Mouse-3 on the buffer-name goes to the previous buffer.
337
338- Mouse-2 on the read-only or modified status in the mode line (`%' or
339`*') toggles the status.
340
341- Mouse-3 on the major mode name displays a major mode menu.
342
343- Mouse-3 on the mode name displays a minor-mode menu.
344
345** Hourglass pointer
346
347Emacs can optionally display an hourglass pointer under X. You can
348turn the display on or off by customizing group `cursor'.
349
350** Blinking cursor
351
352M-x blink-cursor-mode toggles a blinking cursor under X and on
353terminals having terminal capabilities `vi', `vs', and `ve'. Blinking
354and related parameters like frequency and delay can be customized in
355the group `cursor'.
356
357** New font-lock support mode `jit-lock-mode'.
358
359This support mode is roughly equivalent to `lazy-lock' but is
360generally faster. It supports stealth and deferred fontification.
361See the documentation of the function `jit-lock-mode' for more
362details.
363
364Font-lock uses jit-lock-mode as default support mode, so you don't
365have to do anything to activate it.
366
367** The default binding of the Delete key has changed.
368
369The new user-option `normal-erase-is-backspace' can be set to
370determine the effect of the Delete and Backspace function keys.
371
372On window systems, the default value of this option is chosen
373according to the keyboard used. If the keyboard has both a Backspace
374key and a Delete key, and both are mapped to their usual meanings, the
375option's default value is set to t, so that Backspace can be used to
376delete backward, and Delete can be used to delete forward. On
377keyboards which either have only one key (usually labeled DEL), or two
378keys DEL and BS which produce the same effect, the option's value is
379set to nil, and these keys delete backward.
380
381If not running under a window system, setting this option accomplishes
382a similar effect by mapping C-h, which is usually generated by the
383Backspace key, to DEL, and by mapping DEL to C-d via
384`keyboard-translate'. The former functionality of C-h is available on
385the F1 key. You should probably not use this setting on a text-only
386terminal if you don't have both Backspace, Delete and F1 keys.
387
388Programmatically, you can call function normal-erase-is-backspace-mode
389to toggle the behavior of the Delete and Backspace keys.
390
391** The default for user-option `next-line-add-newlines' has been
392changed to nil, i.e. C-n will no longer add newlines at the end of a
393buffer by default.
394
395** The <home> and <end> keys now move to the beginning or end of the
396current line, respectively. C-<home> and C-<end> move to the
397beginning and end of the buffer.
398
399** Emacs now checks for recursive loads of Lisp files. If the
400recursion depth exceeds `recursive-load-depth-limit', an error is
401signaled.
402
403** When an error is signaled during the loading of the user's init
404file, Emacs now pops up the *Messages* buffer.
405
406** Emacs now refuses to load compiled Lisp files which weren't
407compiled with Emacs. Set `load-dangerous-libraries' to t to change
408this behavior.
409
410The reason for this change is an incompatible change in XEmacs's byte
411compiler. Files compiled with XEmacs can contain byte codes that let
412Emacs dump core.
413
414** Toggle buttons and radio buttons in menus.
415
416When compiled with LessTif (or Motif) support, Emacs uses toolkit
417widgets for radio and toggle buttons in menus. When configured for
418Lucid, Emacs draws radio buttons and toggle buttons similar to Motif.
419
420** The menu bar configuration has changed. The new configuration is
421more CUA-compliant. The most significant change is that Options is
422now a separate menu-bar item, with Mule and Customize as its submenus.
423
424** Item Save Options on the Options menu allows saving options set
425using that menu.
426
427** Highlighting of trailing whitespace.
428
429When `show-trailing-whitespace' is non-nil, Emacs displays trailing
430whitespace in the face `trailing-whitespace'. Trailing whitespace is
431defined as spaces or tabs at the end of a line. To avoid busy
432highlighting when entering new text, trailing whitespace is not
433displayed if point is at the end of the line containing the
434whitespace.
435
436** C-x 5 1 runs the new command delete-other-frames which deletes
437all frames except the selected one.
438
439** The new user-option `confirm-kill-emacs' can be customized to
440let Emacs ask for confirmation before exiting.
441
442** The header line in an Info buffer is now displayed as an emacs
443header-line (which is like a mode-line, but at the top of the window),
444so that it remains visible even when the buffer has been scrolled.
445This behavior may be disabled by customizing the option
446`Info-use-header-line'.
447
448** Polish, Czech, German, and French translations of Emacs' reference card
449have been added. They are named `pl-refcard.tex', `cs-refcard.tex',
450`de-refcard.tex' and `fr-refcard.tex'. Postscript files are included.
451
452** An `Emacs Survival Guide', etc/survival.tex, is available.
453
454** A reference card for Dired has been added. Its name is
455`dired-ref.tex'. A French translation is available in
456`fr-drdref.tex'.
457
458** C-down-mouse-3 is bound differently. Now if the menu bar is not
459displayed it pops up a menu containing the items which would be on the
460menu bar. If the menu bar is displayed, it pops up the major mode
461menu or the Edit menu if there is no major mode menu.
462
463** Variable `load-path' is no longer customizable through Customize.
464
465You can no longer use `M-x customize-variable' to customize `load-path'
466because it now contains a version-dependent component. You can still
467use `add-to-list' and `setq' to customize this variable in your
468`~/.emacs' init file or to modify it from any Lisp program in general.
469
470** C-u C-x = provides detailed information about the character at
471point in a pop-up window.
472
473** Emacs can now support 'wheeled' mice (such as the MS IntelliMouse)
474under XFree86. To enable this, use the `mouse-wheel-mode' command, or
475customize the variable `mouse-wheel-mode'.
476
477The variables `mouse-wheel-follow-mouse' and `mouse-wheel-scroll-amount'
478determine where and by how much buffers are scrolled.
479
480** Emacs' auto-save list files are now by default stored in a
481sub-directory `.emacs.d/auto-save-list/' of the user's home directory.
482(On MS-DOS, this subdirectory's name is `_emacs.d/auto-save.list/'.)
483You can customize `auto-save-list-file-prefix' to change this location.
484
485** The function `getenv' is now callable interactively.
486
487** The new user-option `even-window-heights' can be set to nil
488to prevent `display-buffer' from evening out window heights.
489
490** The new command M-x delete-trailing-whitespace RET will delete the
491trailing whitespace within the current restriction. You can also add
492this function to `write-file-hooks' or `local-write-file-hooks'.
493
494** When visiting a file with M-x find-file-literally, no newlines will
495be added to the end of the buffer even if `require-final-newline' is
496non-nil.
497
498** The new user-option `find-file-suppress-same-file-warnings' can be
499set to suppress warnings ``X and Y are the same file'' when visiting a
500file that is already visited under a different name.
501
502** The new user-option `electric-help-shrink-window' can be set to
503nil to prevent adjusting the help window size to the buffer size.
504
505** New command M-x describe-character-set reads a character set name
506and displays information about that.
507
508** The new variable `auto-mode-interpreter-regexp' contains a regular
509expression matching interpreters, for file mode determination.
510
511This regular expression is matched against the first line of a file to
512determine the file's mode in `set-auto-mode' when Emacs can't deduce a
513mode from the file's name. If it matches, the file is assumed to be
514interpreted by the interpreter matched by the second group of the
515regular expression. The mode is then determined as the mode
516associated with that interpreter in `interpreter-mode-alist'.
517
518** New function executable-make-buffer-file-executable-if-script-p is
519suitable as an after-save-hook as an alternative to `executable-chmod'.
520
521** The most preferred coding-system is now used to save a buffer if
522buffer-file-coding-system is `undecided' and it is safe for the buffer
523contents. (The most preferred is set by set-language-environment or
524by M-x prefer-coding-system.) Thus if you visit an ASCII file and
525insert a non-ASCII character from your current language environment,
526the file will be saved silently with the appropriate coding.
527Previously you would be prompted for a safe coding system.
528
529** The many obsolete language `setup-...-environment' commands have
530been removed -- use `set-language-environment'.
531
532** The new Custom option `keyboard-coding-system' specifies a coding
533system for keyboard input.
534
535** New variable `inhibit-iso-escape-detection' determines if Emacs'
536coding system detection algorithm should pay attention to ISO2022's
537escape sequences. If this variable is non-nil, the algorithm ignores
538such escape sequences. The default value is nil, and it is
539recommended not to change it except for the special case that you
540always want to read any escape code verbatim. If you just want to
541read a specific file without decoding escape codes, use C-x RET c
542(`universal-coding-system-argument'). For instance, C-x RET c latin-1
543RET C-x C-f filename RET.
544
545** Variable `default-korean-keyboard' is initialized properly from the
546environment variable `HANGUL_KEYBOARD_TYPE'.
547
548** New command M-x list-charset-chars reads a character set name and
549displays all characters in that character set.
550
551** M-x set-terminal-coding-system (C-x RET t) now allows CCL-based
552coding systems such as cpXXX and cyrillic-koi8.
553
554** Emacs now attempts to determine the initial language environment
555and preferred and locale coding systems systematically from the
556LC_ALL, LC_CTYPE, and LANG environment variables during startup.
557
558** New language environments `Polish', `Latin-8' and `Latin-9'.
559Latin-8 and Latin-9 correspond respectively to the ISO character sets
5608859-14 (Celtic) and 8859-15 (updated Latin-1, with the Euro sign).
561GNU Intlfonts doesn't support these yet but recent X releases have
5628859-15. See etc/INSTALL for information on obtaining extra fonts.
563There are new Leim input methods for Latin-8 and Latin-9 prefix (only)
564and Polish `slash'.
565
566** New language environments `Dutch' and `Spanish'.
567These new environments mainly select appropriate translations
568of the tutorial.
569
570** In Ethiopic language environment, special key bindings for
571function keys are changed as follows. This is to conform to "Emacs
572Lisp Coding Convention".
573
574 new command old-binding
575 --- ------- -----------
576 f3 ethio-fidel-to-sera-buffer f5
577 S-f3 ethio-fidel-to-sera-region f5
578 C-f3 ethio-fidel-to-sera-mail-or-marker f5
579
580 f4 ethio-sera-to-fidel-buffer unchanged
581 S-f4 ethio-sera-to-fidel-region unchanged
582 C-f4 ethio-sera-to-fidel-mail-or-marker unchanged
583
584 S-f5 ethio-toggle-punctuation f3
585 S-f6 ethio-modify-vowel f6
586 S-f7 ethio-replace-space f7
587 S-f8 ethio-input-special-character f8
588 S-f9 ethio-replace-space unchanged
589 C-f9 ethio-toggle-space f2
590
591** There are new Leim input methods.
592New input methods "turkish-postfix", "turkish-alt-postfix",
593"greek-mizuochi", "TeX", and "greek-babel" are now part of the Leim
594package.
595
596** The rule of input method "slovak" is slightly changed. Now the
597rules for translating "q" and "Q" to "`" (backquote) are deleted, thus
598typing them inserts "q" and "Q" respectively. Rules for translating
599"=q", "+q", "=Q", and "+Q" to "`" are also deleted. Now, to input
600"`", you must type "=q".
601
602** When your terminal can't display characters from some of the ISO
6038859 character sets but can display Latin-1, you can display
604more-or-less mnemonic sequences of ASCII/Latin-1 characters instead of
605empty boxes (under a window system) or question marks (not under a
606window system). Customize the option `latin1-display' to turn this
607on.
608
609** M-; now calls comment-dwim which tries to do something clever based
610on the context. M-x kill-comment is now an alias to comment-kill,
611defined in newcomment.el. You can choose different styles of region
612commenting with the variable `comment-style'.
613
614** New user options `display-time-mail-face' and
615`display-time-use-mail-icon' control the appearance of mode-line mail
616indicator used by the display-time package. On a suitable display the
617indicator can be an icon and is mouse-sensitive.
618
619** On window-systems, additional space can be put between text lines
620on the display using several methods
621
622- By setting frame parameter `line-spacing' to PIXELS. PIXELS must be
623a positive integer, and specifies that PIXELS number of pixels should
624be put below text lines on the affected frame or frames.
625
626- By setting X resource `lineSpacing', class `LineSpacing'. This is
627equivalent to specifying the frame parameter.
628
629- By specifying `--line-spacing=N' or `-lsp N' on the command line.
630
631- By setting buffer-local variable `line-spacing'. The meaning is
632the same, but applies to the a particular buffer only.
633
634** The new command `clone-indirect-buffer' can be used to create
635an indirect buffer that is a twin copy of the current buffer. The
636command `clone-indirect-buffer-other-window', bound to C-x 4 c,
637does the same but displays the indirect buffer in another window.
638
639** New user options `backup-directory-alist' and
640`make-backup-file-name-function' control the placement of backups,
641typically in a single directory or in an invisible sub-directory.
642
643** New commands iso-iso2sgml and iso-sgml2iso convert between Latin-1
644characters and the corresponding SGML (HTML) entities.
645
646** New X resources recognized
647
648*** The X resource `synchronous', class `Synchronous', specifies
649whether Emacs should run in synchronous mode. Synchronous mode
650is useful for debugging X problems.
651
652Example:
653
654 emacs.synchronous: true
655
656*** The X resource `visualClass, class `VisualClass', specifies the
657visual Emacs should use. The resource's value should be a string of
658the form `CLASS-DEPTH', where CLASS is the name of the visual class,
659and DEPTH is the requested color depth as a decimal number. Valid
660visual class names are
661
662 TrueColor
663 PseudoColor
664 DirectColor
665 StaticColor
666 GrayScale
667 StaticGray
668
669Visual class names specified as X resource are case-insensitive, i.e.
670`pseudocolor', `Pseudocolor' and `PseudoColor' all have the same
671meaning.
672
673The program `xdpyinfo' can be used to list the visual classes
674supported on your display, and which depths they have. If
675`visualClass' is not specified, Emacs uses the display's default
676visual.
677
678Example:
679
680 emacs.visualClass: TrueColor-8
681
682*** The X resource `privateColormap', class `PrivateColormap',
683specifies that Emacs should use a private colormap if it is using the
684default visual, and that visual is of class PseudoColor. Recognized
685resource values are `true' or `on'.
686
687Example:
688
689 emacs.privateColormap: true
690
691** Faces and frame parameters.
692
693There are four new faces `scroll-bar', `border', `cursor' and `mouse'.
694Setting the frame parameters `scroll-bar-foreground' and
695`scroll-bar-background' sets foreground and background color of face
696`scroll-bar' and vice versa. Setting frame parameter `border-color'
697sets the background color of face `border' and vice versa. Likewise
698for frame parameters `cursor-color' and face `cursor', and frame
699parameter `mouse-color' and face `mouse'.
700
701Changing frame parameter `font' sets font-related attributes of the
702`default' face and vice versa. Setting frame parameters
703`foreground-color' or `background-color' sets the colors of the
704`default' face and vice versa.
705
706** New face `menu'.
707
708The face `menu' can be used to change colors and font of Emacs' menus.
709
710** New frame parameter `screen-gamma' for gamma correction.
711
712The new frame parameter `screen-gamma' specifies gamma-correction for
713colors. Its value may be nil, the default, in which case no gamma
714correction occurs, or a number > 0, usually a float, that specifies
715the screen gamma of a frame's display.
716
717PC monitors usually have a screen gamma of 2.2. smaller values result
718in darker colors. You might want to try a screen gamma of 1.5 for LCD
719color displays. The viewing gamma Emacs uses is 0.4545. (1/2.2).
720
721The X resource name of this parameter is `screenGamma', class
722`ScreenGamma'.
723
724** Tabs and variable-width text.
725
726Tabs are now displayed with stretch properties; the width of a tab is
727defined as a multiple of the normal character width of a frame, and is
728independent of the fonts used in the text where the tab appears.
729Thus, tabs can be used to line up text in different fonts.
730
731** Enhancements of the Lucid menu bar
732
733*** The Lucid menu bar now supports the resource "margin".
734
735 emacs.pane.menubar.margin: 5
736
737The default margin is 4 which makes the menu bar appear like the
738LessTif/Motif one.
739
740*** Arrows that indicate sub-menus are now drawn with shadows, as in
741LessTif and Motif.
742
743** A block cursor can be drawn as wide as the glyph under it under X.
744
745As an example: if a block cursor is over a tab character, it will be
746drawn as wide as that tab on the display. To do this, set
747`x-stretch-cursor' to a non-nil value.
748
749** Empty display lines at the end of a buffer may be marked with a
750bitmap (this is similar to the tilde displayed by vi and Less).
751
752This behavior is activated by setting the buffer-local variable
753`indicate-empty-lines' to a non-nil value. The default value of this
754variable is found in `default-indicate-empty-lines'.
755
756** There is a new "aggressive" scrolling method.
757
758When scrolling up because point is above the window start, if the
759value of the buffer-local variable `scroll-up-aggressively' is a
760number, Emacs chooses a new window start so that point ends up that
761fraction of the window's height from the top of the window.
762
763When scrolling down because point is below the window end, if the
764value of the buffer-local variable `scroll-down-aggressively' is a
765number, Emacs chooses a new window start so that point ends up that
766fraction of the window's height from the bottom of the window.
767
768** You can now easily create new *Info* buffers using either
769M-x clone-buffer, C-u m <entry> RET or C-u g <entry> RET.
770M-x clone-buffer can also be used on *Help* and several other special
771buffers.
772
773** The command `Info-search' now uses a search history.
774
775** Listing buffers with M-x list-buffers (C-x C-b) now shows
776abbreviated file names. Abbreviations can be customized by changing
777`directory-abbrev-alist'.
778
779** A new variable, backup-by-copying-when-privileged-mismatch, gives
780the highest file uid for which backup-by-copying-when-mismatch will be
781forced on. The assumption is that uids less than or equal to this
782value are special uids (root, bin, daemon, etc.--not real system
783users) and that files owned by these users should not change ownership,
784even if your system policy allows users other than root to edit them.
785
786The default is 200; set the variable to nil to disable the feature.
787
788** The rectangle commands now avoid inserting undesirable spaces,
789notably at the end of lines.
790
791All these functions have been rewritten to avoid inserting unwanted
792spaces, and an optional prefix now allows them to behave the old way.
793
794** The function `replace-rectangle' is an alias for `string-rectangle'.
795
796** The new command M-x string-insert-rectangle is like `string-rectangle',
797but inserts text instead of replacing it.
798
799** The new command M-x query-replace-regexp-eval acts like
800query-replace-regexp, but takes a Lisp expression which is evaluated
801after each match to get the replacement text.
802
803** M-x query-replace recognizes a new command `e' (or `E') that lets
804you edit the replacement string.
805
806** The new command mail-abbrev-complete-alias, bound to `M-TAB'
807(if you load the library `mailabbrev'), lets you complete mail aliases
808in the text, analogous to lisp-complete-symbol.
809
810** The variable `echo-keystrokes' may now have a floating point value.
811
812** If your init file is compiled (.emacs.elc), `user-init-file' is set
813to the source name (.emacs.el), if that exists, after loading it.
814
815** The help string specified for a menu-item whose definition contains
816the property `:help HELP' is now displayed under X, on MS-Windows, and
817MS-DOS, either in the echo area or with tooltips. Many standard menus
818displayed by Emacs now have help strings.
819
820--
821** New user option `read-mail-command' specifies a command to use to
822read mail from the menu etc.
823
824** The environment variable `EMACSLOCKDIR' is no longer used on MS-Windows.
825This environment variable was used when creating lock files. Emacs on
826MS-Windows does not use this variable anymore. This change was made
827before Emacs 21.1, but wasn't documented until now.
828
829** Highlighting of mouse-sensitive regions is now supported in the
830MS-DOS version of Emacs.
831
832** The new command `msdos-set-mouse-buttons' forces the MS-DOS version
833of Emacs to behave as if the mouse had a specified number of buttons.
834This comes handy with mice that don't report their number of buttons
835correctly. One example is the wheeled mice, which report 3 buttons,
836but clicks on the middle button are not passed to the MS-DOS version
837of Emacs.
838
839** Customize changes
840
841*** Customize now supports comments about customized items. Use the
842`State' menu to add comments, or give a prefix argument to
843M-x customize-set-variable or M-x customize-set-value. Note that
844customization comments will cause the customizations to fail in
845earlier versions of Emacs.
846
847*** The new option `custom-buffer-done-function' says whether to kill
848Custom buffers when you've done with them or just bury them (the
849default).
850
851*** If Emacs was invoked with the `-q' or `--no-init-file' options, it
852does not allow you to save customizations in your `~/.emacs' init
853file. This is because saving customizations from such a session would
854wipe out all the other customizationss you might have on your init
855file.
856
857** If Emacs was invoked with the `-q' or `--no-init-file' options, it
858does not save disabled and enabled commands for future sessions, to
859avoid overwriting existing customizations of this kind that are
860already in your init file.
861
862** New features in evaluation commands
863
864*** The commands to evaluate Lisp expressions, such as C-M-x in Lisp
865modes, C-j in Lisp Interaction mode, and M-:, now bind the variables
866print-level, print-length, and debug-on-error based on the new
867customizable variables eval-expression-print-level,
868eval-expression-print-length, and eval-expression-debug-on-error.
869
870The default values for the first two of these variables are 12 and 4
871respectively, which means that `eval-expression' now prints at most
872the first 12 members of a list and at most 4 nesting levels deep (if
873the list is longer or deeper than that, an ellipsis `...' is
874printed).
875
876<RET> or <mouse-2> on the printed text toggles between an abbreviated
877printed representation and an unabbreviated one.
878
879The default value of eval-expression-debug-on-error is t, so any error
880during evaluation produces a backtrace.
881
882*** The function `eval-defun' (C-M-x) now loads Edebug and instruments
883code when called with a prefix argument.
884
885** CC mode changes.
886
887Note: This release contains changes that might not be compatible with
888current user setups (although it's believed that these
889incompatibilities will only show in very uncommon circumstances).
890However, since the impact is uncertain, these changes may be rolled
891back depending on user feedback. Therefore there's no forward
892compatibility guarantee wrt the new features introduced in this
893release.
894
895*** The hardcoded switch to "java" style in Java mode is gone.
896CC Mode used to automatically set the style to "java" when Java mode
897is entered. This has now been removed since it caused too much
898confusion.
899
900However, to keep backward compatibility to a certain extent, the
901default value for c-default-style now specifies the "java" style for
902java-mode, but "gnu" for all other modes (as before). So you won't
903notice the change if you haven't touched that variable.
904
905*** New cleanups, space-before-funcall and compact-empty-funcall.
906Two new cleanups have been added to c-cleanup-list:
907
908space-before-funcall causes a space to be inserted before the opening
909parenthesis of a function call, which gives the style "foo (bar)".
910
911compact-empty-funcall causes any space before a function call opening
912parenthesis to be removed if there are no arguments to the function.
913It's typically useful together with space-before-funcall to get the
914style "foo (bar)" and "foo()".
915
916*** Some keywords now automatically trigger reindentation.
917Keywords like "else", "while", "catch" and "finally" have been made
918"electric" to make them reindent automatically when they continue an
919earlier statement. An example:
920
921for (i = 0; i < 17; i++)
922 if (a[i])
923 res += a[i]->offset;
924else
925
926Here, the "else" should be indented like the preceding "if", since it
927continues that statement. CC Mode will automatically reindent it after
928the "else" has been typed in full, since it's not until then it's
929possible to decide whether it's a new statement or a continuation of
930the preceding "if".
931
932CC Mode uses Abbrev mode to achieve this, which is therefore turned on
933by default.
934
935*** M-a and M-e now moves by sentence in multiline strings.
936Previously these two keys only moved by sentence in comments, which
937meant that sentence movement didn't work in strings containing
938documentation or other natural language text.
939
940The reason it's only activated in multiline strings (i.e. strings that
941contain a newline, even when escaped by a '\') is to avoid stopping in
942the short strings that often reside inside statements. Multiline
943strings almost always contain text in a natural language, as opposed
944to other strings that typically contain format specifications,
945commands, etc. Also, it's not that bothersome that M-a and M-e misses
946sentences in single line strings, since they're short anyway.
947
948*** Support for autodoc comments in Pike mode.
949Autodoc comments for Pike are used to extract documentation from the
950source, like Javadoc in Java. Pike mode now recognize this markup in
951comment prefixes and paragraph starts.
952
953*** The comment prefix regexps on c-comment-prefix may be mode specific.
954When c-comment-prefix is an association list, it specifies the comment
955line prefix on a per-mode basis, like c-default-style does. This
956change came about to support the special autodoc comment prefix in
957Pike mode only.
958
959*** Better handling of syntactic errors.
960The recovery after unbalanced parens earlier in the buffer has been
961improved; CC Mode now reports them by dinging and giving a message
962stating the offending line, but still recovers and indent the
963following lines in a sane way (most of the time). An "else" with no
964matching "if" is handled similarly. If an error is discovered while
965indenting a region, the whole region is still indented and the error
966is reported afterwards.
967
968*** Lineup functions may now return absolute columns.
969A lineup function can give an absolute column to indent the line to by
970returning a vector with the desired column as the first element.
971
972*** More robust and warning-free byte compilation.
973Although this is strictly not a user visible change (well, depending
974on the view of a user), it's still worth mentioning that CC Mode now
975can be compiled in the standard ways without causing trouble. Some
976code have also been moved between the subpackages to enhance the
977modularity somewhat. Thanks to Martin Buchholz for doing the
978groundwork.
979
980*** c-style-variables-are-local-p now defaults to t.
981This is an incompatible change that has been made to make the behavior
982of the style system wrt global variable settings less confusing for
983non-advanced users. If you know what this variable does you might
984want to set it to nil in your .emacs, otherwise you probably don't
985have to bother.
986
987Defaulting c-style-variables-are-local-p to t avoids the confusing
988situation that occurs when a user sets some style variables globally
989and edits both a Java and a non-Java file in the same Emacs session.
990If the style variables aren't buffer local in this case, loading of
991the second file will cause the default style (either "gnu" or "java"
992by default) to override the global settings made by the user.
993
994*** New initialization procedure for the style system.
995When the initial style for a buffer is determined by CC Mode (from the
996variable c-default-style), the global values of style variables now
997take precedence over the values specified by the chosen style. This
998is different than the old behavior: previously, the style-specific
999settings would override the global settings. This change makes it
1000possible to do simple configuration in the intuitive way with
1001Customize or with setq lines in one's .emacs file.
1002
1003By default, the global value of every style variable is the new
1004special symbol set-from-style, which causes the value to be taken from
1005the style system. This means that in effect, only an explicit setting
1006of a style variable will cause the "overriding" behavior described
1007above.
1008
1009Also note that global settings override style-specific settings *only*
1010when the initial style of a buffer is chosen by a CC Mode major mode
1011function. When a style is chosen in other ways --- for example, by a
1012call like (c-set-style "gnu") in a hook, or via M-x c-set-style ---
1013then the style-specific values take precedence over any global style
1014values. In Lisp terms, global values override style-specific values
1015only when the new second argument to c-set-style is non-nil; see the
1016function documentation for more info.
1017
1018The purpose of these changes is to make it easier for users,
1019especially novice users, to do simple customizations with Customize or
1020with setq in their .emacs files. On the other hand, the new system is
1021intended to be compatible with advanced users' customizations as well,
1022such as those that choose styles in hooks or whatnot. This new system
1023is believed to be almost entirely compatible with current
1024configurations, in spite of the changed precedence between style and
1025global variable settings when a buffer's default style is set.
1026
1027(Thanks to Eric Eide for clarifying this explanation a bit.)
1028
1029**** c-offsets-alist is now a customizable variable.
1030This became possible as a result of the new initialization behavior.
1031
1032This variable is treated slightly differently from the other style
1033variables; instead of using the symbol set-from-style, it will be
1034completed with the syntactic symbols it doesn't already contain when
1035the style is first initialized. This means it now defaults to the
1036empty list to make all syntactic elements get their values from the
1037style system.
1038
1039**** Compatibility variable to restore the old behavior.
1040In case your configuration doesn't work with this change, you can set
1041c-old-style-variable-behavior to non-nil to get the old behavior back
1042as far as possible.
1043
1044*** Improvements to line breaking and text filling.
1045CC Mode now handles this more intelligently and seamlessly wrt the
1046surrounding code, especially inside comments. For details see the new
1047chapter about this in the manual.
1048
1049**** New variable to recognize comment line prefix decorations.
1050The variable c-comment-prefix-regexp has been added to properly
1051recognize the line prefix in both block and line comments. It's
1052primarily used to initialize the various paragraph recognition and
1053adaptive filling variables that the text handling functions uses.
1054
1055**** New variable c-block-comment-prefix.
1056This is a generalization of the now obsolete variable
1057c-comment-continuation-stars to handle arbitrary strings.
1058
1059**** CC Mode now uses adaptive fill mode.
1060This to make it adapt better to the paragraph style inside comments.
1061
1062It's also possible to use other adaptive filling packages inside CC
1063Mode, notably Kyle E. Jones' Filladapt mode (http://wonderworks.com/).
1064A new convenience function c-setup-filladapt sets up Filladapt for use
1065inside CC Mode.
1066
1067Note though that the 2.12 version of Filladapt lacks a feature that
1068causes it to work suboptimally when c-comment-prefix-regexp can match
1069the empty string (which it commonly does). A patch for that is
1070available from the CC Mode web site (http://www.python.org/emacs/
1071cc-mode/).
1072
1073**** The variables `c-hanging-comment-starter-p' and
1074`c-hanging-comment-ender-p', which controlled how comment starters and
1075enders were filled, are not used anymore. The new version of the
1076function `c-fill-paragraph' keeps the comment starters and enders as
1077they were before the filling.
1078
1079**** It's now possible to selectively turn off auto filling.
1080The variable c-ignore-auto-fill is used to ignore auto fill mode in
1081specific contexts, e.g. in preprocessor directives and in string
1082literals.
1083
1084**** New context sensitive line break function c-context-line-break.
1085It works like newline-and-indent in normal code, and adapts the line
1086prefix according to the comment style when used inside comments. If
1087you're normally using newline-and-indent, you might want to switch to
1088this function.
1089
1090*** Fixes to IDL mode.
1091It now does a better job in recognizing only the constructs relevant
1092to IDL. E.g. it no longer matches "class" as the beginning of a
1093struct block, but it does match the CORBA 2.3 "valuetype" keyword.
1094Thanks to Eric Eide.
1095
1096*** Improvements to the Whitesmith style.
1097It now keeps the style consistently on all levels and both when
1098opening braces hangs and when they don't.
1099
1100**** New lineup function c-lineup-whitesmith-in-block.
1101
1102*** New lineup functions c-lineup-template-args and c-indent-multi-line-block.
1103See their docstrings for details. c-lineup-template-args does a
1104better job of tracking the brackets used as parens in C++ templates,
1105and is used by default to line up continued template arguments.
1106
1107*** c-lineup-comment now preserves alignment with a comment on the
1108previous line. It used to instead preserve comments that started in
1109the column specified by comment-column.
1110
1111*** c-lineup-C-comments handles "free form" text comments.
1112In comments with a long delimiter line at the start, the indentation
1113is kept unchanged for lines that start with an empty comment line
1114prefix. This is intended for the type of large block comments that
1115contain documentation with its own formatting. In these you normally
1116don't want CC Mode to change the indentation.
1117
1118*** The `c' syntactic symbol is now relative to the comment start
1119instead of the previous line, to make integers usable as lineup
1120arguments.
1121
1122*** All lineup functions have gotten docstrings.
1123
1124*** More preprocessor directive movement functions.
1125c-down-conditional does the reverse of c-up-conditional.
1126c-up-conditional-with-else and c-down-conditional-with-else are
1127variants of these that also stops at "#else" lines (suggested by Don
1128Provan).
1129
1130*** Minor improvements to many movement functions in tricky situations.
1131
1132** Dired changes
1133
1134*** New variable `dired-recursive-deletes' determines if the delete
1135command will delete non-empty directories recursively. The default
1136is, delete only empty directories.
1137
1138*** New variable `dired-recursive-copies' determines if the copy
1139command will copy directories recursively. The default is, do not
1140copy directories recursively.
1141
1142*** In command `dired-do-shell-command' (usually bound to `!') a `?'
1143in the shell command has a special meaning similar to `*', but with
1144the difference that the command will be run on each file individually.
1145
1146*** The new command `dired-find-alternate-file' (usually bound to `a')
1147replaces the Dired buffer with the buffer for an alternate file or
1148directory.
1149
1150*** The new command `dired-show-file-type' (usually bound to `y') shows
1151a message in the echo area describing what type of file the point is on.
1152This command invokes the external program `file' do its work, and so
1153will only work on systems with that program, and will be only as
1154accurate or inaccurate as it is.
1155
1156*** Dired now properly handles undo changes of adding/removing `-R'
1157from ls switches.
1158
1159*** Dired commands that prompt for a destination file now allow the use
1160of the `M-n' command in the minibuffer to insert the source filename,
1161which the user can then edit. This only works if there is a single
1162source file, not when operating on multiple marked files.
1163
1164** Gnus changes.
1165
1166The Gnus NEWS entries are short, but they reflect sweeping changes in
1167four areas: Article display treatment, MIME treatment,
1168internationalization and mail-fetching.
1169
1170*** The mail-fetching functions have changed. See the manual for the
1171many details. In particular, all procmail fetching variables are gone.
1172
1173If you used procmail like in
1174
1175(setq nnmail-use-procmail t)
1176(setq nnmail-spool-file 'procmail)
1177(setq nnmail-procmail-directory "~/mail/incoming/")
1178(setq nnmail-procmail-suffix "\\.in")
1179
1180this now has changed to
1181
1182(setq mail-sources
1183 '((directory :path "~/mail/incoming/"
1184 :suffix ".in")))
1185
1186More information is available in the info doc at Select Methods ->
1187Getting Mail -> Mail Sources
1188
1189*** Gnus is now a MIME-capable reader. This affects many parts of
1190Gnus, and adds a slew of new commands. See the manual for details.
1191Separate MIME packages like RMIME, mime-compose etc., will probably no
1192longer work; remove them and use the native facilities.
1193
1194The FLIM/SEMI package still works with Emacs 21, but if you want to
1195use the native facilities, you must remove any mailcap.el[c] that was
1196installed by FLIM/SEMI version 1.13 or earlier.
1197
1198*** Gnus has also been multilingualized. This also affects too many
1199parts of Gnus to summarize here, and adds many new variables. There
1200are built-in facilities equivalent to those of gnus-mule.el, which is
1201now just a compatibility layer.
1202
1203*** gnus-mule.el is now just a compatibility layer over the built-in
1204Gnus facilities.
1205
1206*** gnus-auto-select-first can now be a function to be
1207called to position point.
1208
1209*** The user can now decide which extra headers should be included in
1210summary buffers and NOV files.
1211
1212*** `gnus-article-display-hook' has been removed. Instead, a number
1213of variables starting with `gnus-treat-' have been added.
1214
1215*** The Gnus posting styles have been redone again and now work in a
1216subtly different manner.
1217
1218*** New web-based backends have been added: nnslashdot, nnwarchive
1219and nnultimate. nnweb has been revamped, again, to keep up with
1220ever-changing layouts.
1221
1222*** Gnus can now read IMAP mail via nnimap.
1223
1224*** There is image support of various kinds and some sound support.
1225
1226** Changes in Texinfo mode.
1227
1228*** A couple of new key bindings have been added for inserting Texinfo
1229macros
1230
1231 Key binding Macro
1232 -------------------------
1233 C-c C-c C-s @strong
1234 C-c C-c C-e @emph
1235 C-c C-c u @uref
1236 C-c C-c q @quotation
1237 C-c C-c m @email
1238 C-c C-o @<block> ... @end <block>
1239 M-RET @item
1240
1241*** The " key now inserts either " or `` or '' depending on context.
1242
1243** Changes in Outline mode.
1244
1245There is now support for Imenu to index headings. A new command
1246`outline-headers-as-kill' copies the visible headings in the region to
1247the kill ring, e.g. to produce a table of contents.
1248
1249** Changes to Emacs Server
1250
1251*** The new option `server-kill-new-buffers' specifies what to do
1252with buffers when done with them. If non-nil, the default, buffers
1253are killed, unless they were already present before visiting them with
1254Emacs Server. If nil, `server-temp-file-regexp' specifies which
1255buffers to kill, as before.
1256
1257Please note that only buffers are killed that still have a client,
1258i.e. buffers visited with `emacsclient --no-wait' are never killed in
1259this way.
1260
1261** Both emacsclient and Emacs itself now accept command line options
1262of the form +LINE:COLUMN in addition to +LINE.
1263
1264** Changes to Show Paren mode.
1265
1266*** Overlays used by Show Paren mode now use a priority property.
1267The new user option show-paren-priority specifies the priority to
1268use. Default is 1000.
1269
1270** New command M-x check-parens can be used to find unbalanced paren
1271groups and strings in buffers in Lisp mode (or other modes).
1272
1273** Changes to hideshow.el
1274
1275*** Generalized block selection and traversal
1276
1277A block is now recognized by its start and end regexps (both strings),
1278and an integer specifying which sub-expression in the start regexp
1279serves as the place where a `forward-sexp'-like function can operate.
1280See the documentation of variable `hs-special-modes-alist'.
1281
1282*** During incremental search, if Hideshow minor mode is active,
1283hidden blocks are temporarily shown. The variable `hs-headline' can
1284be used in the mode line format to show the line at the beginning of
1285the open block.
1286
1287*** User option `hs-hide-all-non-comment-function' specifies a
1288function to be called at each top-level block beginning, instead of
1289the normal block-hiding function.
1290
1291*** The command `hs-show-region' has been removed.
1292
1293*** The key bindings have changed to fit the Emacs conventions,
1294roughly imitating those of Outline minor mode. Notably, the prefix
1295for all bindings is now `C-c @'. For details, see the documentation
1296for `hs-minor-mode'.
1297
1298*** The variable `hs-show-hidden-short-form' has been removed, and
1299hideshow.el now always behaves as if this variable were set to t.
1300
1301** Changes to Change Log mode and Add-Log functions
1302
1303*** If you invoke `add-change-log-entry' from a backup file, it makes
1304an entry appropriate for the file's parent. This is useful for making
1305log entries by comparing a version with deleted functions.
1306
1307**** New command M-x change-log-merge merges another log into the
1308current buffer.
1309
1310*** New command M-x change-log-redate fixes any old-style date entries
1311in a log file.
1312
1313*** Change Log mode now adds a file's version number to change log
1314entries if user-option `change-log-version-info-enabled' is non-nil.
1315Unless the file is under version control the search for a file's
1316version number is performed based on regular expressions from
1317`change-log-version-number-regexp-list' which can be customized.
1318Version numbers are only found in the first 10 percent of a file.
1319
1320*** Change Log mode now defines its own faces for font-lock highlighting.
1321
1322** Changes to cmuscheme
1323
1324*** The user-option `scheme-program-name' has been renamed
1325`cmuscheme-program-name' due to conflicts with xscheme.el.
1326
1327** Changes in Font Lock
1328
1329*** The new function `font-lock-remove-keywords' can be used to remove
1330font-lock keywords from the current buffer or from a specific major mode.
1331
1332*** Multi-line patterns are now supported. Modes using this, should
1333set font-lock-multiline to t in their font-lock-defaults.
1334
1335*** `font-lock-syntactic-face-function' allows major-modes to choose
1336the face used for each string/comment.
1337
1338*** A new standard face `font-lock-doc-face'.
1339Meant for Lisp docstrings, Javadoc comments and other "documentation in code".
1340
1341** Changes to Shell mode
1342
1343*** The `shell' command now accepts an optional argument to specify the buffer
1344to use, which defaults to "*shell*". When used interactively, a
1345non-default buffer may be specified by giving the `shell' command a
1346prefix argument (causing it to prompt for the buffer name).
1347
1348** Comint (subshell) changes
1349
1350These changes generally affect all modes derived from comint mode, which
1351include shell-mode, gdb-mode, scheme-interaction-mode, etc.
1352
1353*** Comint now by default interprets some carriage-control characters.
1354Comint now removes CRs from CR LF sequences, and treats single CRs and
1355BSs in the output in a way similar to a terminal (by deleting to the
1356beginning of the line, or deleting the previous character,
1357respectively). This is achieved by adding `comint-carriage-motion' to
1358the `comint-output-filter-functions' hook by default.
1359
1360*** By default, comint no longer uses the variable `comint-prompt-regexp'
1361to distinguish prompts from user-input. Instead, it notices which
1362parts of the text were output by the process, and which entered by the
1363user, and attaches `field' properties to allow emacs commands to use
1364this information. Common movement commands, notably beginning-of-line,
1365respect field boundaries in a fairly natural manner. To disable this
1366feature, and use the old behavior, customize the user option
1367`comint-use-prompt-regexp-instead-of-fields'.
1368
1369*** Comint now includes new features to send commands to running processes
1370and redirect the output to a designated buffer or buffers.
1371
1372*** The command M-x comint-redirect-send-command reads a command and
1373buffer name from the mini-buffer. The command is sent to the current
1374buffer's process, and its output is inserted into the specified buffer.
1375
1376The command M-x comint-redirect-send-command-to-process acts like
1377M-x comint-redirect-send-command but additionally reads the name of
1378the buffer whose process should be used from the mini-buffer.
1379
1380*** Packages based on comint now highlight user input and program prompts,
1381and support choosing previous input with mouse-2. To control these features,
1382see the user-options `comint-highlight-input' and `comint-highlight-prompt'.
1383
1384*** The new command `comint-write-output' (usually bound to `C-c C-s')
1385saves the output from the most recent command to a file. With a prefix
1386argument, it appends to the file.
1387
1388*** The command `comint-kill-output' has been renamed `comint-delete-output'
1389(usually bound to `C-c C-o'); the old name is aliased to it for
1390compatibility.
1391
1392*** The new function `comint-add-to-input-history' adds commands to the input
1393ring (history).
1394
1395*** The new variable `comint-input-history-ignore' is a regexp for
1396identifying history lines that should be ignored, like tcsh time-stamp
1397strings, starting with a `#'. The default value of this variable is "^#".
1398
1399** Changes to Rmail mode
1400
1401*** The new user-option rmail-user-mail-address-regexp can be
1402set to fine tune the identification of the correspondent when
1403receiving new mail. If it matches the address of the sender, the
1404recipient is taken as correspondent of a mail. If nil, the default,
1405`user-login-name' and `user-mail-address' are used to exclude yourself
1406as correspondent.
1407
1408Usually you don't have to set this variable, except if you collect
1409mails sent by you under different user names. Then it should be a
1410regexp matching your mail addresses.
1411
1412*** The new user-option rmail-confirm-expunge controls whether and how
1413to ask for confirmation before expunging deleted messages from an
1414Rmail file. You can choose between no confirmation, confirmation
1415with y-or-n-p, or confirmation with yes-or-no-p. Default is to ask
1416for confirmation with yes-or-no-p.
1417
1418*** RET is now bound in the Rmail summary to rmail-summary-goto-msg,
1419like `j'.
1420
1421*** There is a new user option `rmail-digest-end-regexps' that
1422specifies the regular expressions to detect the line that ends a
1423digest message.
1424
1425*** The new user option `rmail-automatic-folder-directives' specifies
1426in which folder to put messages automatically.
1427
1428*** The new function `rmail-redecode-body' allows to fix a message
1429with non-ASCII characters if Emacs happens to decode it incorrectly
1430due to missing or malformed "charset=" header.
1431
1432** The new user-option `mail-envelope-from' can be used to specify
1433an envelope-from address different from user-mail-address.
1434
1435** The variable mail-specify-envelope-from controls whether to
1436use the -f option when sending mail.
1437
1438** The Rmail command `o' (`rmail-output-to-rmail-file') now writes the
1439current message in the internal `emacs-mule' encoding, rather than in
1440the encoding taken from the variable `buffer-file-coding-system'.
1441This allows to save messages whose characters cannot be safely encoded
1442by the buffer's coding system, and makes sure the message will be
1443displayed correctly when you later visit the target Rmail file.
1444
1445If you want your Rmail files be encoded in a specific coding system
1446other than `emacs-mule', you can customize the variable
1447`rmail-file-coding-system' to set its value to that coding system.
1448
1449** Changes to TeX mode
1450
1451*** The default mode has been changed from `plain-tex-mode' to
1452`latex-mode'.
1453
1454*** latex-mode now has a simple indentation algorithm.
1455
1456*** M-f and M-p jump around \begin...\end pairs.
1457
1458*** Added support for outline-minor-mode.
1459
1460** Changes to RefTeX mode
1461
1462*** RefTeX has new support for index generation. Index entries can be
1463 created with `C-c <', with completion available on index keys.
1464 Pressing `C-c /' indexes the word at the cursor with a default
1465 macro. `C-c >' compiles all index entries into an alphabetically
1466 sorted *Index* buffer which looks like the final index. Entries
1467 can be edited from that buffer.
1468
1469*** Label and citation key selection now allow to select several
1470 items and reference them together (use `m' to mark items, `a' or
1471 `A' to use all marked entries).
1472
1473*** reftex.el has been split into a number of smaller files to reduce
1474 memory use when only a part of RefTeX is being used.
1475
1476*** a new command `reftex-view-crossref-from-bibtex' (bound to `C-c &'
1477 in BibTeX-mode) can be called in a BibTeX database buffer in order
1478 to show locations in LaTeX documents where a particular entry has
1479 been cited.
1480
1481** Emacs Lisp mode now allows multiple levels of outline headings.
1482The level of a heading is determined from the number of leading
1483semicolons in a heading line. Toplevel forms starting with a `('
1484in column 1 are always made leaves.
1485
1486** The M-x time-stamp command (most commonly used on write-file-hooks)
1487has the following new features:
1488
1489*** The patterns for finding the time stamp and for updating a pattern
1490may match text spanning multiple lines. For example, some people like
1491to have the filename and date on separate lines. The new variable
1492time-stamp-inserts-lines controls the matching for multi-line patterns.
1493
1494*** More than one time stamp can be updated in the same file. This
1495feature is useful if you need separate time stamps in a program source
1496file to both include in formatted documentation and insert in the
1497compiled binary. The same time-stamp will be written at each matching
1498pattern. The variable time-stamp-count enables this new feature; it
1499defaults to 1.
1500
1501** Partial Completion mode now completes environment variables in
1502file names.
1503
1504** Ispell changes
1505
1506*** The command `ispell' now spell-checks a region if
1507transient-mark-mode is on, and the mark is active. Otherwise it
1508spell-checks the current buffer.
1509
1510*** Support for synchronous subprocesses - DOS/Windoze - has been
1511added.
1512
1513*** An "alignment error" bug was fixed when a manual spelling
1514correction is made and re-checked.
1515
1516*** Italian, Portuguese, and Slovak dictionary definitions have been added.
1517
1518*** Region skipping performance has been vastly improved in some
1519cases.
1520
1521*** Spell checking HTML buffers has been improved and isn't so strict
1522on syntax errors.
1523
1524*** The buffer-local words are now always placed on a new line at the
1525end of the buffer.
1526
1527*** Spell checking now works in the MS-DOS version of Emacs.
1528
1529*** The variable `ispell-format-word' has been renamed to
1530`ispell-format-word-function'. The old name is still available as
1531alias.
1532
1533** Makefile mode changes
1534
1535*** The mode now uses the abbrev table `makefile-mode-abbrev-table'.
1536
1537*** Conditionals and include statements are now highlighted when
1538Fontlock mode is active.
1539
1540** Isearch changes
1541
1542*** Isearch now puts a call to `isearch-resume' in the command history,
1543so that searches can be resumed.
1544
1545*** In Isearch mode, C-M-s and C-M-r are now bound like C-s and C-r,
1546respectively, i.e. you can repeat a regexp isearch with the same keys
1547that started the search.
1548
1549*** In Isearch mode, mouse-2 in the echo area now yanks the current
1550selection into the search string rather than giving an error.
1551
1552*** There is a new lazy highlighting feature in incremental search.
1553
1554Lazy highlighting is switched on/off by customizing variable
1555`isearch-lazy-highlight'. When active, all matches for the current
1556search string are highlighted. The current match is highlighted as
1557before using face `isearch' or `region'. All other matches are
1558highlighted using face `isearch-lazy-highlight-face' which defaults to
1559`secondary-selection'.
1560
1561The extra highlighting makes it easier to anticipate where the cursor
1562will end up each time you press C-s or C-r to repeat a pending search.
1563Highlighting of these additional matches happens in a deferred fashion
1564using "idle timers," so the cycles needed do not rob isearch of its
1565usual snappy response.
1566
1567If `isearch-lazy-highlight-cleanup' is set to t, highlights for
1568matches are automatically cleared when you end the search. If it is
1569set to nil, you can remove the highlights manually with `M-x
1570isearch-lazy-highlight-cleanup'.
1571
1572** VC Changes
1573
1574VC has been overhauled internally. It is now modular, making it
1575easier to plug-in arbitrary version control backends. (See Lisp
1576Changes for details on the new structure.) As a result, the mechanism
1577to enable and disable support for particular version systems has
1578changed: everything is now controlled by the new variable
1579`vc-handled-backends'. Its value is a list of symbols that identify
1580version systems; the default is '(RCS CVS SCCS). When finding a file,
1581each of the backends in that list is tried in order to see whether the
1582file is registered in that backend.
1583
1584When registering a new file, VC first tries each of the listed
1585backends to see if any of them considers itself "responsible" for the
1586directory of the file (e.g. because a corresponding subdirectory for
1587master files exists). If none of the backends is responsible, then
1588the first backend in the list that could register the file is chosen.
1589As a consequence, the variable `vc-default-back-end' is now obsolete.
1590
1591The old variable `vc-master-templates' is also obsolete, although VC
1592still supports it for backward compatibility. To define templates for
1593RCS or SCCS, you should rather use the new variables
1594vc-{rcs,sccs}-master-templates. (There is no such feature under CVS
1595where it doesn't make sense.)
1596
1597The variables `vc-ignore-vc-files' and `vc-handle-cvs' are also
1598obsolete now, you must set `vc-handled-backends' to nil or exclude
1599`CVS' from the list, respectively, to achieve their effect now.
1600
1601*** General Changes
1602
1603The variable `vc-checkout-carefully' is obsolete: the corresponding
1604checks are always done now.
1605
1606VC Dired buffers are now kept up-to-date during all version control
1607operations.
1608
1609`vc-diff' output is now displayed in `diff-mode'.
1610`vc-print-log' uses `log-view-mode'.
1611`vc-log-mode' (used for *VC-Log*) has been replaced by `log-edit-mode'.
1612
1613The command C-x v m (vc-merge) now accepts an empty argument as the
1614first revision number. This means that any recent changes on the
1615current branch should be picked up from the repository and merged into
1616the working file (``merge news'').
1617
1618The commands C-x v s (vc-create-snapshot) and C-x v r
1619(vc-retrieve-snapshot) now ask for a directory name from which to work
1620downwards.
1621
1622*** Multiple Backends
1623
1624VC now lets you register files in more than one backend. This is
1625useful, for example, if you are working with a slow remote CVS
1626repository. You can then use RCS for local editing, and occasionally
1627commit your changes back to CVS, or pick up changes from CVS into your
1628local RCS archives.
1629
1630To make this work, the ``more local'' backend (RCS in our example)
1631should come first in `vc-handled-backends', and the ``more remote''
1632backend (CVS) should come later. (The default value of
1633`vc-handled-backends' already has it that way.)
1634
1635You can then commit changes to another backend (say, RCS), by typing
1636C-u C-x v v RCS RET (i.e. vc-next-action now accepts a backend name as
1637a revision number). VC registers the file in the more local backend
1638if that hasn't already happened, and commits to a branch based on the
1639current revision number from the more remote backend.
1640
1641If a file is registered in multiple backends, you can switch to
1642another one using C-x v b (vc-switch-backend). This does not change
1643any files, it only changes VC's perspective on the file. Use this to
1644pick up changes from CVS while working under RCS locally.
1645
1646After you are done with your local RCS editing, you can commit your
1647changes back to CVS using C-u C-x v v CVS RET. In this case, the
1648local RCS archive is removed after the commit, and the log entry
1649buffer is initialized to contain the entire RCS change log of the file.
1650
1651*** Changes for CVS
1652
1653There is a new user option, `vc-cvs-stay-local'. If it is `t' (the
1654default), then VC avoids network queries for files registered in
1655remote repositories. The state of such files is then only determined
1656by heuristics and past information. `vc-cvs-stay-local' can also be a
1657regexp to match against repository hostnames; only files from hosts
1658that match it are treated locally. If the variable is nil, then VC
1659queries the repository just as often as it does for local files.
1660
1661If `vc-cvs-stay-local' is on, then VC also makes local backups of
1662repository versions. This means that ordinary diffs (C-x v =) and
1663revert operations (C-x v u) can be done completely locally, without
1664any repository interactions at all. The name of a local version
1665backup of FILE is FILE.~REV.~, where REV is the repository version
1666number. This format is similar to that used by C-x v ~
1667(vc-version-other-window), except for the trailing dot. As a matter
1668of fact, the two features can each use the files created by the other,
1669the only difference being that files with a trailing `.' are deleted
1670automatically after commit. (This feature doesn't work on MS-DOS,
1671since DOS disallows more than a single dot in the trunk of a file
1672name.)
1673
1674If `vc-cvs-stay-local' is on, and there have been changes in the
1675repository, VC notifies you about it when you actually try to commit.
1676If you want to check for updates from the repository without trying to
1677commit, you can either use C-x v m RET to perform an update on the
1678current file, or you can use C-x v r RET to get an update for an
1679entire directory tree.
1680
1681The new user option `vc-cvs-use-edit' indicates whether VC should call
1682"cvs edit" to make files writeable; it defaults to `t'. (This option
1683is only meaningful if the CVSREAD variable is set, or if files are
1684"watched" by other developers.)
1685
1686The commands C-x v s (vc-create-snapshot) and C-x v r
1687(vc-retrieve-snapshot) are now also implemented for CVS. If you give
1688an empty snapshot name to the latter, that performs a `cvs update',
1689starting at the given directory.
1690
1691*** Lisp Changes in VC
1692
1693VC has been restructured internally to make it modular. You can now
1694add support for arbitrary version control backends by writing a
1695library that provides a certain set of backend-specific functions, and
1696then telling VC to use that library. For example, to add support for
1697a version system named SYS, you write a library named vc-sys.el, which
1698provides a number of functions vc-sys-... (see commentary at the top
1699of vc.el for a detailed list of them). To make VC use that library,
1700you need to put it somewhere into Emacs' load path and add the symbol
1701`SYS' to the list `vc-handled-backends'.
1702
1703** The customizable EDT emulation package now supports the EDT
1704SUBS command and EDT scroll margins. It also works with more
1705terminal/keyboard configurations and it now works under XEmacs.
1706See etc/edt-user.doc for more information.
1707
1708** New modes and packages
1709
1710*** The new global minor mode `minibuffer-electric-default-mode'
1711automatically hides the `(default ...)' part of minibuffer prompts when
1712the default is not applicable.
1713
1714*** Artist is an Emacs lisp package that allows you to draw lines,
1715rectangles and ellipses by using your mouse and/or keyboard. The
1716shapes are made up with the ascii characters |, -, / and \.
1717
1718Features are:
1719
1720- Intersecting: When a `|' intersects with a `-', a `+' is
1721 drawn, like this: | \ /
1722 --+-- X
1723 | / \
1724
1725- Rubber-banding: When drawing lines you can interactively see the
1726 result while holding the mouse button down and moving the mouse. If
1727 your machine is not fast enough (a 386 is a bit too slow, but a
1728 pentium is well enough), you can turn this feature off. You will
1729 then see 1's and 2's which mark the 1st and 2nd endpoint of the line
1730 you are drawing.
1731
1732- Arrows: After having drawn a (straight) line or a (straight)
1733 poly-line, you can set arrows on the line-ends by typing < or >.
1734
1735- Flood-filling: You can fill any area with a certain character by
1736 flood-filling.
1737
1738- Cut copy and paste: You can cut, copy and paste rectangular
1739 regions. Artist also interfaces with the rect package (this can be
1740 turned off if it causes you any trouble) so anything you cut in
1741 artist can be yanked with C-x r y and vice versa.
1742
1743- Drawing with keys: Everything you can do with the mouse, you can
1744 also do without the mouse.
1745
1746- Aspect-ratio: You can set the variable artist-aspect-ratio to
1747 reflect the height-width ratio for the font you are using. Squares
1748 and circles are then drawn square/round. Note, that once your
1749 ascii-file is shown with font with a different height-width ratio,
1750 the squares won't be square and the circles won't be round.
1751
1752- Drawing operations: The following drawing operations are implemented:
1753
1754 lines straight-lines
1755 rectangles squares
1756 poly-lines straight poly-lines
1757 ellipses circles
1758 text (see-thru) text (overwrite)
1759 spray-can setting size for spraying
1760 vaporize line vaporize lines
1761 erase characters erase rectangles
1762
1763 Straight lines are lines that go horizontally, vertically or
1764 diagonally. Plain lines go in any direction. The operations in
1765 the right column are accessed by holding down the shift key while
1766 drawing.
1767
1768 It is possible to vaporize (erase) entire lines and connected lines
1769 (rectangles for example) as long as the lines being vaporized are
1770 straight and connected at their endpoints. Vaporizing is inspired
1771 by the drawrect package by Jari Aalto <jari.aalto@poboxes.com>.
1772
1773- Picture mode compatibility: Artist is picture mode compatible (this
1774 can be turned off).
1775
1776*** The new package Eshell is an operating system command shell
1777implemented entirely in Emacs Lisp. Use `M-x eshell' to invoke it.
1778It functions similarly to bash and zsh, and allows running of Lisp
1779functions and external commands using the same syntax. It supports
1780history lists, aliases, extended globbing, smart scrolling, etc. It
1781will work on any platform Emacs has been ported to. And since most of
1782the basic commands -- ls, rm, mv, cp, ln, du, cat, etc. -- have been
1783rewritten in Lisp, it offers an operating-system independent shell,
1784all within the scope of your Emacs process.
1785
1786*** The new package timeclock.el is a mode is for keeping track of time
1787intervals. You can use it for whatever purpose you like, but the
1788typical scenario is to keep track of how much time you spend working
1789on certain projects.
1790
1791*** The new package hi-lock.el provides commands to highlight matches
1792of interactively entered regexps. For example,
1793
1794 M-x highlight-regexp RET clearly RET RET
1795
1796will highlight all occurrences of `clearly' using a yellow background
1797face. New occurrences of `clearly' will be highlighted as they are
1798typed. `M-x unhighlight-regexp RET' will remove the highlighting.
1799Any existing face can be used for highlighting and a set of
1800appropriate faces is provided. The regexps can be written into the
1801current buffer in a form that will be recognized the next time the
1802corresponding file is read. There are commands to highlight matches
1803to phrases and to highlight entire lines containing a match.
1804
1805*** The new package zone.el plays games with Emacs' display when
1806Emacs is idle.
1807
1808*** The new package tildify.el allows to add hard spaces or other text
1809fragments in accordance with the current major mode.
1810
1811*** The new package xml.el provides a simple but generic XML
1812parser. It doesn't parse the DTDs however.
1813
1814*** The comment operations are now provided by the newcomment.el
1815package which allows different styles of comment-region and should
1816be more robust while offering the same functionality.
1817`comment-region' now doesn't always comment a-line-at-a-time, but only
1818comments the region, breaking the line at point if necessary.
1819
1820*** The Ebrowse package implements a C++ class browser and tags
1821facilities tailored for use with C++. It is documented in a
1822separate Texinfo file.
1823
1824*** The PCL-CVS package available by either running M-x cvs-examine or
1825by visiting a CVS administrative directory (with a prefix argument)
1826provides an alternative interface to VC-dired for CVS. It comes with
1827`log-view-mode' to view RCS and SCCS logs and `log-edit-mode' used to
1828enter check-in log messages.
1829
1830*** The new package called `woman' allows to browse Unix man pages
1831without invoking external programs.
1832
1833The command `M-x woman' formats manual pages entirely in Emacs Lisp
1834and then displays them, like `M-x manual-entry' does. Unlike
1835`manual-entry', `woman' does not invoke any external programs, so it
1836is useful on systems such as MS-DOS/MS-Windows where the `man' and
1837Groff or `troff' commands are not readily available.
1838
1839The command `M-x woman-find-file' asks for the file name of a man
1840page, then formats and displays it like `M-x woman' does.
1841
1842*** The new command M-x re-builder offers a convenient interface for
1843authoring regular expressions with immediate visual feedback.
1844
1845The buffer from which the command was called becomes the target for
1846the regexp editor popping up in a separate window. Matching text in
1847the target buffer is immediately color marked during the editing.
1848Each sub-expression of the regexp will show up in a different face so
1849even complex regexps can be edited and verified on target data in a
1850single step.
1851
1852On displays not supporting faces the matches instead blink like
1853matching parens to make them stand out. On such a setup you will
1854probably also want to use the sub-expression mode when the regexp
1855contains such to get feedback about their respective limits.
1856
1857*** glasses-mode is a minor mode that makes
1858unreadableIdentifiersLikeThis readable. It works as glasses, without
1859actually modifying content of a buffer.
1860
1861*** The package ebnf2ps translates an EBNF to a syntactic chart in
1862PostScript.
1863
1864Currently accepts ad-hoc EBNF, ISO EBNF and Bison/Yacc.
1865
1866The ad-hoc default EBNF syntax has the following elements:
1867
1868 ; comment (until end of line)
1869 A non-terminal
1870 "C" terminal
1871 ?C? special
1872 $A default non-terminal
1873 $"C" default terminal
1874 $?C? default special
1875 A = B. production (A is the header and B the body)
1876 C D sequence (C occurs before D)
1877 C | D alternative (C or D occurs)
1878 A - B exception (A excluding B, B without any non-terminal)
1879 n * A repetition (A repeats n (integer) times)
1880 (C) group (expression C is grouped together)
1881 [C] optional (C may or not occurs)
1882 C+ one or more occurrences of C
1883 {C}+ one or more occurrences of C
1884 {C}* zero or more occurrences of C
1885 {C} zero or more occurrences of C
1886 C / D equivalent to: C {D C}*
1887 {C || D}+ equivalent to: C {D C}*
1888 {C || D}* equivalent to: [C {D C}*]
1889 {C || D} equivalent to: [C {D C}*]
1890
1891Please, see ebnf2ps documentation for EBNF syntax and how to use it.
1892
1893*** The package align.el will align columns within a region, using M-x
1894align. Its mode-specific rules, based on regular expressions,
1895determine where the columns should be split. In C and C++, for
1896example, it will align variable names in declaration lists, or the
1897equal signs of assignments.
1898
1899*** `paragraph-indent-minor-mode' is a new minor mode supporting
1900paragraphs in the same style as `paragraph-indent-text-mode'.
1901
1902*** bs.el is a new package for buffer selection similar to
1903list-buffers or electric-buffer-list. Use M-x bs-show to display a
1904buffer menu with this package. See the Custom group `bs'.
1905
1906*** find-lisp.el is a package emulating the Unix find command in Lisp.
1907
1908*** calculator.el is a small calculator package that is intended to
1909replace desktop calculators such as xcalc and calc.exe. Actually, it
1910is not too small - it has more features than most desktop calculators,
1911and can be customized easily to get many more functions. It should
1912not be confused with "calc" which is a much bigger mathematical tool
1913which answers different needs.
1914
1915*** The minor modes cwarn-mode and global-cwarn-mode highlights
1916suspicious C and C++ constructions. Currently, assignments inside
1917expressions, semicolon following `if', `for' and `while' (except, of
1918course, after a `do .. while' statement), and C++ functions with
1919reference parameters are recognized. The modes require font-lock mode
1920to be enabled.
1921
1922*** smerge-mode.el provides `smerge-mode', a simple minor-mode for files
1923containing diff3-style conflict markers, such as generated by RCS.
1924
1925*** 5x5.el is a simple puzzle game.
1926
1927*** hl-line.el provides `hl-line-mode', a minor mode to highlight the
1928current line in the current buffer. It also provides
1929`global-hl-line-mode' to provide the same behavior in all buffers.
1930
1931*** ansi-color.el translates ANSI terminal escapes into text-properties.
1932
1933Please note: if `ansi-color-for-comint-mode' and
1934`global-font-lock-mode' are non-nil, loading ansi-color.el will
1935disable font-lock and add `ansi-color-apply' to
1936`comint-preoutput-filter-functions' for all shell-mode buffers. This
1937displays the output of "ls --color=yes" using the correct foreground
1938and background colors.
1939
1940*** delphi.el provides a major mode for editing the Delphi (Object
1941Pascal) language.
1942
1943*** quickurl.el provides a simple method of inserting a URL based on
1944the text at point.
1945
1946*** sql.el provides an interface to SQL data bases.
1947
1948*** fortune.el uses the fortune program to create mail/news signatures.
1949
1950*** whitespace.el is a package for warning about and cleaning bogus
1951whitespace in a file.
1952
1953*** PostScript mode (ps-mode) is a new major mode for editing PostScript
1954files. It offers: interaction with a PostScript interpreter, including
1955(very basic) error handling; fontification, easily customizable for
1956interpreter messages; auto-indentation; insertion of EPSF templates and
1957often used code snippets; viewing of BoundingBox; commenting out /
1958uncommenting regions; conversion of 8bit characters to PostScript octal
1959codes. All functionality is accessible through a menu.
1960
1961*** delim-col helps to prettify columns in a text region or rectangle.
1962
1963Here is an example of columns:
1964
1965horse apple bus
1966dog pineapple car EXTRA
1967porcupine strawberry airplane
1968
1969Doing the following settings:
1970
1971 (setq delimit-columns-str-before "[ ")
1972 (setq delimit-columns-str-after " ]")
1973 (setq delimit-columns-str-separator ", ")
1974 (setq delimit-columns-separator "\t")
1975
1976
1977Selecting the lines above and typing:
1978
1979 M-x delimit-columns-region
1980
1981It results:
1982
1983[ horse , apple , bus , ]
1984[ dog , pineapple , car , EXTRA ]
1985[ porcupine, strawberry, airplane, ]
1986
1987delim-col has the following options:
1988
1989 delimit-columns-str-before Specify a string to be inserted
1990 before all columns.
1991
1992 delimit-columns-str-separator Specify a string to be inserted
1993 between each column.
1994
1995 delimit-columns-str-after Specify a string to be inserted
1996 after all columns.
1997
1998 delimit-columns-separator Specify a regexp which separates
1999 each column.
2000
2001delim-col has the following commands:
2002
2003 delimit-columns-region Prettify all columns in a text region.
2004 delimit-columns-rectangle Prettify all columns in a text rectangle.
2005
2006*** Recentf mode maintains a menu for visiting files that were
2007operated on recently. User option recentf-menu-filter specifies a
2008menu filter function to change the menu appearance. For example, the
2009recent file list can be displayed:
2010
2011- organized by major modes, directories or user defined rules.
2012- sorted by file paths, file names, ascending or descending.
2013- showing paths relative to the current default-directory
2014
2015The `recentf-filter-changer' menu filter function allows to
2016dynamically change the menu appearance.
2017
2018*** elide-head.el provides a mechanism for eliding boilerplate header
2019text.
2020
2021*** footnote.el provides `footnote-mode', a minor mode supporting use
2022of footnotes. It is intended for use with Message mode, but isn't
2023specific to Message mode.
2024
2025*** diff-mode.el provides `diff-mode', a major mode for
2026viewing/editing context diffs (patches). It is selected for files
2027with extension `.diff', `.diffs', `.patch' and `.rej'.
2028
2029*** EUDC, the Emacs Unified Directory Client, provides a common user
2030interface to access directory servers using different directory
2031protocols. It has a separate manual.
2032
2033*** autoconf.el provides a major mode for editing configure.in files
2034for Autoconf, selected automatically.
2035
2036*** windmove.el provides moving between windows.
2037
2038*** crm.el provides a facility to read multiple strings from the
2039minibuffer with completion.
2040
2041*** todo-mode.el provides management of TODO lists and integration
2042with the diary features.
2043
2044*** autoarg.el provides a feature reported from Twenex Emacs whereby
2045numeric keys supply prefix args rather than self inserting.
2046
2047*** The function `turn-off-auto-fill' unconditionally turns off Auto
2048Fill mode.
2049
2050*** pcomplete.el is a library that provides programmable completion
2051facilities for Emacs, similar to what zsh and tcsh offer. The main
2052difference is that completion functions are written in Lisp, meaning
2053they can be profiled, debugged, etc.
2054
2055*** antlr-mode is a new major mode for editing ANTLR grammar files.
2056It is automatically turned on for files whose names have the extension
2057`.g'.
2058
2059** Changes in sort.el
2060
2061The function sort-numeric-fields interprets numbers starting with `0'
2062as octal and numbers starting with `0x' or `0X' as hexadecimal. The
2063new user-option sort-numeric-base can be used to specify a default
2064numeric base.
2065
2066** Changes to Ange-ftp
2067
2068*** Ange-ftp allows you to specify of a port number in remote file
2069names cleanly. It is appended to the host name, separated by a hash
2070sign, e.g. `/foo@bar.org#666:mumble'. (This syntax comes from EFS.)
2071
2072*** If the new user-option `ange-ftp-try-passive-mode' is set, passive
2073ftp mode will be used if the ftp client supports that.
2074
2075*** Ange-ftp handles the output of the w32-style clients which
2076output ^M at the end of lines.
2077
2078** The recommended way of using Iswitchb is via the new global minor
2079mode `iswitchb-mode'.
2080
2081** Just loading the msb package doesn't switch on Msb mode anymore.
2082If you have `(require 'msb)' in your .emacs, please replace it with
2083`(msb-mode 1)'.
2084
2085** Changes in Flyspell mode
2086
2087*** Flyspell mode has various new options. See the `flyspell' Custom
2088group.
2089
2090*** The variable `flyspell-generic-check-word-p' has been renamed
2091to `flyspell-generic-check-word-predicate'. The old name is still
2092available as alias.
2093
2094** The user option `backward-delete-char-untabify-method' controls the
2095behavior of `backward-delete-char-untabify'. The following values
2096are recognized:
2097
2098`untabify' -- turn a tab to many spaces, then delete one space;
2099`hungry' -- delete all whitespace, both tabs and spaces;
2100`all' -- delete all whitespace, including tabs, spaces and newlines;
2101nil -- just delete one character.
2102
2103Default value is `untabify'.
2104
2105[This change was made in Emacs 20.3 but not mentioned then.]
2106
2107** In Cperl mode `cperl-invalid-face' should now be a normal face
2108symbol, not double-quoted.
2109
2110** Some packages are declared obsolete, to be removed in a future
2111version. They are: auto-show, c-mode, hilit19, hscroll, ooutline,
2112profile, rnews, rnewspost, and sc. Their implementations have been
2113moved to lisp/obsolete.
2114
2115** auto-compression mode is no longer enabled just by loading jka-compr.el.
2116To control it, set `auto-compression-mode' via Custom or use the
2117`auto-compression-mode' command.
2118
2119** `browse-url-gnome-moz' is a new option for
2120`browse-url-browser-function', invoking Mozilla in GNOME, and
2121`browse-url-kde' can be chosen for invoking the KDE browser.
2122
2123** The user-option `browse-url-new-window-p' has been renamed to
2124`browse-url-new-window-flag'.
2125
2126** The functions `keep-lines', `flush-lines' and `how-many' now
2127operate on the active region in Transient Mark mode.
2128
2129** `gnus-user-agent' is a new possibility for `mail-user-agent'. It
2130is like `message-user-agent', but with all the Gnus paraphernalia.
2131
2132** The Strokes package has been updated. If your Emacs has XPM
2133support, you can use it for pictographic editing. In Strokes mode,
2134use C-mouse-2 to compose a complex stoke and insert it into the
2135buffer. You can encode or decode a strokes buffer with new commands
2136M-x strokes-encode-buffer and M-x strokes-decode-buffer. There is a
2137new command M-x strokes-list-strokes.
2138
2139** Hexl contains a new command `hexl-insert-hex-string' which inserts
2140a string of hexadecimal numbers read from the mini-buffer.
2141
2142** Hexl mode allows to insert non-ASCII characters.
2143
2144The non-ASCII characters are encoded using the same encoding as the
2145file you are visiting in Hexl mode.
2146
2147** Shell script mode changes.
2148
2149Shell script mode (sh-script) can now indent scripts for shells
2150derived from sh and rc. The indentation style is customizable, and
2151sh-script can attempt to "learn" the current buffer's style.
2152
2153** Etags changes.
2154
2155*** In DOS, etags looks for file.cgz if it cannot find file.c.
2156
2157*** New option --ignore-case-regex is an alternative to --regex. It is now
2158possible to bind a regexp to a language, by prepending the regexp with
2159{lang}, where lang is one of the languages that `etags --help' prints out.
2160This feature is useful especially for regex files, where each line contains
2161a regular expression. The manual contains details.
2162
2163*** In C and derived languages, etags creates tags for function
2164declarations when given the --declarations option.
2165
2166*** In C++, tags are created for "operator". The tags have the form
2167"operator+", without spaces between the keyword and the operator.
2168
2169*** You shouldn't generally need any more the -C or -c++ option: etags
2170automatically switches to C++ parsing when it meets the `class' or
2171`template' keywords.
2172
2173*** Etags now is able to delve at arbitrary deeps into nested structures in
2174C-like languages. Previously, it was limited to one or two brace levels.
2175
2176*** New language Ada: tags are functions, procedures, packages, tasks, and
2177types.
2178
2179*** In Fortran, `procedure' is not tagged.
2180
2181*** In Java, tags are created for "interface".
2182
2183*** In Lisp, "(defstruct (foo", "(defun (operator" and similar constructs
2184are now tagged.
2185
2186*** In makefiles, tags the targets.
2187
2188*** In Perl, the --globals option tags global variables. my and local
2189variables are tagged.
2190
2191*** New language Python: def and class at the beginning of a line are tags.
2192
2193*** .ss files are Scheme files, .pdb is Postscript with C syntax, .psw is
2194for PSWrap.
2195
2196** Changes in etags.el
2197
2198*** The new user-option tags-case-fold-search can be used to make
2199tags operations case-sensitive or case-insensitive. The default
2200is to use the same setting as case-fold-search.
2201
2202*** You can display additional output with M-x tags-apropos by setting
2203the new variable tags-apropos-additional-actions.
2204
2205If non-nil, the variable's value should be a list of triples (TITLE
2206FUNCTION TO-SEARCH). For each triple, M-x tags-apropos processes
2207TO-SEARCH and lists tags from it. TO-SEARCH should be an alist,
2208obarray, or symbol. If it is a symbol, the symbol's value is used.
2209
2210TITLE is a string to use to label the list of tags from TO-SEARCH.
2211
2212FUNCTION is a function to call when an entry is selected in the Tags
2213List buffer. It is called with one argument, the selected symbol.
2214
2215A useful example value for this variable might be something like:
2216
2217 '(("Emacs Lisp" Info-goto-emacs-command-node obarray)
2218 ("Common Lisp" common-lisp-hyperspec common-lisp-hyperspec-obarray)
2219 ("SCWM" scwm-documentation scwm-obarray))
2220
2221*** The face tags-tag-face can be used to customize the appearance
2222of tags in the output of M-x tags-apropos.
2223
2224*** Setting tags-apropos-verbose to a non-nil value displays the
2225names of tags files in the *Tags List* buffer.
2226
2227*** You can now search for tags that are part of the filename itself.
2228If you have tagged the files topfile.c subdir/subfile.c
2229/tmp/tempfile.c, you can now search for tags "topfile.c", "subfile.c",
2230"dir/sub", "tempfile", "tempfile.c". If the tag matches the file name,
2231point will go to the beginning of the file.
2232
2233*** Compressed files are now transparently supported if
2234auto-compression-mode is active. You can tag (with Etags) and search
2235(with find-tag) both compressed and uncompressed files.
2236
2237*** Tags commands like M-x tags-search no longer change point
2238in buffers where no match is found. In buffers where a match is
2239found, the original value of point is pushed on the marker ring.
2240
2241** Fortran mode has a new command `fortran-strip-sequence-nos' to
2242remove text past column 72. The syntax class of `\' in Fortran is now
2243appropriate for C-style escape sequences in strings.
2244
2245** SGML mode's default `sgml-validate-command' is now `nsgmls'.
2246
2247** A new command `view-emacs-problems' (C-h P) displays the PROBLEMS file.
2248
2249** The Dabbrev package has a new user-option `dabbrev-ignored-regexps'
2250containing a list of regular expressions. Buffers matching a regular
2251expression from that list, are not checked.
2252
2253** Emacs can now figure out modification times of remote files.
2254When you do C-x C-f /user@host:/path/file RET and edit the file,
2255and someone else modifies the file, you will be prompted to revert
2256the buffer, just like for the local files.
2257
2258** The buffer menu (C-x C-b) no longer lists the *Buffer List* buffer.
2259
2260** When invoked with a prefix argument, the command `list-abbrevs' now
2261displays local abbrevs, only.
2262
2263** Refill minor mode provides preliminary support for keeping
2264paragraphs filled as you modify them.
2265
2266** The variable `double-click-fuzz' specifies how much the mouse
2267may be moved between clicks that are recognized as a pair. Its value
2268is measured in pixels.
2269
2270** The new global minor mode `auto-image-file-mode' allows image files
2271to be visited as images.
2272
2273** Two new user-options `grep-command' and `grep-find-command'
2274were added to compile.el.
2275
2276** Withdrawn packages
2277
2278*** mldrag.el has been removed. mouse.el provides the same
2279functionality with aliases for the mldrag functions.
2280
2281*** eval-reg.el has been obsoleted by changes to edebug.el and removed.
2282
2283*** ph.el has been obsoleted by EUDC and removed.
2284
2285\f
2286* Incompatible Lisp changes in 21.1
2287
2288There are a few Lisp changes which are not backwards-compatible and
2289may require changes to existing code. Here is a list for reference.
2290See the sections below for details.
2291
2292** Since `format' preserves text properties, the idiom
2293`(format "%s" foo)' no longer works to copy and remove properties.
2294Use `copy-sequence' to copy the string, then use `set-text-properties'
2295to remove the properties of the copy.
2296
2297** Since the `keymap' text property now has significance, some code
2298which uses both `local-map' and `keymap' properties (for portability)
2299may, for instance, give rise to duplicate menus when the keymaps from
2300these properties are active.
2301
2302** The change in the treatment of non-ASCII characters in search
2303ranges may affect some code.
2304
2305** A non-nil value for the LOCAL arg of add-hook makes the hook
2306buffer-local even if `make-local-hook' hasn't been called, which might
2307make a difference to some code.
2308
2309** The new treatment of the minibuffer prompt might affect code which
2310operates on the minibuffer.
2311
2312** The new character sets `eight-bit-control' and `eight-bit-graphic'
2313cause `no-conversion' and `emacs-mule-unix' coding systems to produce
2314different results when reading files with non-ASCII characters
2315(previously, both coding systems would produce the same results).
2316Specifically, `no-conversion' interprets each 8-bit byte as a separate
2317character. This makes `no-conversion' inappropriate for reading
2318multibyte text, e.g. buffers written to disk in their internal MULE
2319encoding (auto-saving does that, for example). If a Lisp program
2320reads such files with `no-conversion', each byte of the multibyte
2321sequence, including the MULE leading codes such as \201, is treated as
2322a separate character, which prevents them from being interpreted in
2323the buffer as multibyte characters.
2324
2325Therefore, Lisp programs that read files which contain the internal
2326MULE encoding should use `emacs-mule-unix'. `no-conversion' is only
2327appropriate for reading truly binary files.
2328
2329** Code that relies on the obsolete `before-change-function' and
2330`after-change-function' to detect buffer changes will now fail. Use
2331`before-change-functions' and `after-change-functions' instead.
2332
2333** Code that uses `concat' with integer args now gets an error, as
2334long promised. So does any code that uses derivatives of `concat',
2335such as `mapconcat'.
2336
2337** The function base64-decode-string now always returns a unibyte
2338string.
2339
2340** Not a Lisp incompatibility as such but, with the introduction of
2341extra private charsets, there is now only one slot free for a new
2342dimension-2 private charset. User code which tries to add more than
2343one extra will fail unless you rebuild Emacs with some standard
2344charset(s) removed; that is probably inadvisable because it changes
2345the emacs-mule encoding. Also, files stored in the emacs-mule
2346encoding using Emacs 20 with additional private charsets defined will
2347probably not be read correctly by Emacs 21.
2348
2349** The variable `directory-sep-char' is slated for removal.
2350Not really a change (yet), but a projected one that you should be
2351aware of: The variable `directory-sep-char' is deprecated, and should
2352not be used. It was always ignored on GNU/Linux and Unix systems and
2353on MS-DOS, but the MS-Windows port tried to support it by adapting the
2354behavior of certain primitives to the value of this variable. It
2355turned out that such support cannot be reliable, so it was decided to
2356remove this variable in the near future. Lisp programs are well
2357advised not to set it to anything but '/', because any different value
2358will not have any effect when support for this variable is removed.
2359
2360\f
2361* Lisp changes made after edition 2.6 of the Emacs Lisp Manual,
2362(Display-related features are described in a page of their own below.)
2363
2364** Function assq-delete-all replaces function assoc-delete-all.
2365
2366** The new function animate-string, from lisp/play/animate.el
2367allows the animated display of strings.
2368
2369** The new function `interactive-form' can be used to obtain the
2370interactive form of a function.
2371
2372** The keyword :set-after in defcustom allows to specify dependencies
2373between custom options. Example:
2374
2375 (defcustom default-input-method nil
2376 "*Default input method for multilingual text (a string).
2377 This is the input method activated automatically by the command
2378 `toggle-input-method' (\\[toggle-input-method])."
2379 :group 'mule
2380 :type '(choice (const nil) string)
2381 :set-after '(current-language-environment))
2382
2383This specifies that default-input-method should be set after
2384current-language-environment even if default-input-method appears
2385first in a custom-set-variables statement.
2386
2387** The new hook `kbd-macro-termination-hook' is run at the end of
2388function execute-kbd-macro. Functions on this hook are called with no
2389args. The hook is run independent of how the macro was terminated
2390(signal or normal termination).
2391
2392** Functions `butlast' and `nbutlast' for removing trailing elements
2393from a list are now available without requiring the CL package.
2394
2395** The new user-option `even-window-heights' can be set to nil
2396to prevent `display-buffer' from evening out window heights.
2397
2398** The user-option `face-font-registry-alternatives' specifies
2399alternative font registry names to try when looking for a font.
2400
2401** Function `md5' calculates the MD5 "message digest"/"checksum".
2402
2403** Function `delete-frame' runs `delete-frame-hook' before actually
2404deleting the frame. The hook is called with one arg, the frame
2405being deleted.
2406
2407** `add-hook' now makes the hook local if called with a non-nil LOCAL arg.
2408
2409** The treatment of non-ASCII characters in search ranges has changed.
2410If a range in a regular expression or the arg of
2411skip-chars-forward/backward starts with a unibyte character C and ends
2412with a multibyte character C2, the range is divided into two: one is
2413C..?\377, the other is C1..C2, where C1 is the first character of C2's
2414charset.
2415
2416** The new function `display-message-or-buffer' displays a message in
2417the echo area or pops up a buffer, depending on the length of the
2418message.
2419
2420** The new macro `with-auto-compression-mode' allows evaluating an
2421expression with auto-compression-mode enabled.
2422
2423** In image specifications, `:heuristic-mask' has been replaced
2424with the more general `:mask' property.
2425
2426** Image specifications accept more `:conversion's.
2427
2428** A `?' can be used in a symbol name without escaping it with a
2429backslash.
2430
2431** Reading from the mini-buffer now reads from standard input if Emacs
2432is running in batch mode. For example,
2433
2434 (message "%s" (read t))
2435
2436will read a Lisp expression from standard input and print the result
2437to standard output.
2438
2439** The argument of `down-list', `backward-up-list', `up-list',
2440`kill-sexp', `backward-kill-sexp' and `mark-sexp' is now optional.
2441
2442** If `display-buffer-reuse-frames' is set, function `display-buffer'
2443will raise frames displaying a buffer, instead of creating a new
2444frame or window.
2445
2446** Two new functions for removing elements from lists/sequences
2447were added
2448
2449- Function: remove ELT SEQ
2450
2451Return a copy of SEQ with all occurrences of ELT removed. SEQ must be
2452a list, vector, or string. The comparison is done with `equal'.
2453
2454- Function: remq ELT LIST
2455
2456Return a copy of LIST with all occurrences of ELT removed. The
2457comparison is done with `eq'.
2458
2459** The function `delete' now also works with vectors and strings.
2460
2461** The meaning of the `:weakness WEAK' argument of make-hash-table
2462has been changed: WEAK can now have new values `key-or-value' and
2463`key-and-value', in addition to `nil', `key', `value', and `t'.
2464
2465** Function `aset' stores any multibyte character in any string
2466without signaling "Attempt to change char length of a string". It may
2467convert a unibyte string to multibyte if necessary.
2468
2469** The value of the `help-echo' text property is called as a function
2470or evaluated, if it is not a string already, to obtain a help string.
2471
2472** Function `make-obsolete' now has an optional arg to say when the
2473function was declared obsolete.
2474
2475** Function `plist-member' is renamed from `widget-plist-member' (which is
2476retained as an alias).
2477
2478** Easy-menu's :filter now takes the unconverted form of the menu and
2479the result is automatically converted to Emacs' form.
2480
2481** The new function `window-list' has been defined
2482
2483- Function: window-list &optional FRAME WINDOW MINIBUF
2484
2485Return a list of windows on FRAME, starting with WINDOW. FRAME nil or
2486omitted means use the selected frame. WINDOW nil or omitted means use
2487the selected window. MINIBUF t means include the minibuffer window,
2488even if it isn't active. MINIBUF nil or omitted means include the
2489minibuffer window only if it's active. MINIBUF neither nil nor t
2490means never include the minibuffer window.
2491
2492** There's a new function `get-window-with-predicate' defined as follows
2493
2494- Function: get-window-with-predicate PREDICATE &optional MINIBUF ALL-FRAMES DEFAULT
2495
2496Return a window satisfying PREDICATE.
2497
2498This function cycles through all visible windows using `walk-windows',
2499calling PREDICATE on each one. PREDICATE is called with a window as
2500argument. The first window for which PREDICATE returns a non-nil
2501value is returned. If no window satisfies PREDICATE, DEFAULT is
2502returned.
2503
2504Optional second arg MINIBUF t means count the minibuffer window even
2505if not active. MINIBUF nil or omitted means count the minibuffer iff
2506it is active. MINIBUF neither t nor nil means not to count the
2507minibuffer even if it is active.
2508
2509Several frames may share a single minibuffer; if the minibuffer
2510counts, all windows on all frames that share that minibuffer count
2511too. Therefore, if you are using a separate minibuffer frame
2512and the minibuffer is active and MINIBUF says it counts,
2513`walk-windows' includes the windows in the frame from which you
2514entered the minibuffer, as well as the minibuffer window.
2515
2516ALL-FRAMES is the optional third argument.
2517ALL-FRAMES nil or omitted means cycle within the frames as specified above.
2518ALL-FRAMES = `visible' means include windows on all visible frames.
2519ALL-FRAMES = 0 means include windows on all visible and iconified frames.
2520ALL-FRAMES = t means include windows on all frames including invisible frames.
2521If ALL-FRAMES is a frame, it means include windows on that frame.
2522Anything else means restrict to the selected frame.
2523
2524** The function `single-key-description' now encloses function key and
2525event names in angle brackets. When called with a second optional
2526argument non-nil, angle brackets won't be printed.
2527
2528** If the variable `message-truncate-lines' is bound to t around a
2529call to `message', the echo area will not be resized to display that
2530message; it will be truncated instead, as it was done in 20.x.
2531Default value is nil.
2532
2533** The user option `line-number-display-limit' can now be set to nil,
2534meaning no limit.
2535
2536** The new user option `line-number-display-limit-width' controls
2537the maximum width of lines in a buffer for which Emacs displays line
2538numbers in the mode line. The default is 200.
2539
2540** `select-safe-coding-system' now also checks the most preferred
2541coding-system if buffer-file-coding-system is `undecided' and
2542DEFAULT-CODING-SYSTEM is not specified,
2543
2544** The function `subr-arity' provides information about the argument
2545list of a primitive.
2546
2547** `where-is-internal' now also accepts a list of keymaps.
2548
2549** The text property `keymap' specifies a key map which overrides the
2550buffer's local map and the map specified by the `local-map' property.
2551This is probably what most current uses of `local-map' want, rather
2552than replacing the local map.
2553
2554** The obsolete variables `before-change-function' and
2555`after-change-function' are no longer acted upon and have been
2556removed. Use `before-change-functions' and `after-change-functions'
2557instead.
2558
2559** The function `apropos-mode' runs the hook `apropos-mode-hook'.
2560
2561** `concat' no longer accepts individual integer arguments,
2562as promised long ago.
2563
2564** The new function `float-time' returns the current time as a float.
2565
2566** The new variable auto-coding-regexp-alist specifies coding systems
2567for reading specific files, analogous to auto-coding-alist, but
2568patterns are checked against file contents instead of file names.
2569
2570\f
2571* Lisp changes in Emacs 21.1 (see following page for display-related features)
2572
2573** The new package rx.el provides an alternative sexp notation for
2574regular expressions.
2575
2576- Function: rx-to-string SEXP
2577
2578Translate SEXP into a regular expression in string notation.
2579
2580- Macro: rx SEXP
2581
2582Translate SEXP into a regular expression in string notation.
2583
2584The following are valid subforms of regular expressions in sexp
2585notation.
2586
2587STRING
2588 matches string STRING literally.
2589
2590CHAR
2591 matches character CHAR literally.
2592
2593`not-newline'
2594 matches any character except a newline.
2595 .
2596`anything'
2597 matches any character
2598
2599`(any SET)'
2600 matches any character in SET. SET may be a character or string.
2601 Ranges of characters can be specified as `A-Z' in strings.
2602
2603'(in SET)'
2604 like `any'.
2605
2606`(not (any SET))'
2607 matches any character not in SET
2608
2609`line-start'
2610 matches the empty string, but only at the beginning of a line
2611 in the text being matched
2612
2613`line-end'
2614 is similar to `line-start' but matches only at the end of a line
2615
2616`string-start'
2617 matches the empty string, but only at the beginning of the
2618 string being matched against.
2619
2620`string-end'
2621 matches the empty string, but only at the end of the
2622 string being matched against.
2623
2624`buffer-start'
2625 matches the empty string, but only at the beginning of the
2626 buffer being matched against.
2627
2628`buffer-end'
2629 matches the empty string, but only at the end of the
2630 buffer being matched against.
2631
2632`point'
2633 matches the empty string, but only at point.
2634
2635`word-start'
2636 matches the empty string, but only at the beginning or end of a
2637 word.
2638
2639`word-end'
2640 matches the empty string, but only at the end of a word.
2641
2642`word-boundary'
2643 matches the empty string, but only at the beginning or end of a
2644 word.
2645
2646`(not word-boundary)'
2647 matches the empty string, but not at the beginning or end of a
2648 word.
2649
2650`digit'
2651 matches 0 through 9.
2652
2653`control'
2654 matches ASCII control characters.
2655
2656`hex-digit'
2657 matches 0 through 9, a through f and A through F.
2658
2659`blank'
2660 matches space and tab only.
2661
2662`graphic'
2663 matches graphic characters--everything except ASCII control chars,
2664 space, and DEL.
2665
2666`printing'
2667 matches printing characters--everything except ASCII control chars
2668 and DEL.
2669
2670`alphanumeric'
2671 matches letters and digits. (But at present, for multibyte characters,
2672 it matches anything that has word syntax.)
2673
2674`letter'
2675 matches letters. (But at present, for multibyte characters,
2676 it matches anything that has word syntax.)
2677
2678`ascii'
2679 matches ASCII (unibyte) characters.
2680
2681`nonascii'
2682 matches non-ASCII (multibyte) characters.
2683
2684`lower'
2685 matches anything lower-case.
2686
2687`upper'
2688 matches anything upper-case.
2689
2690`punctuation'
2691 matches punctuation. (But at present, for multibyte characters,
2692 it matches anything that has non-word syntax.)
2693
2694`space'
2695 matches anything that has whitespace syntax.
2696
2697`word'
2698 matches anything that has word syntax.
2699
2700`(syntax SYNTAX)'
2701 matches a character with syntax SYNTAX. SYNTAX must be one
2702 of the following symbols.
2703
2704 `whitespace' (\\s- in string notation)
2705 `punctuation' (\\s.)
2706 `word' (\\sw)
2707 `symbol' (\\s_)
2708 `open-parenthesis' (\\s()
2709 `close-parenthesis' (\\s))
2710 `expression-prefix' (\\s')
2711 `string-quote' (\\s\")
2712 `paired-delimiter' (\\s$)
2713 `escape' (\\s\\)
2714 `character-quote' (\\s/)
2715 `comment-start' (\\s<)
2716 `comment-end' (\\s>)
2717
2718`(not (syntax SYNTAX))'
2719 matches a character that has not syntax SYNTAX.
2720
2721`(category CATEGORY)'
2722 matches a character with category CATEGORY. CATEGORY must be
2723 either a character to use for C, or one of the following symbols.
2724
2725 `consonant' (\\c0 in string notation)
2726 `base-vowel' (\\c1)
2727 `upper-diacritical-mark' (\\c2)
2728 `lower-diacritical-mark' (\\c3)
2729 `tone-mark' (\\c4)
2730 `symbol' (\\c5)
2731 `digit' (\\c6)
2732 `vowel-modifying-diacritical-mark' (\\c7)
2733 `vowel-sign' (\\c8)
2734 `semivowel-lower' (\\c9)
2735 `not-at-end-of-line' (\\c<)
2736 `not-at-beginning-of-line' (\\c>)
2737 `alpha-numeric-two-byte' (\\cA)
2738 `chinse-two-byte' (\\cC)
2739 `greek-two-byte' (\\cG)
2740 `japanese-hiragana-two-byte' (\\cH)
2741 `indian-two-byte' (\\cI)
2742 `japanese-katakana-two-byte' (\\cK)
2743 `korean-hangul-two-byte' (\\cN)
2744 `cyrillic-two-byte' (\\cY)
2745 `ascii' (\\ca)
2746 `arabic' (\\cb)
2747 `chinese' (\\cc)
2748 `ethiopic' (\\ce)
2749 `greek' (\\cg)
2750 `korean' (\\ch)
2751 `indian' (\\ci)
2752 `japanese' (\\cj)
2753 `japanese-katakana' (\\ck)
2754 `latin' (\\cl)
2755 `lao' (\\co)
2756 `tibetan' (\\cq)
2757 `japanese-roman' (\\cr)
2758 `thai' (\\ct)
2759 `vietnamese' (\\cv)
2760 `hebrew' (\\cw)
2761 `cyrillic' (\\cy)
2762 `can-break' (\\c|)
2763
2764`(not (category CATEGORY))'
2765 matches a character that has not category CATEGORY.
2766
2767`(and SEXP1 SEXP2 ...)'
2768 matches what SEXP1 matches, followed by what SEXP2 matches, etc.
2769
2770`(submatch SEXP1 SEXP2 ...)'
2771 like `and', but makes the match accessible with `match-end',
2772 `match-beginning', and `match-string'.
2773
2774`(group SEXP1 SEXP2 ...)'
2775 another name for `submatch'.
2776
2777`(or SEXP1 SEXP2 ...)'
2778 matches anything that matches SEXP1 or SEXP2, etc. If all
2779 args are strings, use `regexp-opt' to optimize the resulting
2780 regular expression.
2781
2782`(minimal-match SEXP)'
2783 produce a non-greedy regexp for SEXP. Normally, regexps matching
2784 zero or more occurrences of something are \"greedy\" in that they
2785 match as much as they can, as long as the overall regexp can
2786 still match. A non-greedy regexp matches as little as possible.
2787
2788`(maximal-match SEXP)'
2789 produce a greedy regexp for SEXP. This is the default.
2790
2791`(zero-or-more SEXP)'
2792 matches zero or more occurrences of what SEXP matches.
2793
2794`(0+ SEXP)'
2795 like `zero-or-more'.
2796
2797`(* SEXP)'
2798 like `zero-or-more', but always produces a greedy regexp.
2799
2800`(*? SEXP)'
2801 like `zero-or-more', but always produces a non-greedy regexp.
2802
2803`(one-or-more SEXP)'
2804 matches one or more occurrences of A.
2805
2806`(1+ SEXP)'
2807 like `one-or-more'.
2808
2809`(+ SEXP)'
2810 like `one-or-more', but always produces a greedy regexp.
2811
2812`(+? SEXP)'
2813 like `one-or-more', but always produces a non-greedy regexp.
2814
2815`(zero-or-one SEXP)'
2816 matches zero or one occurrences of A.
2817
2818`(optional SEXP)'
2819 like `zero-or-one'.
2820
2821`(? SEXP)'
2822 like `zero-or-one', but always produces a greedy regexp.
2823
2824`(?? SEXP)'
2825 like `zero-or-one', but always produces a non-greedy regexp.
2826
2827`(repeat N SEXP)'
2828 matches N occurrences of what SEXP matches.
2829
2830`(repeat N M SEXP)'
2831 matches N to M occurrences of what SEXP matches.
2832
2833`(eval FORM)'
2834 evaluate FORM and insert result. If result is a string,
2835 `regexp-quote' it.
2836
2837`(regexp REGEXP)'
2838 include REGEXP in string notation in the result.
2839
2840*** The features `md5' and `overlay' are now provided by default.
2841
2842*** The special form `save-restriction' now works correctly even if the
2843buffer is widened inside the save-restriction and changes made outside
2844the original restriction. Previously, doing this would cause the saved
2845restriction to be restored incorrectly.
2846
2847*** The functions `find-charset-region' and `find-charset-string' include
2848`eight-bit-control' and/or `eight-bit-graphic' in the returned list
2849when they find 8-bit characters. Previously, they included `ascii' in a
2850multibyte buffer and `unknown' in a unibyte buffer.
2851
2852*** The functions `set-buffer-multibyte', `string-as-multibyte' and
2853`string-as-unibyte' change the byte sequence of a buffer or a string
2854if it contains a character from the `eight-bit-control' character set.
2855
2856*** The handling of multibyte sequences in a multibyte buffer is
2857changed. Previously, a byte sequence matching the pattern
2858[\200-\237][\240-\377]+ was interpreted as a single character
2859regardless of the length of the trailing bytes [\240-\377]+. Thus, if
2860the sequence was longer than what the leading byte indicated, the
2861extra trailing bytes were ignored by Lisp functions. Now such extra
2862bytes are independent 8-bit characters belonging to the charset
2863eight-bit-graphic.
2864
2865** Fontsets are now implemented using char-tables.
2866
2867A fontset can now be specified for each independent character, for
2868a group of characters or for a character set rather than just for a
2869character set as previously.
2870
2871*** The arguments of the function `set-fontset-font' are changed.
2872They are NAME, CHARACTER, FONTNAME, and optional FRAME. The function
2873modifies fontset NAME to use FONTNAME for CHARACTER.
2874
2875CHARACTER may be a cons (FROM . TO), where FROM and TO are non-generic
2876characters. In that case FONTNAME is used for all characters in the
2877range FROM and TO (inclusive). CHARACTER may be a charset. In that
2878case FONTNAME is used for all character in the charset.
2879
2880FONTNAME may be a cons (FAMILY . REGISTRY), where FAMILY is the family
2881name of a font and REGISTRY is a registry name of a font.
2882
2883*** Variable x-charset-registry has been deleted. The default charset
2884registries of character sets are set in the default fontset
2885"fontset-default".
2886
2887*** The function `create-fontset-from-fontset-spec' ignores the second
2888argument STYLE-VARIANT. It never creates style-variant fontsets.
2889
2890** The method of composing characters is changed. Now character
2891composition is done by a special text property `composition' in
2892buffers and strings.
2893
2894*** Charset composition is deleted. Emacs never creates a `composite
2895character' which is an independent character with a unique character
2896code. Thus the following functions handling `composite characters'
2897have been deleted: composite-char-component,
2898composite-char-component-count, composite-char-composition-rule,
2899composite-char-composition-rule and decompose-composite-char delete.
2900The variables leading-code-composition and min-composite-char have
2901also been deleted.
2902
2903*** Three more glyph reference points are added. They can be used to
2904specify a composition rule. See the documentation of the variable
2905`reference-point-alist' for more detail.
2906
2907*** The function `compose-region' takes new arguments COMPONENTS and
2908MODIFICATION-FUNC. With COMPONENTS, you can specify not only a
2909composition rule but also characters to be composed. Such characters
2910may differ between buffer and string text.
2911
2912*** The function `compose-string' takes new arguments START, END,
2913COMPONENTS, and MODIFICATION-FUNC.
2914
2915*** The function `compose-string' puts text property `composition'
2916directly on the argument STRING instead of returning a new string.
2917Likewise, the function `decompose-string' just removes text property
2918`composition' from STRING.
2919
2920*** The new function `find-composition' returns information about
2921a composition at a specified position in a buffer or a string.
2922
2923*** The function `decompose-composite-char' is now labeled as
2924obsolete.
2925
2926** The new coding system `mac-roman' is primarily intended for use on
2927the Macintosh but may be used generally for Macintosh-encoded text.
2928
2929** The new character sets `mule-unicode-0100-24ff',
2930`mule-unicode-2500-33ff', and `mule-unicode-e000-ffff' have been
2931introduced for Unicode characters in the range U+0100..U+24FF,
2932U+2500..U+33FF, U+E000..U+FFFF respectively.
2933
2934Note that the character sets are not yet unified in Emacs, so
2935characters which belong to charsets such as Latin-2, Greek, Hebrew,
2936etc. and the same characters in the `mule-unicode-*' charsets are
2937different characters, as far as Emacs is concerned. For example, text
2938which includes Unicode characters from the Latin-2 locale cannot be
2939encoded by Emacs with ISO 8859-2 coding system.
2940
2941** The new coding system `mule-utf-8' has been added.
2942It provides limited support for decoding/encoding UTF-8 text. For
2943details, please see the documentation string of this coding system.
2944
2945** The new character sets `japanese-jisx0213-1' and
2946`japanese-jisx0213-2' have been introduced for the new Japanese
2947standard JIS X 0213 Plane 1 and Plane 2.
2948
2949** The new character sets `latin-iso8859-14' and `latin-iso8859-15'
2950have been introduced.
2951
2952** The new character sets `eight-bit-control' and `eight-bit-graphic'
2953have been introduced for 8-bit characters in the ranges 0x80..0x9F and
29540xA0..0xFF respectively. Note that the multibyte representation of
2955eight-bit-control is never exposed; this leads to an exception in the
2956emacs-mule coding system, which encodes everything else to the
2957buffer/string internal representation. Note that to search for
2958eight-bit-graphic characters in a multibyte buffer, the search string
2959must be multibyte, otherwise such characters will be converted to
2960their multibyte equivalent.
2961
2962** If the APPEND argument of `write-region' is an integer, it seeks to
2963that offset in the file before writing.
2964
2965** The function `add-minor-mode' has been added for convenience and
2966compatibility with XEmacs (and is used internally by define-minor-mode).
2967
2968** The function `shell-command' now sets the default directory of the
2969`*Shell Command Output*' buffer to the default directory of the buffer
2970from which the command was issued.
2971
2972** The functions `query-replace', `query-replace-regexp',
2973`query-replace-regexp-eval' `map-query-replace-regexp',
2974`replace-string', `replace-regexp', and `perform-replace' take two
2975additional optional arguments START and END that specify the region to
2976operate on.
2977
2978** The new function `count-screen-lines' is a more flexible alternative
2979to `window-buffer-height'.
2980
2981- Function: count-screen-lines &optional BEG END COUNT-FINAL-NEWLINE WINDOW
2982
2983Return the number of screen lines in the region between BEG and END.
2984The number of screen lines may be different from the number of actual
2985lines, due to line breaking, display table, etc.
2986
2987Optional arguments BEG and END default to `point-min' and `point-max'
2988respectively.
2989
2990If region ends with a newline, ignore it unless optional third argument
2991COUNT-FINAL-NEWLINE is non-nil.
2992
2993The optional fourth argument WINDOW specifies the window used for
2994obtaining parameters such as width, horizontal scrolling, and so
2995on. The default is to use the selected window's parameters.
2996
2997Like `vertical-motion', `count-screen-lines' always uses the current
2998buffer, regardless of which buffer is displayed in WINDOW. This makes
2999possible to use `count-screen-lines' in any buffer, whether or not it
3000is currently displayed in some window.
3001
3002** The new function `mapc' is like `mapcar' but doesn't collect the
3003argument function's results.
3004
3005** The functions base64-decode-region and base64-decode-string now
3006signal an error instead of returning nil if decoding fails. Also,
3007`base64-decode-string' now always returns a unibyte string (in Emacs
300820, it returned a multibyte string when the result was a valid multibyte
3009sequence).
3010
3011** The function sendmail-user-agent-compose now recognizes a `body'
3012header in the list of headers passed to it.
3013
3014** The new function member-ignore-case works like `member', but
3015ignores differences in case and text representation.
3016
3017** The buffer-local variable cursor-type can be used to specify the
3018cursor to use in windows displaying a buffer. Values are interpreted
3019as follows:
3020
3021 t use the cursor specified for the frame (default)
3022 nil don't display a cursor
3023 `bar' display a bar cursor with default width
3024 (bar . WIDTH) display a bar cursor with width WIDTH
3025 others display a box cursor.
3026
3027** The variable open-paren-in-column-0-is-defun-start controls whether
3028an open parenthesis in column 0 is considered to be the start of a
3029defun. If set, the default, it is considered a defun start. If not
3030set, an open parenthesis in column 0 has no special meaning.
3031
3032** The new function `string-to-syntax' can be used to translate syntax
3033specifications in string form as accepted by `modify-syntax-entry' to
3034the cons-cell form that is used for the values of the `syntax-table'
3035text property, and in `font-lock-syntactic-keywords'.
3036
3037Example:
3038
3039 (string-to-syntax "()")
3040 => (4 . 41)
3041
3042** Emacs' reader supports CL read syntax for integers in bases
3043other than 10.
3044
3045*** `#BINTEGER' or `#bINTEGER' reads INTEGER in binary (radix 2).
3046INTEGER optionally contains a sign.
3047
3048 #b1111
3049 => 15
3050 #b-1111
3051 => -15
3052
3053*** `#OINTEGER' or `#oINTEGER' reads INTEGER in octal (radix 8).
3054
3055 #o666
3056 => 438
3057
3058*** `#XINTEGER' or `#xINTEGER' reads INTEGER in hexadecimal (radix 16).
3059
3060 #xbeef
3061 => 48815
3062
3063*** `#RADIXrINTEGER' reads INTEGER in radix RADIX, 2 <= RADIX <= 36.
3064
3065 #2R-111
3066 => -7
3067 #25rah
3068 => 267
3069
3070** The function `documentation-property' now evaluates the value of
3071the given property to obtain a string if it doesn't refer to etc/DOC
3072and isn't a string.
3073
3074** If called for a symbol, the function `documentation' now looks for
3075a `function-documentation' property of that symbol. If it has a non-nil
3076value, the documentation is taken from that value. If the value is
3077not a string, it is evaluated to obtain a string.
3078
3079** The last argument of `define-key-after' defaults to t for convenience.
3080
3081** The new function `replace-regexp-in-string' replaces all matches
3082for a regexp in a string.
3083
3084** `mouse-position' now runs the abnormal hook
3085`mouse-position-function'.
3086
3087** The function string-to-number now returns a float for numbers
3088that don't fit into a Lisp integer.
3089
3090** The variable keyword-symbols-constants-flag has been removed.
3091Keywords are now always considered constants.
3092
3093** The new function `delete-and-extract-region' deletes text and
3094returns it.
3095
3096** The function `clear-this-command-keys' now also clears the vector
3097returned by function `recent-keys'.
3098
3099** Variables `beginning-of-defun-function' and `end-of-defun-function'
3100can be used to define handlers for the functions that find defuns.
3101Major modes can define these locally instead of rebinding C-M-a
3102etc. if the normal conventions for defuns are not appropriate for the
3103mode.
3104
3105** easy-mmode-define-minor-mode now takes an additional BODY argument
3106and is renamed `define-minor-mode'.
3107
3108** If an abbrev has a hook function which is a symbol, and that symbol
3109has a non-nil `no-self-insert' property, the return value of the hook
3110function specifies whether an expansion has been done or not. If it
3111returns nil, abbrev-expand also returns nil, meaning "no expansion has
3112been performed."
3113
3114When abbrev expansion is done by typing a self-inserting character,
3115and the abbrev has a hook with the `no-self-insert' property, and the
3116hook function returns non-nil meaning expansion has been done,
3117then the self-inserting character is not inserted.
3118
3119** The function `intern-soft' now accepts a symbol as first argument.
3120In this case, that exact symbol is looked up in the specified obarray,
3121and the function's value is nil if it is not found.
3122
3123** The new macro `with-syntax-table' can be used to evaluate forms
3124with the syntax table of the current buffer temporarily set to a
3125specified table.
3126
3127 (with-syntax-table TABLE &rest BODY)
3128
3129Evaluate BODY with syntax table of current buffer set to a copy of
3130TABLE. The current syntax table is saved, BODY is evaluated, and the
3131saved table is restored, even in case of an abnormal exit. Value is
3132what BODY returns.
3133
3134** Regular expressions now support intervals \{n,m\} as well as
3135Perl's shy-groups \(?:...\) and non-greedy *? +? and ?? operators.
3136Also back-references like \2 are now considered as an error if the
3137corresponding subgroup does not exist (or is not closed yet).
3138Previously it would have been silently turned into `2' (ignoring the `\').
3139
3140** The optional argument BUFFER of function file-local-copy has been
3141removed since it wasn't used by anything.
3142
3143** The file name argument of function `file-locked-p' is now required
3144instead of being optional.
3145
3146** The new built-in error `text-read-only' is signaled when trying to
3147modify read-only text.
3148
3149** New functions and variables for locales.
3150
3151The new variable `locale-coding-system' specifies how to encode and
3152decode strings passed to low-level message functions like strerror and
3153time functions like strftime. The new variables
3154`system-messages-locale' and `system-time-locale' give the system
3155locales to be used when invoking these two types of functions.
3156
3157The new function `set-locale-environment' sets the language
3158environment, preferred coding system, and locale coding system from
3159the system locale as specified by the LC_ALL, LC_CTYPE, and LANG
3160environment variables. Normally, it is invoked during startup and need
3161not be invoked thereafter. It uses the new variables
3162`locale-language-names', `locale-charset-language-names', and
3163`locale-preferred-coding-systems' to make its decisions.
3164
3165** syntax tables now understand nested comments.
3166To declare a comment syntax as allowing nesting, just add an `n'
3167modifier to either of the characters of the comment end and the comment
3168start sequences.
3169
3170** The function `pixmap-spec-p' has been renamed `bitmap-spec-p'
3171because `bitmap' is more in line with the usual X terminology.
3172
3173** New function `propertize'
3174
3175The new function `propertize' can be used to conveniently construct
3176strings with text properties.
3177
3178- Function: propertize STRING &rest PROPERTIES
3179
3180Value is a copy of STRING with text properties assigned as specified
3181by PROPERTIES. PROPERTIES is a sequence of pairs PROPERTY VALUE, with
3182PROPERTY being the name of a text property and VALUE being the
3183specified value of that property. Example:
3184
3185 (propertize "foo" 'face 'bold 'read-only t)
3186
3187** push and pop macros.
3188
3189Simple versions of the push and pop macros of Common Lisp
3190are now defined in Emacs Lisp. These macros allow only symbols
3191as the place that holds the list to be changed.
3192
3193(push NEWELT LISTNAME) add NEWELT to the front of LISTNAME's value.
3194(pop LISTNAME) return first elt of LISTNAME, and remove it
3195 (thus altering the value of LISTNAME).
3196
3197** New dolist and dotimes macros.
3198
3199Simple versions of the dolist and dotimes macros of Common Lisp
3200are now defined in Emacs Lisp.
3201
3202(dolist (VAR LIST [RESULT]) BODY...)
3203 Execute body once for each element of LIST,
3204 using the variable VAR to hold the current element.
3205 Then return the value of RESULT, or nil if RESULT is omitted.
3206
3207(dotimes (VAR COUNT [RESULT]) BODY...)
3208 Execute BODY with VAR bound to successive integers running from 0,
3209 inclusive, to COUNT, exclusive.
3210 Then return the value of RESULT, or nil if RESULT is omitted.
3211
3212** Regular expressions now support Posix character classes such as
3213[:alpha:], [:space:] and so on. These must be used within a character
3214class--for instance, [-[:digit:].+] matches digits or a period
3215or a sign.
3216
3217[:digit:] matches 0 through 9
3218[:cntrl:] matches ASCII control characters
3219[:xdigit:] matches 0 through 9, a through f and A through F.
3220[:blank:] matches space and tab only
3221[:graph:] matches graphic characters--everything except ASCII control chars,
3222 space, and DEL.
3223[:print:] matches printing characters--everything except ASCII control chars
3224 and DEL.
3225[:alnum:] matches letters and digits.
3226 (But at present, for multibyte characters,
3227 it matches anything that has word syntax.)
3228[:alpha:] matches letters.
3229 (But at present, for multibyte characters,
3230 it matches anything that has word syntax.)
3231[:ascii:] matches ASCII (unibyte) characters.
3232[:nonascii:] matches non-ASCII (multibyte) characters.
3233[:lower:] matches anything lower-case.
3234[:punct:] matches punctuation.
3235 (But at present, for multibyte characters,
3236 it matches anything that has non-word syntax.)
3237[:space:] matches anything that has whitespace syntax.
3238[:upper:] matches anything upper-case.
3239[:word:] matches anything that has word syntax.
3240
3241** Emacs now has built-in hash tables.
3242
3243The following functions are defined for hash tables:
3244
3245- Function: make-hash-table ARGS
3246
3247The argument list ARGS consists of keyword/argument pairs. All arguments
3248are optional. The following arguments are defined:
3249
3250:test TEST
3251
3252TEST must be a symbol specifying how to compare keys. Default is `eql'.
3253Predefined are `eq', `eql' and `equal'. If TEST is not predefined,
3254it must have been defined with `define-hash-table-test'.
3255
3256:size SIZE
3257
3258SIZE must be an integer > 0 giving a hint to the implementation how
3259many elements will be put in the hash table. Default size is 65.
3260
3261:rehash-size REHASH-SIZE
3262
3263REHASH-SIZE specifies by how much to grow a hash table once it becomes
3264full. If REHASH-SIZE is an integer, add that to the hash table's old
3265size to get the new size. Otherwise, REHASH-SIZE must be a float >
32661.0, and the new size is computed by multiplying REHASH-SIZE with the
3267old size. Default rehash size is 1.5.
3268
3269:rehash-threshold THRESHOLD
3270
3271THRESHOLD must be a float > 0 and <= 1.0 specifying when to resize the
3272hash table. It is resized when the ratio of (number of entries) /
3273(size of hash table) is >= THRESHOLD. Default threshold is 0.8.
3274
3275:weakness WEAK
3276
3277WEAK must be either nil, one of the symbols `key, `value',
3278`key-or-value', `key-and-value', or t, meaning the same as
3279`key-and-value'. Entries are removed from weak tables during garbage
3280collection if their key and/or value are not referenced elsewhere
3281outside of the hash table. Default are non-weak hash tables.
3282
3283- Function: makehash &optional TEST
3284
3285Similar to make-hash-table, but only TEST can be specified.
3286
3287- Function: hash-table-p TABLE
3288
3289Returns non-nil if TABLE is a hash table object.
3290
3291- Function: copy-hash-table TABLE
3292
3293Returns a copy of TABLE. Only the table itself is copied, keys and
3294values are shared.
3295
3296- Function: hash-table-count TABLE
3297
3298Returns the number of entries in TABLE.
3299
3300- Function: hash-table-rehash-size TABLE
3301
3302Returns the rehash size of TABLE.
3303
3304- Function: hash-table-rehash-threshold TABLE
3305
3306Returns the rehash threshold of TABLE.
3307
3308- Function: hash-table-rehash-size TABLE
3309
3310Returns the size of TABLE.
3311
3312- Function: hash-table-test TABLE
3313
3314Returns the test TABLE uses to compare keys.
3315
3316- Function: hash-table-weakness TABLE
3317
3318Returns the weakness specified for TABLE.
3319
3320- Function: clrhash TABLE
3321
3322Clear TABLE.
3323
3324- Function: gethash KEY TABLE &optional DEFAULT
3325
3326Look up KEY in TABLE and return its associated VALUE or DEFAULT if
3327not found.
3328
3329- Function: puthash KEY VALUE TABLE
3330
3331Associate KEY with VALUE in TABLE. If KEY is already associated with
3332another value, replace the old value with VALUE.
3333
3334- Function: remhash KEY TABLE
3335
3336Remove KEY from TABLE if it is there.
3337
3338- Function: maphash FUNCTION TABLE
3339
3340Call FUNCTION for all elements in TABLE. FUNCTION must take two
3341arguments KEY and VALUE.
3342
3343- Function: sxhash OBJ
3344
3345Return a hash code for Lisp object OBJ.
3346
3347- Function: define-hash-table-test NAME TEST-FN HASH-FN
3348
3349Define a new hash table test named NAME. If NAME is specified as
3350a test in `make-hash-table', the table created will use TEST-FN for
3351comparing keys, and HASH-FN to compute hash codes for keys. Test
3352and hash function are stored as symbol property `hash-table-test'
3353of NAME with a value of (TEST-FN HASH-FN).
3354
3355TEST-FN must take two arguments and return non-nil if they are the same.
3356
3357HASH-FN must take one argument and return an integer that is the hash
3358code of the argument. The function should use the whole range of
3359integer values for hash code computation, including negative integers.
3360
3361Example: The following creates a hash table whose keys are supposed to
3362be strings that are compared case-insensitively.
3363
3364 (defun case-fold-string= (a b)
3365 (compare-strings a nil nil b nil nil t))
3366
3367 (defun case-fold-string-hash (a)
3368 (sxhash (upcase a)))
3369
3370 (define-hash-table-test 'case-fold 'case-fold-string=
3371 'case-fold-string-hash))
3372
3373 (make-hash-table :test 'case-fold)
3374
3375** The Lisp reader handles circular structure.
3376
3377It now works to use the #N= and #N# constructs to represent
3378circular structures. For example, #1=(a . #1#) represents
3379a cons cell which is its own cdr.
3380
3381** The Lisp printer handles circular structure.
3382
3383If you bind print-circle to a non-nil value, the Lisp printer outputs
3384#N= and #N# constructs to represent circular and shared structure.
3385
3386** If the second argument to `move-to-column' is anything but nil or
3387t, that means replace a tab with spaces if necessary to reach the
3388specified column, but do not add spaces at the end of the line if it
3389is too short to reach that column.
3390
3391** perform-replace has a new feature: the REPLACEMENTS argument may
3392now be a cons cell (FUNCTION . DATA). This means to call FUNCTION
3393after each match to get the replacement text. FUNCTION is called with
3394two arguments: DATA, and the number of replacements already made.
3395
3396If the FROM-STRING contains any upper-case letters,
3397perform-replace also turns off `case-fold-search' temporarily
3398and inserts the replacement text without altering case in it.
3399
3400** The function buffer-size now accepts an optional argument
3401to specify which buffer to return the size of.
3402
3403** The calendar motion commands now run the normal hook
3404calendar-move-hook after moving point.
3405
3406** The new variable small-temporary-file-directory specifies a
3407directory to use for creating temporary files that are likely to be
3408small. (Certain Emacs features use this directory.) If
3409small-temporary-file-directory is nil, they use
3410temporary-file-directory instead.
3411
3412** The variable `inhibit-modification-hooks', if non-nil, inhibits all
3413the hooks that track changes in the buffer. This affects
3414`before-change-functions' and `after-change-functions', as well as
3415hooks attached to text properties and overlay properties.
3416
3417** assq-delete-all is a new function that deletes all the
3418elements of an alist which have a car `eq' to a particular value.
3419
3420** make-temp-file provides a more reliable way to create a temporary file.
3421
3422make-temp-file is used like make-temp-name, except that it actually
3423creates the file before it returns. This prevents a timing error,
3424ensuring that no other job can use the same name for a temporary file.
3425
3426** New exclusive-open feature in `write-region'
3427
3428The optional seventh arg is now called MUSTBENEW. If non-nil, it insists
3429on a check for an existing file with the same name. If MUSTBENEW
3430is `excl', that means to get an error if the file already exists;
3431never overwrite. If MUSTBENEW is neither nil nor `excl', that means
3432ask for confirmation before overwriting, but do go ahead and
3433overwrite the file if the user gives confirmation.
3434
3435If the MUSTBENEW argument in `write-region' is `excl',
3436that means to use a special feature in the `open' system call
3437to get an error if the file exists at that time.
3438The error reported is `file-already-exists'.
3439
3440** Function `format' now handles text properties.
3441
3442Text properties of the format string are applied to the result string.
3443If the result string is longer than the format string, text properties
3444ending at the end of the format string are extended to the end of the
3445result string.
3446
3447Text properties from string arguments are applied to the result
3448string where arguments appear in the result string.
3449
3450Example:
3451
3452 (let ((s1 "hello, %s")
3453 (s2 "world"))
3454 (put-text-property 0 (length s1) 'face 'bold s1)
3455 (put-text-property 0 (length s2) 'face 'italic s2)
3456 (format s1 s2))
3457
3458results in a bold-face string with an italic `world' at the end.
3459
3460** Messages can now be displayed with text properties.
3461
3462Text properties are handled as described above for function `format'.
3463The following example displays a bold-face message with an italic
3464argument in it.
3465
3466 (let ((msg "hello, %s!")
3467 (arg "world"))
3468 (put-text-property 0 (length msg) 'face 'bold msg)
3469 (put-text-property 0 (length arg) 'face 'italic arg)
3470 (message msg arg))
3471
3472** Sound support
3473
3474Emacs supports playing sound files on GNU/Linux and the free BSDs
3475(Voxware driver and native BSD driver, aka as Luigi's driver).
3476
3477Currently supported file formats are RIFF-WAVE (*.wav) and Sun Audio
3478(*.au). You must configure Emacs with the option `--with-sound=yes'
3479to enable sound support.
3480
3481Sound files can be played by calling (play-sound SOUND). SOUND is a
3482list of the form `(sound PROPERTY...)'. The function is only defined
3483when sound support is present for the system on which Emacs runs. The
3484functions runs `play-sound-functions' with one argument which is the
3485sound to play, before playing the sound.
3486
3487The following sound properties are supported:
3488
3489- `:file FILE'
3490
3491FILE is a file name. If FILE isn't an absolute name, it will be
3492searched relative to `data-directory'.
3493
3494- `:data DATA'
3495
3496DATA is a string containing sound data. Either :file or :data
3497may be present, but not both.
3498
3499- `:volume VOLUME'
3500
3501VOLUME must be an integer in the range 0..100 or a float in the range
35020..1. This property is optional.
3503
3504- `:device DEVICE'
3505
3506DEVICE is a string specifying the system device on which to play the
3507sound. The default device is system-dependent.
3508
3509Other properties are ignored.
3510
3511An alternative interface is called as
3512(play-sound-file FILE &optional VOLUME DEVICE).
3513
3514** `multimedia' is a new Finder keyword and Custom group.
3515
3516** keywordp is a new predicate to test efficiently for an object being
3517a keyword symbol.
3518
3519** Changes to garbage collection
3520
3521*** The function garbage-collect now additionally returns the number
3522of live and free strings.
3523
3524*** There is a new variable `strings-consed' holding the number of
3525strings that have been consed so far.
3526
3527\f
3528* Lisp-level Display features added after release 2.6 of the Emacs
3529Lisp Manual
3530
3531** The user-option `resize-mini-windows' controls how Emacs resizes
3532mini-windows.
3533
3534** The function `pos-visible-in-window-p' now has a third optional
3535argument, PARTIALLY. If a character is only partially visible, nil is
3536returned, unless PARTIALLY is non-nil.
3537
3538** On window systems, `glyph-table' is no longer used.
3539
3540** Help strings in menu items are now used to provide `help-echo' text.
3541
3542** The function `image-size' can be used to determine the size of an
3543image.
3544
3545- Function: image-size SPEC &optional PIXELS FRAME
3546
3547Return the size of an image as a pair (WIDTH . HEIGHT).
3548
3549SPEC is an image specification. PIXELS non-nil means return sizes
3550measured in pixels, otherwise return sizes measured in canonical
3551character units (fractions of the width/height of the frame's default
3552font). FRAME is the frame on which the image will be displayed.
3553FRAME nil or omitted means use the selected frame.
3554
3555** The function `image-mask-p' can be used to determine if an image
3556has a mask bitmap.
3557
3558- Function: image-mask-p SPEC &optional FRAME
3559
3560Return t if image SPEC has a mask bitmap.
3561FRAME is the frame on which the image will be displayed. FRAME nil
3562or omitted means use the selected frame.
3563
3564** The function `find-image' can be used to find a usable image
3565satisfying one of a list of specifications.
3566
3567** The STRING argument of `put-image' and `insert-image' is now
3568optional.
3569
3570** Image specifications may contain the property `:ascent center' (see
3571below).
3572
3573\f
3574* New Lisp-level Display features in Emacs 21.1
3575
3576** The function tty-suppress-bold-inverse-default-colors can be used
3577to make Emacs avoid displaying text with bold black foreground on TTYs.
3578
3579Some terminals, notably PC consoles, emulate bold text by displaying
3580text in brighter colors. On such a console, a bold black foreground
3581is displayed in a gray color. If this turns out to be hard to read on
3582your monitor---the problem occurred with the mode line on
3583laptops---you can instruct Emacs to ignore the text's boldness, and to
3584just display it black instead.
3585
3586This situation can't be detected automatically. You will have to put
3587a line like
3588
3589 (tty-suppress-bold-inverse-default-colors t)
3590
3591in your `.emacs'.
3592
3593** New face implementation.
3594
3595Emacs faces have been reimplemented from scratch. They don't use XLFD
3596font names anymore and face merging now works as expected.
3597
3598*** New faces.
3599
3600Each face can specify the following display attributes:
3601
3602 1. Font family or fontset alias name.
3603
3604 2. Relative proportionate width, aka character set width or set
3605 width (swidth), e.g. `semi-compressed'.
3606
3607 3. Font height in 1/10pt
3608
3609 4. Font weight, e.g. `bold'.
3610
3611 5. Font slant, e.g. `italic'.
3612
3613 6. Foreground color.
3614
3615 7. Background color.
3616
3617 8. Whether or not characters should be underlined, and in what color.
3618
3619 9. Whether or not characters should be displayed in inverse video.
3620
3621 10. A background stipple, a bitmap.
3622
3623 11. Whether or not characters should be overlined, and in what color.
3624
3625 12. Whether or not characters should be strike-through, and in what
3626 color.
3627
3628 13. Whether or not a box should be drawn around characters, its
3629 color, the width of the box lines, and 3D appearance.
3630
3631Faces are frame-local by nature because Emacs allows to define the
3632same named face (face names are symbols) differently for different
3633frames. Each frame has an alist of face definitions for all named
3634faces. The value of a named face in such an alist is a Lisp vector
3635with the symbol `face' in slot 0, and a slot for each of the face
3636attributes mentioned above.
3637
3638There is also a global face alist `face-new-frame-defaults'. Face
3639definitions from this list are used to initialize faces of newly
3640created frames.
3641
3642A face doesn't have to specify all attributes. Those not specified
3643have a nil value. Faces specifying all attributes are called
3644`fully-specified'.
3645
3646*** Face merging.
3647
3648The display style of a given character in the text is determined by
3649combining several faces. This process is called `face merging'. Any
3650aspect of the display style that isn't specified by overlays or text
3651properties is taken from the `default' face. Since it is made sure
3652that the default face is always fully-specified, face merging always
3653results in a fully-specified face.
3654
3655*** Face realization.
3656
3657After all face attributes for a character have been determined by
3658merging faces of that character, that face is `realized'. The
3659realization process maps face attributes to what is physically
3660available on the system where Emacs runs. The result is a `realized
3661face' in form of an internal structure which is stored in the face
3662cache of the frame on which it was realized.
3663
3664Face realization is done in the context of the charset of the
3665character to display because different fonts and encodings are used
3666for different charsets. In other words, for characters of different
3667charsets, different realized faces are needed to display them.
3668
3669Except for composite characters, faces are always realized for a
3670specific character set and contain a specific font, even if the face
3671being realized specifies a fontset. The reason is that the result of
3672the new font selection stage is better than what can be done with
3673statically defined font name patterns in fontsets.
3674
3675In unibyte text, Emacs' charsets aren't applicable; function
3676`char-charset' reports ASCII for all characters, including those >
36770x7f. The X registry and encoding of fonts to use is determined from
3678the variable `face-default-registry' in this case. The variable is
3679initialized at Emacs startup time from the font the user specified for
3680Emacs.
3681
3682Currently all unibyte text, i.e. all buffers with
3683`enable-multibyte-characters' nil are displayed with fonts of the same
3684registry and encoding `face-default-registry'. This is consistent
3685with the fact that languages can also be set globally, only.
3686
3687**** Clearing face caches.
3688
3689The Lisp function `clear-face-cache' can be called to clear face caches
3690on all frames. If called with a non-nil argument, it will also unload
3691unused fonts.
3692
3693*** Font selection.
3694
3695Font selection tries to find the best available matching font for a
3696given (charset, face) combination. This is done slightly differently
3697for faces specifying a fontset, or a font family name.
3698
3699If the face specifies a fontset name, that fontset determines a
3700pattern for fonts of the given charset. If the face specifies a font
3701family, a font pattern is constructed. Charset symbols have a
3702property `x-charset-registry' for that purpose that maps a charset to
3703an XLFD registry and encoding in the font pattern constructed.
3704
3705Available fonts on the system on which Emacs runs are then matched
3706against the font pattern. The result of font selection is the best
3707match for the given face attributes in this font list.
3708
3709Font selection can be influenced by the user.
3710
3711The user can specify the relative importance he gives the face
3712attributes width, height, weight, and slant by setting
3713face-font-selection-order (faces.el) to a list of face attribute
3714names. The default is (:width :height :weight :slant), and means
3715that font selection first tries to find a good match for the font
3716width specified by a face, then---within fonts with that width---tries
3717to find a best match for the specified font height, etc.
3718
3719Setting `face-font-family-alternatives' allows the user to specify
3720alternative font families to try if a family specified by a face
3721doesn't exist.
3722
3723Setting `face-font-registry-alternatives' allows the user to specify
3724all alternative font registry names to try for a face specifying a
3725registry.
3726
3727Please note that the interpretations of the above two variables are
3728slightly different.
3729
3730Setting face-ignored-fonts allows the user to ignore specific fonts.
3731
3732
3733**** Scalable fonts
3734
3735Emacs can make use of scalable fonts but doesn't do so by default,
3736since the use of too many or too big scalable fonts may crash XFree86
3737servers.
3738
3739To enable scalable font use, set the variable
3740`scalable-fonts-allowed'. A value of nil, the default, means never use
3741scalable fonts. A value of t means any scalable font may be used.
3742Otherwise, the value must be a list of regular expressions. A
3743scalable font may then be used if it matches a regular expression from
3744that list. Example:
3745
3746 (setq scalable-fonts-allowed '("muleindian-2$"))
3747
3748allows the use of scalable fonts with registry `muleindian-2'.
3749
3750*** Functions and variables related to font selection.
3751
3752- Function: x-family-fonts &optional FAMILY FRAME
3753
3754Return a list of available fonts of family FAMILY on FRAME. If FAMILY
3755is omitted or nil, list all families. Otherwise, FAMILY must be a
3756string, possibly containing wildcards `?' and `*'.
3757
3758If FRAME is omitted or nil, use the selected frame. Each element of
3759the result is a vector [FAMILY WIDTH POINT-SIZE WEIGHT SLANT FIXED-P
3760FULL REGISTRY-AND-ENCODING]. FAMILY is the font family name.
3761POINT-SIZE is the size of the font in 1/10 pt. WIDTH, WEIGHT, and
3762SLANT are symbols describing the width, weight and slant of the font.
3763These symbols are the same as for face attributes. FIXED-P is non-nil
3764if the font is fixed-pitch. FULL is the full name of the font, and
3765REGISTRY-AND-ENCODING is a string giving the registry and encoding of
3766the font. The result list is sorted according to the current setting
3767of the face font sort order.
3768
3769- Function: x-font-family-list
3770
3771Return a list of available font families on FRAME. If FRAME is
3772omitted or nil, use the selected frame. Value is a list of conses
3773(FAMILY . FIXED-P) where FAMILY is a font family, and FIXED-P is
3774non-nil if fonts of that family are fixed-pitch.
3775
3776- Variable: font-list-limit
3777
3778Limit for font matching. If an integer > 0, font matching functions
3779won't load more than that number of fonts when searching for a
3780matching font. The default is currently 100.
3781
3782*** Setting face attributes.
3783
3784For the most part, the new face implementation is interface-compatible
3785with the old one. Old face attribute related functions are now
3786implemented in terms of the new functions `set-face-attribute' and
3787`face-attribute'.
3788
3789Face attributes are identified by their names which are keyword
3790symbols. All attributes can be set to `unspecified'.
3791
3792The following attributes are recognized:
3793
3794`:family'
3795
3796VALUE must be a string specifying the font family, e.g. ``courier'',
3797or a fontset alias name. If a font family is specified, wild-cards `*'
3798and `?' are allowed.
3799
3800`:width'
3801
3802VALUE specifies the relative proportionate width of the font to use.
3803It must be one of the symbols `ultra-condensed', `extra-condensed',
3804`condensed', `semi-condensed', `normal', `semi-expanded', `expanded',
3805`extra-expanded', or `ultra-expanded'.
3806
3807`:height'
3808
3809VALUE must be either an integer specifying the height of the font to use
3810in 1/10 pt, a floating point number specifying the amount by which to
3811scale any underlying face, or a function, which is called with the old
3812height (from the underlying face), and should return the new height.
3813
3814`:weight'
3815
3816VALUE specifies the weight of the font to use. It must be one of the
3817symbols `ultra-bold', `extra-bold', `bold', `semi-bold', `normal',
3818`semi-light', `light', `extra-light', `ultra-light'.
3819
3820`:slant'
3821
3822VALUE specifies the slant of the font to use. It must be one of the
3823symbols `italic', `oblique', `normal', `reverse-italic', or
3824`reverse-oblique'.
3825
3826`:foreground', `:background'
3827
3828VALUE must be a color name, a string.
3829
3830`:underline'
3831
3832VALUE specifies whether characters in FACE should be underlined. If
3833VALUE is t, underline with foreground color of the face. If VALUE is
3834a string, underline with that color. If VALUE is nil, explicitly
3835don't underline.
3836
3837`:overline'
3838
3839VALUE specifies whether characters in FACE should be overlined. If
3840VALUE is t, overline with foreground color of the face. If VALUE is a
3841string, overline with that color. If VALUE is nil, explicitly don't
3842overline.
3843
3844`:strike-through'
3845
3846VALUE specifies whether characters in FACE should be drawn with a line
3847striking through them. If VALUE is t, use the foreground color of the
3848face. If VALUE is a string, strike-through with that color. If VALUE
3849is nil, explicitly don't strike through.
3850
3851`:box'
3852
3853VALUE specifies whether characters in FACE should have a box drawn
3854around them. If VALUE is nil, explicitly don't draw boxes. If
3855VALUE is t, draw a box with lines of width 1 in the foreground color
3856of the face. If VALUE is a string, the string must be a color name,
3857and the box is drawn in that color with a line width of 1. Otherwise,
3858VALUE must be a property list of the form `(:line-width WIDTH
3859:color COLOR :style STYLE)'. If a keyword/value pair is missing from
3860the property list, a default value will be used for the value, as
3861specified below. WIDTH specifies the width of the lines to draw; it
3862defaults to 1. COLOR is the name of the color to draw in, default is
3863the foreground color of the face for simple boxes, and the background
3864color of the face for 3D boxes. STYLE specifies whether a 3D box
3865should be draw. If STYLE is `released-button', draw a box looking
3866like a released 3D button. If STYLE is `pressed-button' draw a box
3867that appears like a pressed button. If STYLE is nil, the default if
3868the property list doesn't contain a style specification, draw a 2D
3869box.
3870
3871`:inverse-video'
3872
3873VALUE specifies whether characters in FACE should be displayed in
3874inverse video. VALUE must be one of t or nil.
3875
3876`:stipple'
3877
3878If VALUE is a string, it must be the name of a file of pixmap data.
3879The directories listed in the `x-bitmap-file-path' variable are
3880searched. Alternatively, VALUE may be a list of the form (WIDTH
3881HEIGHT DATA) where WIDTH and HEIGHT are the size in pixels, and DATA
3882is a string containing the raw bits of the bitmap. VALUE nil means
3883explicitly don't use a stipple pattern.
3884
3885For convenience, attributes `:family', `:width', `:height', `:weight',
3886and `:slant' may also be set in one step from an X font name:
3887
3888`:font'
3889
3890Set font-related face attributes from VALUE. VALUE must be a valid
3891XLFD font name. If it is a font name pattern, the first matching font
3892is used--this is for compatibility with the behavior of previous
3893versions of Emacs.
3894
3895For compatibility with Emacs 20, keywords `:bold' and `:italic' can
3896be used to specify that a bold or italic font should be used. VALUE
3897must be t or nil in that case. A value of `unspecified' is not allowed."
3898
3899Please see also the documentation of `set-face-attribute' and
3900`defface'.
3901
3902`:inherit'
3903
3904VALUE is the name of a face from which to inherit attributes, or a list
3905of face names. Attributes from inherited faces are merged into the face
3906like an underlying face would be, with higher priority than underlying faces.
3907
3908*** Face attributes and X resources
3909
3910The following X resource names can be used to set face attributes
3911from X resources:
3912
3913 Face attribute X resource class
3914-----------------------------------------------------------------------
3915 :family attributeFamily . Face.AttributeFamily
3916 :width attributeWidth Face.AttributeWidth
3917 :height attributeHeight Face.AttributeHeight
3918 :weight attributeWeight Face.AttributeWeight
3919 :slant attributeSlant Face.AttributeSlant
3920 foreground attributeForeground Face.AttributeForeground
3921 :background attributeBackground . Face.AttributeBackground
3922 :overline attributeOverline Face.AttributeOverline
3923 :strike-through attributeStrikeThrough Face.AttributeStrikeThrough
3924 :box attributeBox Face.AttributeBox
3925 :underline attributeUnderline Face.AttributeUnderline
3926 :inverse-video attributeInverse Face.AttributeInverse
3927 :stipple attributeStipple Face.AttributeStipple
3928 or attributeBackgroundPixmap
3929 Face.AttributeBackgroundPixmap
3930 :font attributeFont Face.AttributeFont
3931 :bold attributeBold Face.AttributeBold
3932 :italic attributeItalic . Face.AttributeItalic
3933 :font attributeFont Face.AttributeFont
3934
3935*** Text property `face'.
3936
3937The value of the `face' text property can now be a single face
3938specification or a list of such specifications. Each face
3939specification can be
3940
39411. A symbol or string naming a Lisp face.
3942
39432. A property list of the form (KEYWORD VALUE ...) where each
3944 KEYWORD is a face attribute name, and VALUE is an appropriate value
3945 for that attribute. Please see the doc string of `set-face-attribute'
3946 for face attribute names.
3947
39483. Conses of the form (FOREGROUND-COLOR . COLOR) or
3949 (BACKGROUND-COLOR . COLOR) where COLOR is a color name. This is
3950 for compatibility with previous Emacs versions.
3951
3952** Support functions for colors on text-only terminals.
3953
3954The function `tty-color-define' can be used to define colors for use
3955on TTY and MSDOS frames. It maps a color name to a color number on
3956the terminal. Emacs defines a couple of common color mappings by
3957default. You can get defined colors with a call to
3958`defined-colors'. The function `tty-color-clear' can be
3959used to clear the mapping table.
3960
3961** Unified support for colors independent of frame type.
3962
3963The new functions `defined-colors', `color-defined-p', `color-values',
3964and `display-color-p' work for any type of frame. On frames whose
3965type is neither x nor w32, these functions transparently map X-style
3966color specifications to the closest colors supported by the frame
3967display. Lisp programs should use these new functions instead of the
3968old `x-defined-colors', `x-color-defined-p', `x-color-values', and
3969`x-display-color-p'. (The old function names are still available for
3970compatibility; they are now aliases of the new names.) Lisp programs
3971should no more look at the value of the variable window-system to
3972modify their color-related behavior.
3973
3974The primitives `color-gray-p' and `color-supported-p' also work for
3975any frame type.
3976
3977** Platform-independent functions to describe display capabilities.
3978
3979The new functions `display-mouse-p', `display-popup-menus-p',
3980`display-graphic-p', `display-selections-p', `display-screens',
3981`display-pixel-width', `display-pixel-height', `display-mm-width',
3982`display-mm-height', `display-backing-store', `display-save-under',
3983`display-planes', `display-color-cells', `display-visual-class', and
3984`display-grayscale-p' describe the basic capabilities of a particular
3985display. Lisp programs should call these functions instead of testing
3986the value of the variables `window-system' or `system-type', or calling
3987platform-specific functions such as `x-display-pixel-width'.
3988
3989The new function `display-images-p' returns non-nil if a particular
3990display can display image files.
3991
3992** The minibuffer prompt is now actually inserted in the minibuffer.
3993
3994This makes it possible to scroll through the prompt, if you want to.
3995To disallow this completely (like previous versions of emacs), customize
3996the variable `minibuffer-prompt-properties', and turn on the
3997`Inviolable' option.
3998
3999The function `minibuffer-prompt-end' returns the current position of the
4000end of the minibuffer prompt, if the minibuffer is current.
4001Otherwise, it returns `(point-min)'.
4002
4003** New `field' abstraction in buffers.
4004
4005There is now code to support an abstraction called `fields' in emacs
4006buffers. A field is a contiguous region of text with the same `field'
4007property (which can be a text property or an overlay).
4008
4009Many emacs functions, such as forward-word, forward-sentence,
4010forward-paragraph, beginning-of-line, etc., stop moving when they come
4011to the boundary between fields; beginning-of-line and end-of-line will
4012not let the point move past the field boundary, but other movement
4013commands continue into the next field if repeated. Stopping at field
4014boundaries can be suppressed programmatically by binding
4015`inhibit-field-text-motion' to a non-nil value around calls to these
4016functions.
4017
4018Now that the minibuffer prompt is inserted into the minibuffer, it is in
4019a separate field from the user-input part of the buffer, so that common
4020editing commands treat the user's text separately from the prompt.
4021
4022The following functions are defined for operating on fields:
4023
4024- Function: constrain-to-field NEW-POS OLD-POS &optional ESCAPE-FROM-EDGE ONLY-IN-LINE INHIBIT-CAPTURE-PROPERTY
4025
4026Return the position closest to NEW-POS that is in the same field as OLD-POS.
4027
4028A field is a region of text with the same `field' property.
4029If NEW-POS is nil, then the current point is used instead, and set to the
4030constrained position if that is different.
4031
4032If OLD-POS is at the boundary of two fields, then the allowable
4033positions for NEW-POS depends on the value of the optional argument
4034ESCAPE-FROM-EDGE: If ESCAPE-FROM-EDGE is nil, then NEW-POS is
4035constrained to the field that has the same `field' char-property
4036as any new characters inserted at OLD-POS, whereas if ESCAPE-FROM-EDGE
4037is non-nil, NEW-POS is constrained to the union of the two adjacent
4038fields. Additionally, if two fields are separated by another field with
4039the special value `boundary', then any point within this special field is
4040also considered to be `on the boundary'.
4041
4042If the optional argument ONLY-IN-LINE is non-nil and constraining
4043NEW-POS would move it to a different line, NEW-POS is returned
4044unconstrained. This useful for commands that move by line, like
4045C-n or C-a, which should generally respect field boundaries
4046only in the case where they can still move to the right line.
4047
4048If the optional argument INHIBIT-CAPTURE-PROPERTY is non-nil, and OLD-POS has
4049a non-nil property of that name, then any field boundaries are ignored.
4050
4051Field boundaries are not noticed if `inhibit-field-text-motion' is non-nil.
4052
4053- Function: delete-field &optional POS
4054
4055Delete the field surrounding POS.
4056A field is a region of text with the same `field' property.
4057If POS is nil, the value of point is used for POS.
4058
4059- Function: field-beginning &optional POS ESCAPE-FROM-EDGE
4060
4061Return the beginning of the field surrounding POS.
4062A field is a region of text with the same `field' property.
4063If POS is nil, the value of point is used for POS.
4064If ESCAPE-FROM-EDGE is non-nil and POS is at the beginning of its
4065field, then the beginning of the *previous* field is returned.
4066
4067- Function: field-end &optional POS ESCAPE-FROM-EDGE
4068
4069Return the end of the field surrounding POS.
4070A field is a region of text with the same `field' property.
4071If POS is nil, the value of point is used for POS.
4072If ESCAPE-FROM-EDGE is non-nil and POS is at the end of its field,
4073then the end of the *following* field is returned.
4074
4075- Function: field-string &optional POS
4076
4077Return the contents of the field surrounding POS as a string.
4078A field is a region of text with the same `field' property.
4079If POS is nil, the value of point is used for POS.
4080
4081- Function: field-string-no-properties &optional POS
4082
4083Return the contents of the field around POS, without text-properties.
4084A field is a region of text with the same `field' property.
4085If POS is nil, the value of point is used for POS.
4086
4087** Image support.
4088
4089Emacs can now display images. Images are inserted into text by giving
4090strings or buffer text a `display' text property containing one of
4091(AREA IMAGE) or IMAGE. The display of the `display' property value
4092replaces the display of the characters having that property.
4093
4094If the property value has the form (AREA IMAGE), AREA must be one of
4095`(margin left-margin)', `(margin right-margin)' or `(margin nil)'. If
4096AREA is `(margin nil)', IMAGE will be displayed in the text area of a
4097window, otherwise it will be displayed in the left or right marginal
4098area.
4099
4100IMAGE is an image specification.
4101
4102*** Image specifications
4103
4104Image specifications are lists of the form `(image PROPS)' where PROPS
4105is a property list whose keys are keyword symbols. Each
4106specifications must contain a property `:type TYPE' with TYPE being a
4107symbol specifying the image type, e.g. `xbm'. Properties not
4108described below are ignored.
4109
4110The following is a list of properties all image types share.
4111
4112`:ascent ASCENT'
4113
4114ASCENT must be a number in the range 0..100, or the symbol `center'.
4115If it is a number, it specifies the percentage of the image's height
4116to use for its ascent.
4117
4118If not specified, ASCENT defaults to the value 50 which means that the
4119image will be centered with the base line of the row it appears in.
4120
4121If ASCENT is `center' the image is vertically centered around a
4122centerline which is the vertical center of text drawn at the position
4123of the image, in the manner specified by the text properties and
4124overlays that apply to the image.
4125
4126`:margin MARGIN'
4127
4128MARGIN must be either a number >= 0 specifying how many pixels to put
4129as margin around the image, or a pair (X . Y) with X specifying the
4130horizontal margin and Y specifying the vertical margin. Default is 0.
4131
4132`:relief RELIEF'
4133
4134RELIEF is analogous to the `:relief' attribute of faces. Puts a relief
4135around an image.
4136
4137`:conversion ALGO'
4138
4139Apply an image algorithm to the image before displaying it.
4140
4141ALGO `laplace' or `emboss' means apply a Laplace or ``emboss''
4142edge-detection algorithm to the image.
4143
4144ALGO `(edge-detection :matrix MATRIX :color-adjust ADJUST)' means
4145apply a general edge-detection algorithm. MATRIX must be either a
4146nine-element list or a nine-element vector of numbers. A pixel at
4147position x/y in the transformed image is computed from original pixels
4148around that position. MATRIX specifies, for each pixel in the
4149neighborhood of x/y, a factor with which that pixel will influence the
4150transformed pixel; element 0 specifies the factor for the pixel at
4151x-1/y-1, element 1 the factor for the pixel at x/y-1 etc. as shown
4152below.
4153
4154 (x-1/y-1 x/y-1 x+1/y-1
4155 x-1/y x/y x+1/y
4156 x-1/y+1 x/y+1 x+1/y+1)
4157
4158The resulting pixel is computed from the color intensity of the color
4159resulting from summing up the RGB values of surrounding pixels,
4160multiplied by the specified factors, and dividing that sum by the sum
4161of the factors' absolute values.
4162
4163Laplace edge-detection currently uses a matrix of
4164
4165 (1 0 0
4166 0 0 0
4167 9 9 -1)
4168
4169Emboss edge-detection uses a matrix of
4170
4171 ( 2 -1 0
4172 -1 0 1
4173 0 1 -2)
4174
4175ALGO `disabled' means transform the image so that it looks
4176``disabled''.
4177
4178`:mask MASK'
4179
4180If MASK is `heuristic' or `(heuristic BG)', build a clipping mask for
4181the image, so that the background of a frame is visible behind the
4182image. If BG is not specified, or if BG is t, determine the
4183background color of the image by looking at the 4 corners of the
4184image, assuming the most frequently occurring color from the corners is
4185the background color of the image. Otherwise, BG must be a list `(RED
4186GREEN BLUE)' specifying the color to assume for the background of the
4187image.
4188
4189If MASK is nil, remove a mask from the image, if it has one. Images
4190in some formats include a mask which can be removed by specifying
4191`:mask nil'.
4192
4193`:file FILE'
4194
4195Load image from FILE. If FILE is not absolute after expanding it,
4196search for the image in `data-directory'. Some image types support
4197building images from data. When this is done, no `:file' property
4198may be present in the image specification.
4199
4200`:data DATA'
4201
4202Get image data from DATA. (As of this writing, this is not yet
4203supported for image type `postscript'). Either :file or :data may be
4204present in an image specification, but not both. All image types
4205support strings as DATA, some types allow additional types of DATA.
4206
4207*** Supported image types
4208
4209**** XBM, image type `xbm'.
4210
4211XBM images don't require an external library. Additional image
4212properties supported are:
4213
4214`:foreground FG'
4215
4216FG must be a string specifying the image foreground color, or nil
4217meaning to use the default. Default is the frame's foreground color.
4218
4219`:background BG'
4220
4221BG must be a string specifying the image background color, or nil
4222meaning to use the default. Default is the frame's background color.
4223
4224XBM images can be constructed from data instead of file. In this
4225case, the image specification must contain the following properties
4226instead of a `:file' property.
4227
4228`:width WIDTH'
4229
4230WIDTH specifies the width of the image in pixels.
4231
4232`:height HEIGHT'
4233
4234HEIGHT specifies the height of the image in pixels.
4235
4236`:data DATA'
4237
4238DATA must be either
4239
4240 1. a string large enough to hold the bitmap data, i.e. it must
4241 have a size >= (WIDTH + 7) / 8 * HEIGHT
4242
4243 2. a bool-vector of size >= WIDTH * HEIGHT
4244
4245 3. a vector of strings or bool-vectors, one for each line of the
4246 bitmap.
4247
4248 4. a string that's an in-memory XBM file. Neither width nor
4249 height may be specified in this case because these are defined
4250 in the file.
4251
4252**** XPM, image type `xpm'
4253
4254XPM images require the external library `libXpm', package
4255`xpm-3.4k.tar.gz', version 3.4k or later. Make sure the library is
4256found when Emacs is configured by supplying appropriate paths via
4257`--x-includes' and `--x-libraries'.
4258
4259Additional image properties supported are:
4260
4261`:color-symbols SYMBOLS'
4262
4263SYMBOLS must be a list of pairs (NAME . COLOR), with NAME being the
4264name of color as it appears in an XPM file, and COLOR being an X color
4265name.
4266
4267XPM images can be built from memory instead of files. In that case,
4268add a `:data' property instead of a `:file' property.
4269
4270The XPM library uses libz in its implementation so that it is able
4271to display compressed images.
4272
4273**** PBM, image type `pbm'
4274
4275PBM images don't require an external library. Color, gray-scale and
4276mono images are supported. Additional image properties supported for
4277mono images are:
4278
4279`:foreground FG'
4280
4281FG must be a string specifying the image foreground color, or nil
4282meaning to use the default. Default is the frame's foreground color.
4283
4284`:background FG'
4285
4286BG must be a string specifying the image background color, or nil
4287meaning to use the default. Default is the frame's background color.
4288
4289**** JPEG, image type `jpeg'
4290
4291Support for JPEG images requires the external library `libjpeg',
4292package `jpegsrc.v6a.tar.gz', or later. There are no additional image
4293properties defined.
4294
4295**** TIFF, image type `tiff'
4296
4297Support for TIFF images requires the external library `libtiff',
4298package `tiff-v3.4-tar.gz', or later. There are no additional image
4299properties defined.
4300
4301**** GIF, image type `gif'
4302
4303Support for GIF images requires the external library `libungif', package
4304`libungif-4.1.0', or later.
4305
4306Additional image properties supported are:
4307
4308`:index INDEX'
4309
4310INDEX must be an integer >= 0. Load image number INDEX from a
4311multi-image GIF file. If INDEX is too large, the image displays
4312as a hollow box.
4313
4314This could be used to implement limited support for animated GIFs.
4315For example, the following function displays a multi-image GIF file
4316at point-min in the current buffer, switching between sub-images
4317every 0.1 seconds.
4318
4319(defun show-anim (file max)
4320 "Display multi-image GIF file FILE which contains MAX subimages."
4321 (display-anim (current-buffer) file 0 max t))
4322
4323(defun display-anim (buffer file idx max first-time)
4324 (when (= idx max)
4325 (setq idx 0))
4326 (let ((img (create-image file nil nil :index idx)))
4327 (save-excursion
4328 (set-buffer buffer)
4329 (goto-char (point-min))
4330 (unless first-time (delete-char 1))
4331 (insert-image img "x"))
4332 (run-with-timer 0.1 nil 'display-anim buffer file (1+ idx) max nil)))
4333
4334**** PNG, image type `png'
4335
4336Support for PNG images requires the external library `libpng',
4337package `libpng-1.0.2.tar.gz', or later. There are no additional image
4338properties defined.
4339
4340**** Ghostscript, image type `postscript'.
4341
4342Additional image properties supported are:
4343
4344`:pt-width WIDTH'
4345
4346WIDTH is width of the image in pt (1/72 inch). WIDTH must be an
4347integer. This is a required property.
4348
4349`:pt-height HEIGHT'
4350
4351HEIGHT specifies the height of the image in pt (1/72 inch). HEIGHT
4352must be a integer. This is an required property.
4353
4354`:bounding-box BOX'
4355
4356BOX must be a list or vector of 4 integers giving the bounding box of
4357the PS image, analogous to the `BoundingBox' comment found in PS
4358files. This is an required property.
4359
4360Part of the Ghostscript interface is implemented in Lisp. See
4361lisp/gs.el.
4362
4363*** Lisp interface.
4364
4365The variable `image-types' contains a list of those image types
4366which are supported in the current configuration.
4367
4368Images are stored in an image cache and removed from the cache when
4369they haven't been displayed for `image-cache-eviction-delay seconds.
4370The function `clear-image-cache' can be used to clear the image cache
4371manually. Images in the cache are compared with `equal', i.e. all
4372images with `equal' specifications share the same image.
4373
4374*** Simplified image API, image.el
4375
4376The new Lisp package image.el contains functions that simplify image
4377creation and putting images into text. The function `create-image'
4378can be used to create images. The macro `defimage' can be used to
4379define an image based on available image types. The functions
4380`put-image' and `insert-image' can be used to insert an image into a
4381buffer.
4382
4383** Display margins.
4384
4385Windows can now have margins which are used for special text
4386and images.
4387
4388To give a window margins, either set the buffer-local variables
4389`left-margin-width' and `right-margin-width', or call
4390`set-window-margins'. The function `window-margins' can be used to
4391obtain the current settings. To make `left-margin-width' and
4392`right-margin-width' take effect, you must set them before displaying
4393the buffer in a window, or use `set-window-buffer' to force an update
4394of the display margins.
4395
4396You can put text in margins by giving it a `display' text property
4397containing a pair of the form `(LOCATION . VALUE)', where LOCATION is
4398one of `left-margin' or `right-margin' or nil. VALUE can be either a
4399string, an image specification or a stretch specification (see later
4400in this file).
4401
4402** Help display
4403
4404Emacs displays short help messages in the echo area, when the mouse
4405moves over a tool-bar item or a piece of text that has a text property
4406`help-echo'. This feature also applies to strings in the mode line
4407that have a `help-echo' property.
4408
4409If the value of the `help-echo' property is a function, that function
4410is called with three arguments WINDOW, OBJECT and POSITION. WINDOW is
4411the window in which the help was found.
4412
4413If OBJECT is a buffer, POS is the position in the buffer where the
4414`help-echo' text property was found.
4415
4416If OBJECT is an overlay, that overlay has a `help-echo' property, and
4417POS is the position in the overlay's buffer under the mouse.
4418
4419If OBJECT is a string (an overlay string or a string displayed with
4420the `display' property), POS is the position in that string under the
4421mouse.
4422
4423If the value of the `help-echo' property is neither a function nor a
4424string, it is evaluated to obtain a help string.
4425
4426For tool-bar and menu-bar items, their key definition is used to
4427determine the help to display. If their definition contains a
4428property `:help FORM', FORM is evaluated to determine the help string.
4429For tool-bar items without a help form, the caption of the item is
4430used as help string.
4431
4432The hook `show-help-function' can be set to a function that displays
4433the help string differently. For example, enabling a tooltip window
4434causes the help display to appear there instead of in the echo area.
4435
4436** Vertical fractional scrolling.
4437
4438The display of text in windows can be scrolled smoothly in pixels.
4439This is useful, for example, for making parts of large images visible.
4440
4441The function `window-vscroll' returns the current value of vertical
4442scrolling, a non-negative fraction of the canonical character height.
4443The function `set-window-vscroll' can be used to set the vertical
4444scrolling value. Here is an example of how these function might be
4445used.
4446
4447 (global-set-key [A-down]
4448 #'(lambda ()
4449 (interactive)
4450 (set-window-vscroll (selected-window)
4451 (+ 0.5 (window-vscroll)))))
4452 (global-set-key [A-up]
4453 #'(lambda ()
4454 (interactive)
4455 (set-window-vscroll (selected-window)
4456 (- (window-vscroll) 0.5)))))
4457
4458** New hook `fontification-functions'.
4459
4460Functions from `fontification-functions' are called from redisplay
4461when it encounters a region of text that is not yet fontified. This
4462variable automatically becomes buffer-local when set. Each function
4463is called with one argument, POS.
4464
4465At least one of the hook functions should fontify one or more
4466characters starting at POS in the current buffer. It should mark them
4467as fontified by giving them a non-nil value of the `fontified' text
4468property. It may be reasonable for these functions to check for the
4469`fontified' property and not put it back on, but they do not have to.
4470
4471** Tool bar support.
4472
4473Emacs supports a tool bar at the top of a frame under X. The frame
4474parameter `tool-bar-lines' (X resource "toolBar", class "ToolBar")
4475controls how may lines to reserve for the tool bar. A zero value
4476suppresses the tool bar. If the value is non-zero and
4477`auto-resize-tool-bars' is non-nil the tool bar's size will be changed
4478automatically so that all tool bar items are visible.
4479
4480*** Tool bar item definitions
4481
4482Tool bar items are defined using `define-key' with a prefix-key
4483`tool-bar'. For example `(define-key global-map [tool-bar item1] ITEM)'
4484where ITEM is a list `(menu-item CAPTION BINDING PROPS...)'.
4485
4486CAPTION is the caption of the item, If it's not a string, it is
4487evaluated to get a string. The caption is currently not displayed in
4488the tool bar, but it is displayed if the item doesn't have a `:help'
4489property (see below).
4490
4491BINDING is the tool bar item's binding. Tool bar items with keymaps as
4492binding are currently ignored.
4493
4494The following properties are recognized:
4495
4496`:enable FORM'.
4497
4498FORM is evaluated and specifies whether the tool bar item is enabled
4499or disabled.
4500
4501`:visible FORM'
4502
4503FORM is evaluated and specifies whether the tool bar item is displayed.
4504
4505`:filter FUNCTION'
4506
4507FUNCTION is called with one parameter, the same list BINDING in which
4508FUNCTION is specified as the filter. The value FUNCTION returns is
4509used instead of BINDING to display this item.
4510
4511`:button (TYPE SELECTED)'
4512
4513TYPE must be one of `:radio' or `:toggle'. SELECTED is evaluated
4514and specifies whether the button is selected (pressed) or not.
4515
4516`:image IMAGES'
4517
4518IMAGES is either a single image specification or a vector of four
4519image specifications. If it is a vector, this table lists the
4520meaning of each of the four elements:
4521
4522 Index Use when item is
4523 ----------------------------------------
4524 0 enabled and selected
4525 1 enabled and deselected
4526 2 disabled and selected
4527 3 disabled and deselected
4528
4529If IMAGE is a single image specification, a Laplace edge-detection
4530algorithm is used on that image to draw the image in disabled state.
4531
4532`:help HELP-STRING'.
4533
4534Gives a help string to display for the tool bar item. This help
4535is displayed when the mouse is moved over the item.
4536
4537The function `toolbar-add-item' is a convenience function for adding
4538toolbar items generally, and `tool-bar-add-item-from-menu' can be used
4539to define a toolbar item with a binding copied from an item on the
4540menu bar.
4541
4542The default bindings use a menu-item :filter to derive the tool-bar
4543dynamically from variable `tool-bar-map' which may be set
4544buffer-locally to override the global map.
4545
4546*** Tool-bar-related variables.
4547
4548If `auto-resize-tool-bar' is non-nil, the tool bar will automatically
4549resize to show all defined tool bar items. It will never grow larger
4550than 1/4 of the frame's size.
4551
4552If `auto-raise-tool-bar-buttons' is non-nil, tool bar buttons will be
4553raised when the mouse moves over them.
4554
4555You can add extra space between tool bar items by setting
4556`tool-bar-button-margin' to a positive integer specifying a number of
4557pixels, or a pair of integers (X . Y) specifying horizontal and
4558vertical margins . Default is 1.
4559
4560You can change the shadow thickness of tool bar buttons by setting
4561`tool-bar-button-relief' to an integer. Default is 3.
4562
4563*** Tool-bar clicks with modifiers.
4564
4565You can bind commands to clicks with control, shift, meta etc. on
4566a tool bar item. If
4567
4568 (define-key global-map [tool-bar shell]
4569 '(menu-item "Shell" shell
4570 :image (image :type xpm :file "shell.xpm")))
4571
4572is the original tool bar item definition, then
4573
4574 (define-key global-map [tool-bar S-shell] 'some-command)
4575
4576makes a binding to run `some-command' for a shifted click on the same
4577item.
4578
4579** Mode line changes.
4580
4581*** Mouse-sensitive mode line.
4582
4583The mode line can be made mouse-sensitive by displaying strings there
4584that have a `local-map' text property. There are three ways to display
4585a string with a `local-map' property in the mode line.
4586
45871. The mode line spec contains a variable whose string value has
4588a `local-map' text property.
4589
45902. The mode line spec contains a format specifier (e.g. `%12b'), and
4591that format specifier has a `local-map' property.
4592
45933. The mode line spec contains a list containing `:eval FORM'. FORM
4594is evaluated. If the result is a string, and that string has a
4595`local-map' property.
4596
4597The same mechanism is used to determine the `face' and `help-echo'
4598properties of strings in the mode line. See `bindings.el' for an
4599example.
4600
4601*** If a mode line element has the form `(:eval FORM)', FORM is
4602evaluated and the result is used as mode line element.
4603
4604*** You can suppress mode-line display by setting the buffer-local
4605variable mode-line-format to nil.
4606
4607*** A headerline can now be displayed at the top of a window.
4608
4609This mode line's contents are controlled by the new variable
4610`header-line-format' and `default-header-line-format' which are
4611completely analogous to `mode-line-format' and
4612`default-mode-line-format'. A value of nil means don't display a top
4613line.
4614
4615The appearance of top mode lines is controlled by the face
4616`header-line'.
4617
4618The function `coordinates-in-window-p' returns `header-line' for a
4619position in the header-line.
4620
4621** Text property `display'
4622
4623The `display' text property is used to insert images into text,
4624replace text with other text, display text in marginal area, and it is
4625also used to control other aspects of how text displays. The value of
4626the `display' property should be a display specification, as described
4627below, or a list or vector containing display specifications.
4628
4629*** Replacing text, displaying text in marginal areas
4630
4631To replace the text having the `display' property with some other
4632text, use a display specification of the form `(LOCATION STRING)'.
4633
4634If LOCATION is `(margin left-margin)', STRING is displayed in the left
4635marginal area, if it is `(margin right-margin)', it is displayed in
4636the right marginal area, and if LOCATION is `(margin nil)' STRING
4637is displayed in the text. In the latter case you can also use the
4638simpler form STRING as property value.
4639
4640*** Variable width and height spaces
4641
4642To display a space of fractional width or height, use a display
4643specification of the form `(LOCATION STRECH)'. If LOCATION is
4644`(margin left-margin)', the space is displayed in the left marginal
4645area, if it is `(margin right-margin)', it is displayed in the right
4646marginal area, and if LOCATION is `(margin nil)' the space is
4647displayed in the text. In the latter case you can also use the
4648simpler form STRETCH as property value.
4649
4650The stretch specification STRETCH itself is a list of the form `(space
4651PROPS)', where PROPS is a property list which can contain the
4652properties described below.
4653
4654The display of the fractional space replaces the display of the
4655characters having the `display' property.
4656
4657- :width WIDTH
4658
4659Specifies that the space width should be WIDTH times the normal
4660character width. WIDTH can be an integer or floating point number.
4661
4662- :relative-width FACTOR
4663
4664Specifies that the width of the stretch should be computed from the
4665first character in a group of consecutive characters that have the
4666same `display' property. The computation is done by multiplying the
4667width of that character by FACTOR.
4668
4669- :align-to HPOS
4670
4671Specifies that the space should be wide enough to reach HPOS. The
4672value HPOS is measured in units of the normal character width.
4673
4674Exactly one of the above properties should be used.
4675
4676- :height HEIGHT
4677
4678Specifies the height of the space, as HEIGHT, measured in terms of the
4679normal line height.
4680
4681- :relative-height FACTOR
4682
4683The height of the space is computed as the product of the height
4684of the text having the `display' property and FACTOR.
4685
4686- :ascent ASCENT
4687
4688Specifies that ASCENT percent of the height of the stretch should be
4689used for the ascent of the stretch, i.e. for the part above the
4690baseline. The value of ASCENT must be a non-negative number less or
4691equal to 100.
4692
4693You should not use both `:height' and `:relative-height' together.
4694
4695*** Images
4696
4697A display specification for an image has the form `(LOCATION
4698. IMAGE)', where IMAGE is an image specification. The image replaces,
4699in the display, the characters having this display specification in
4700their `display' text property. If LOCATION is `(margin left-margin)',
4701the image will be displayed in the left marginal area, if it is
4702`(margin right-margin)' it will be displayed in the right marginal
4703area, and if LOCATION is `(margin nil)' the image will be displayed in
4704the text. In the latter case you can also use the simpler form IMAGE
4705as display specification.
4706
4707*** Other display properties
4708
4709- (space-width FACTOR)
4710
4711Specifies that space characters in the text having that property
4712should be displayed FACTOR times as wide as normal; FACTOR must be an
4713integer or float.
4714
4715- (height HEIGHT)
4716
4717Display text having this property in a font that is smaller or larger.
4718
4719If HEIGHT is a list of the form `(+ N)', where N is an integer, that
4720means to use a font that is N steps larger. If HEIGHT is a list of
4721the form `(- N)', that means to use a font that is N steps smaller. A
4722``step'' is defined by the set of available fonts; each size for which
4723a font is available counts as a step.
4724
4725If HEIGHT is a number, that means to use a font that is HEIGHT times
4726as tall as the frame's default font.
4727
4728If HEIGHT is a symbol, it is called as a function with the current
4729height as argument. The function should return the new height to use.
4730
4731Otherwise, HEIGHT is evaluated to get the new height, with the symbol
4732`height' bound to the current specified font height.
4733
4734- (raise FACTOR)
4735
4736FACTOR must be a number, specifying a multiple of the current
4737font's height. If it is positive, that means to display the characters
4738raised. If it is negative, that means to display them lower down. The
4739amount of raising or lowering is computed without taking account of the
4740`height' subproperty.
4741
4742*** Conditional display properties
4743
4744All display specifications can be conditionalized. If a specification
4745has the form `(when CONDITION . SPEC)', the specification SPEC applies
4746only when CONDITION yields a non-nil value when evaluated. During the
4747evaluation, `object' is bound to the string or buffer having the
4748conditional display property; `position' and `buffer-position' are
4749bound to the position within `object' and the buffer position where
4750the display property was found, respectively. Both positions can be
4751different when object is a string.
4752
4753The normal specification consisting of SPEC only is equivalent to
4754`(when t . SPEC)'.
4755
4756** New menu separator types.
4757
4758Emacs now supports more than one menu separator type. Menu items with
4759item names consisting of dashes only (including zero dashes) are
4760treated like before. In addition, the following item names are used
4761to specify other menu separator types.
4762
4763- `--no-line' or `--space', or `--:space', or `--:noLine'
4764
4765No separator lines are drawn, but a small space is inserted where the
4766separator occurs.
4767
4768- `--single-line' or `--:singleLine'
4769
4770A single line in the menu's foreground color.
4771
4772- `--double-line' or `--:doubleLine'
4773
4774A double line in the menu's foreground color.
4775
4776- `--single-dashed-line' or `--:singleDashedLine'
4777
4778A single dashed line in the menu's foreground color.
4779
4780- `--double-dashed-line' or `--:doubleDashedLine'
4781
4782A double dashed line in the menu's foreground color.
4783
4784- `--shadow-etched-in' or `--:shadowEtchedIn'
4785
4786A single line with 3D sunken appearance. This is the form
4787displayed for item names consisting of dashes only.
4788
4789- `--shadow-etched-out' or `--:shadowEtchedOut'
4790
4791A single line with 3D raised appearance.
4792
4793- `--shadow-etched-in-dash' or `--:shadowEtchedInDash'
4794
4795A single dashed line with 3D sunken appearance.
4796
4797- `--shadow-etched-out-dash' or `--:shadowEtchedOutDash'
4798
4799A single dashed line with 3D raise appearance.
4800
4801- `--shadow-double-etched-in' or `--:shadowDoubleEtchedIn'
4802
4803Two lines with 3D sunken appearance.
4804
4805- `--shadow-double-etched-out' or `--:shadowDoubleEtchedOut'
4806
4807Two lines with 3D raised appearance.
4808
4809- `--shadow-double-etched-in-dash' or `--:shadowDoubleEtchedInDash'
4810
4811Two dashed lines with 3D sunken appearance.
4812
4813- `--shadow-double-etched-out-dash' or `--:shadowDoubleEtchedOutDash'
4814
4815Two dashed lines with 3D raised appearance.
4816
4817Under LessTif/Motif, the last four separator types are displayed like
4818the corresponding single-line separators.
4819
4820** New frame parameters for scroll bar colors.
4821
4822The new frame parameters `scroll-bar-foreground' and
4823`scroll-bar-background' can be used to change scroll bar colors.
4824Their value must be either a color name, a string, or nil to specify
4825that scroll bars should use a default color. For toolkit scroll bars,
4826default colors are toolkit specific. For non-toolkit scroll bars, the
4827default background is the background color of the frame, and the
4828default foreground is black.
4829
4830The X resource name of these parameters are `scrollBarForeground'
4831(class ScrollBarForeground) and `scrollBarBackground' (class
4832`ScrollBarBackground').
4833
4834Setting these parameters overrides toolkit specific X resource
4835settings for scroll bar colors.
4836
4837** You can set `redisplay-dont-pause' to a non-nil value to prevent
4838display updates from being interrupted when input is pending.
4839
4840** Changing a window's width may now change its window start if it
4841starts on a continuation line. The new window start is computed based
4842on the window's new width, starting from the start of the continued
4843line as the start of the screen line with the minimum distance from
4844the original window start.
4845
4846** The variable `hscroll-step' and the functions
4847`hscroll-point-visible' and `hscroll-window-column' have been removed
4848now that proper horizontal scrolling is implemented.
4849
4850** Windows can now be made fixed-width and/or fixed-height.
4851
4852A window is fixed-size if its buffer has a buffer-local variable
4853`window-size-fixed' whose value is not nil. A value of `height' makes
4854windows fixed-height, a value of `width' makes them fixed-width, any
4855other non-nil value makes them both fixed-width and fixed-height.
4856
4857The following code makes all windows displaying the current buffer
4858fixed-width and fixed-height.
4859
4860 (set (make-local-variable 'window-size-fixed) t)
4861
4862A call to enlarge-window on a window gives an error if that window is
4863fixed-width and it is tried to change the window's width, or if the
4864window is fixed-height, and it is tried to change its height. To
4865change the size of a fixed-size window, bind `window-size-fixed'
4866temporarily to nil, for example
4867
4868 (let ((window-size-fixed nil))
4869 (enlarge-window 10))
4870
4871Likewise, an attempt to split a fixed-height window vertically,
4872or a fixed-width window horizontally results in a error.
4873
4874** The cursor-type frame parameter is now supported on MS-DOS
4875terminals. When Emacs starts, it by default changes the cursor shape
4876to a solid box, as it does on Unix. The `cursor-type' frame parameter
4877overrides this as it does on Unix, except that the bar cursor is
4878horizontal rather than vertical (since the MS-DOS display doesn't
4879support a vertical-bar cursor).
4880
4881
4882\f
4883----------------------------------------------------------------------
5b87ad55 4884This file is part of GNU Emacs.
9a21d88b 4885
5b87ad55
GM
4886GNU Emacs is free software; you can redistribute it and/or modify
4887it under the terms of the GNU General Public License as published by
4888the Free Software Foundation; either version 2, or (at your option)
4889any later version.
4890
4891GNU Emacs is distributed in the hope that it will be useful,
4892but WITHOUT ANY WARRANTY; without even the implied warranty of
4893MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
4894GNU General Public License for more details.
9a21d88b 4895
5b87ad55
GM
4896You should have received a copy of the GNU General Public License
4897along with GNU Emacs; see the file COPYING. If not, write to the
4898Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
4899Boston, MA 02110-1301, USA.
9a21d88b 4900
9a21d88b
KS
4901\f
4902Local variables:
4903mode: outline
4904paragraph-separate: "[ \f]*$"
4905end: