]> code.delx.au - gnu-emacs/blobdiff - lispref/display.texi
(Timers): Clarify about REPEAT when timer is delayed.
[gnu-emacs] / lispref / display.texi
index bf5f89f18a1c6a65058687fdf17009b17ab0ff0a..e7fab3ac7a8c997a40358603a402b72f3826a11a 100644 (file)
@@ -59,8 +59,8 @@ This function clears and redisplays all visible frames.
 redisplay is done, but does not clear them first.
 
 @defun force-window-update &optional object
-This function forces redisplay of some or all windows.  If
-@var{object} is a window, it forces redisplay of that window.  If
+This function forces some or all windows to be updated on next redisplay.
+If @var{object} is a window, it forces redisplay of that window.  If
 @var{object} is a buffer or buffer name, it forces redisplay of all
 windows displaying that buffer.  If @var{object} is @code{nil} (or
 omitted), it forces redisplay of all windows.
@@ -94,7 +94,6 @@ at all if input is available before it starts.  Most of the time, this
 is exactly what you want.  However, you can prevent preemption by
 binding @code{redisplay-dont-pause} to a non-@code{nil} value.
 
-@tindex redisplay-preemption-period
 @defvar redisplay-preemption-period
 This variable specifies how many seconds Emacs waits between checks
 for new input during redisplay.  (The default is 0.1 seconds.)  If
@@ -104,25 +103,25 @@ processes the available input before trying again to redisplay.
 If this variable is @code{nil}, Emacs does not check for input during
 redisplay, and redisplay cannot be preempted by input.
 
-@emph{Note} that this variable is only available if Emacs is built
-with support for sub-second timers.
+This variable is only obeyed on graphical terminals.  For
+text terminals, see @ref{Terminal Output}.
 @end defvar
 
-@tindex redisplay-dont-pause
 @defvar redisplay-dont-pause
 If this variable is non-@code{nil}, pending input does not
 prevent or halt redisplay; redisplay occurs, and finishes,
 regardless of whether input is available.
 @end defvar
 
-  You can request a display update, but only if no input is pending,
-with @code{(sit-for 0)}.  To force a display update even when input is
-pending, do this:
+@defun redisplay &optional force
+This function performs an immediate redisplay provided there are no
+pending input events.  This is equivalent to @code{(sit-for 0)}.
 
-@example
-(let ((redisplay-dont-pause t))
-  (sit-for 0))
-@end example
+If the optional argument @var{force} is non-@code{nil}, it forces an
+immediate and complete redisplay even if input is available.
+
+Returns @code{t} if redisplay was performed, or @code{nil} otherwise.
+@end defun
 
 @node Truncation
 @section Truncation
@@ -131,22 +130,21 @@ pending, do this:
 @cindex @samp{$} in display
 @cindex @samp{\} in display
 
-  When a line of text extends beyond the right edge of a window, the
-line can either be continued on the next screen line, or truncated to
-one screen line.  The additional screen lines used to display a long
-text line are called @dfn{continuation} lines.  Normally, a @samp{$} in
-the rightmost column of the window indicates truncation; a @samp{\} on
-the rightmost column indicates a line that ``wraps'' onto the next line,
-which is also called @dfn{continuing} the line.  (The display table can
-specify alternative indicators; see @ref{Display Tables}.)
-
-  On a graphical display, the @samp{$} and @samp{\} indicators are
-replaced with arrow images displayed in the window fringes
-(@pxref{Fringes}).
-
-  Note that continuation is different from filling; continuation happens
-on the screen only, not in the buffer contents, and it breaks a line
-precisely at the right margin, not at a word boundary.  @xref{Filling}.
+  When a line of text extends beyond the right edge of a window, Emacs
+can @dfn{continue} the line (make it ``wrap'' to the next screen
+line), or @dfn{truncate} the line (limit it to one screen line).  The
+additional screen lines used to display a long text line are called
+@dfn{continuation} lines.  Continuation is not the same as filling;
+continuation happens on the screen only, not in the buffer contents,
+and it breaks a line precisely at the right margin, not at a word
+boundary.  @xref{Filling}.
+
+   On a graphical display, tiny arrow images in the window fringes
+indicate truncated and continued lines (@pxref{Fringes}).  On a text
+terminal, a @samp{$} in the rightmost column of the window indicates
+truncation; a @samp{\} on the rightmost column indicates a line that
+``wraps.''  (The display table can specify alternate characters to use
+for this; @pxref{Display Tables}).
 
 @defopt truncate-lines
 This buffer-local variable controls how Emacs displays lines that extend
@@ -261,7 +259,6 @@ To automatically display a message in the echo area or in a pop-buffer,
 depending on its size, use @code{display-message-or-buffer} (see below).
 @end defun
 
-@tindex with-temp-message
 @defmac with-temp-message message &rest body
 This construct displays a message in the echo area temporarily, during
 the execution of @var{body}.  It displays @var{message}, executes
@@ -284,6 +281,7 @@ You can force use of the mouse or of the echo area by binding
 @end defun
 
 @defun message-box format-string &rest arguments
+@anchor{message-box}
 This function displays a message like @code{message}, but uses a dialog
 box (or a pop-up menu) whenever that is possible.  If it is impossible
 to use a dialog box or pop-up menu, because the terminal does not
@@ -292,7 +290,6 @@ support them, then @code{message-box} uses the echo area, like
 @end defun
 
 @defun display-message-or-buffer message &optional buffer-name not-this-window frame
-@tindex display-message-or-buffer
 This function displays the message @var{message}, which may be either a
 string or a buffer.  If it is shorter than the maximum height of the
 echo area, as defined by @code{max-mini-window-height}, it is displayed
@@ -1031,7 +1028,6 @@ selected.
 @end defvar
 
 @defvar temp-buffer-setup-hook
-@tindex temp-buffer-setup-hook
 This normal hook is run by @code{with-output-to-temp-buffer} before
 evaluating @var{body}.  When the hook runs, the temporary buffer is
 current.  This hook is normally set up with a function to put the
@@ -1195,7 +1191,7 @@ The return value is @var{overlay}.
 This is the only valid way to change the endpoints of an overlay.  Do
 not try modifying the markers in the overlay by hand, as that fails to
 update other vital data structures and can cause some overlays to be
-``lost''.
+``lost.''
 @end defun
 
 @defun remove-overlays &optional start end name value
@@ -1863,9 +1859,9 @@ as if they had a light background.
 
   The effect of using a face is determined by a fixed set of @dfn{face
 attributes}.  This table lists all the face attributes, and what they
-mean.  Note that in general, more than one face can be specified for a
-given piece of text; when that happens, the attributes of all the faces
-are merged to specify how to display the text.  @xref{Displaying Faces}.
+mean.  You can specify more than one face for a given piece of text;
+Emacs merges the attributes of all the faces to determine how to
+display the text.  @xref{Displaying Faces}.
 
   Any attribute in a face can have the value @code{unspecified}.  This
 means the face doesn't specify that attribute.  In face merging, when
@@ -2019,7 +2015,7 @@ A non-@code{nil} value specifies a bold font.
 A non-@code{nil} value specifies an italic font.
 @end table
 
-  For compatibility, you can still set these ``attributes'', even
+  For compatibility, you can still set these ``attributes,'' even
 though they are not real face attributes.  Here is what that does:
 
 @table @code
@@ -2054,16 +2050,13 @@ suitable for use with @code{:stipple} (see above).  It returns
 @node Attribute Functions
 @subsection Face Attribute Functions
 
-  You can modify the attributes of an existing face with the following
-functions.  If you specify @var{frame}, they affect just that frame;
-otherwise, they affect all frames as well as the defaults that apply to
-new frames.
+  This section describes the functions for accessing and modifying the
+attributes of an existing face.
 
-@tindex set-face-attribute
 @defun set-face-attribute face frame &rest arguments
-This function sets one or more attributes of face @var{face}
-for frame @var{frame}.  If @var{frame} is @code{nil}, it sets
-the attribute for all frames, and the defaults for new frames.
+This function sets one or more attributes of face @var{face} for frame
+@var{frame}.  The attributes you specify this way override whatever
+the @code{defface} says.
 
 The extra arguments @var{arguments} specify the attributes to set, and
 the values for them.  They should consist of alternating attribute names
@@ -2080,16 +2073,24 @@ Thus,
 @noindent
 sets the attributes @code{:width}, @code{:weight} and @code{:underline}
 to the corresponding values.
+
+If @var{frame} is @code{t}, this function sets the default attributes
+for new frames.  Default attribute values specified this way override
+the @code{defface} for newly created frames.
+
+If @var{frame} is @code{nil}, this function sets the attributes for
+all existing frames, and the default for new frames.
 @end defun
 
-@tindex face-attribute
 @defun face-attribute face attribute &optional frame inherit
 This returns the value of the @var{attribute} attribute of face
 @var{face} on @var{frame}.  If @var{frame} is @code{nil},
 that means the selected frame (@pxref{Input Focus}).
 
-If @var{frame} is @code{t}, the value is the default for
-@var{face} for new frames.
+If @var{frame} is @code{t}, this returns whatever new-frames default
+value you previously specified with @code{set-face-attribute} for the
+@var{attribute} attribute of @var{face}.  If you have not specified
+one, it returns @code{nil}.
 
 If @var{inherit} is @code{nil}, only attributes directly defined by
 @var{face} are considered, so the return value may be
@@ -2114,18 +2115,25 @@ For example,
 @end example
 @end defun
 
-  The functions above did not exist before Emacs 21.  For compatibility
-with older Emacs versions, you can use the following functions to set
-and examine the face attributes which existed in those versions.
-
-@tindex face-attribute-relative-p
 @defun face-attribute-relative-p attribute value
-This function returns non-@code{nil} if @var{value}, when used as
-the value of the face attribute @var{attribute}, is relative (that is,
-if it modifies an underlying or inherited value of @var{attribute}).
+This function returns non-@code{nil} if @var{value}, when used as the
+value of the face attribute @var{attribute}, is relative.  This means
+it would modify, rather than completely override, any value that comes
+from a subsequent face in the face list or that is inherited from
+another face.
+
+@code{unspecified} is a relative value for all attributes.
+For @code{:height}, floating point values are also relative.
+
+For example:
+
+@example
+(read-face-name "Describe face" "= `default' face" t)
+@end example
+
+prompts with @samp{Describe face (default = `default' face): }.
 @end defun
 
-@tindex merge-face-attribute
 @defun merge-face-attribute attribute value1 value2
 If @var{value1} is a relative value for the face attribute
 @var{attribute}, returns it merged with the underlying value
@@ -2133,6 +2141,12 @@ If @var{value1} is a relative value for the face attribute
 face attribute @var{attribute}, returns @var{value1} unchanged.
 @end defun
 
+  The functions above did not exist before Emacs 21.  For compatibility
+with older Emacs versions, you can use the following functions to set
+and examine the face attributes which existed in those versions.
+They use values of @code{t} and @code{nil} for @var{frame}
+just like @code{set-face-attribute} and @code{face-attribute}.
+
 @defun set-face-foreground face color &optional frame
 @defunx set-face-background face color &optional frame
 These functions set the foreground (or background, respectively) color
@@ -2188,9 +2202,10 @@ This function swaps the foreground and background colors of face
 @end defun
 
   These functions examine the attributes of a face.  If you don't
-specify @var{frame}, they refer to the default data for new frames.
-They return the symbol @code{unspecified} if the face doesn't define any
-value for that attribute.
+specify @var{frame}, they refer to the selected frame; @code{t} refers
+to the default data for new frames.  They return the symbol
+@code{unspecified} if the face doesn't define any value for that
+attribute.
 
 @defun face-foreground face &optional frame inherit
 @defunx face-background face &optional frame inherit
@@ -2314,7 +2329,6 @@ not available, you can specify a set of mappings for alternatives to
 try.
 
 @defvar face-font-selection-order
-@tindex face-font-selection-order
 This variable specifies the order of importance of the face attributes
 @code{:width}, @code{:height}, @code{:weight}, and @code{:slant}.  The
 value should be a list containing those four symbols, in order of
@@ -2344,7 +2358,6 @@ quite right.
 @end defvar
 
 @defvar face-font-family-alternatives
-@tindex face-font-family-alternatives
 This variable lets you specify alternative font families to try, if a
 given family is specified and doesn't exist.  Each element should have
 this form:
@@ -2359,7 +2372,6 @@ family that does exist.
 @end defvar
 
 @defvar face-font-registry-alternatives
-@tindex face-font-registry-alternatives
 This variable lets you specify alternative font registries to try, if a
 given registry is specified and doesn't exist.  Each element should have
 this form:
@@ -2378,7 +2390,6 @@ them, since the use of too many or too big scalable fonts can crash
 XFree86 servers.
 
 @defvar scalable-fonts-allowed
-@tindex scalable-fonts-allowed
 This variable controls which scalable fonts to use.  A value of
 @code{nil}, the default, means do not use scalable fonts.  @code{t}
 means to use any scalable font that seems appropriate for the text.
@@ -2479,7 +2490,6 @@ makes @code{modeline} an alias for the @code{mode-line} face.
   This hook is used for automatically assigning faces to text in the
 buffer.  It is part of the implementation of Font-Lock mode.
 
-@tindex fontification-functions
 @defvar fontification-functions
 This variable holds a list of functions that are called by Emacs
 redisplay as needed to assign faces automatically to text in the buffer.
@@ -2529,7 +2539,6 @@ many fonts match the pattern.
 @end defun
 
 @defun x-family-fonts &optional family frame
-@tindex x-family-fonts
 This function returns a list describing the available fonts for family
 @var{family} on @var{frame}.  If @var{family} is omitted or @code{nil},
 this list applies to all families, and therefore, it contains all
@@ -2560,7 +2569,6 @@ The result list is sorted according to the current face font sort order.
 @end defun
 
 @defun x-font-family-list &optional frame
-@tindex x-font-family-list
 This function returns a list of the font families available for
 @var{frame}'s display.  If @var{frame} is omitted or @code{nil}, it
 describes the selected frame's display (@pxref{Input Focus}).
@@ -2577,7 +2585,6 @@ non-@code{nil} if fonts of that family are fixed-pitch.
 @end defun
 
 @defvar font-list-limit
-@tindex font-list-limit
 This variable specifies maximum number of fonts to consider in font
 matching.  The function @code{x-family-fonts} will not return more than
 that many fonts, and font selection will consider only that many fonts
@@ -2794,7 +2801,6 @@ window fringe (on a graphic display) to indicate truncated or
 continued lines, buffer boundaries, overlay arrow, etc.
 
 @defopt indicate-empty-lines
-@tindex indicate-empty-lines
 @cindex fringes, and empty line indication
 When this is non-@code{nil}, Emacs displays a special glyph in the
 fringe of each empty line at the end of the buffer, on graphical
@@ -2812,26 +2818,32 @@ In addition, Emacs can display an up-arrow in the fringe to show
 that there is text above the screen, and a down-arrow to show
 there is text below the screen.
 
-There are four kinds of basic values:
+There are three kinds of basic values:
 
 @table @asis
 @item @code{nil}
-Don't display the icons.
+Don't display any of these fringe icons.
 @item @code{left}
-Display them in the left fringe.
+Display the angle icons and arrows in the left fringe.
 @item @code{right}
-Display them in the right fringe.
-@item @var{anything-else}
-Display the icon at the top of the window top in the left fringe, and other
-in the right fringe.
+Display the angle icons and arrows in the right fringe.
+@item any non-alist
+Display the angle icons in the left fringe
+and don't display the arrows.
 @end table
 
-If value is a cons @code{(@var{angles} . @var{arrows})}, @var{angles}
-controls the angle icons, and @var{arrows} controls the arrows.  Both
-@var{angles} and @var{arrows} work according to the table above.
-Thus, @code{(t .  right)} places the top angle icon in the left
-fringe, the bottom angle icon in the right fringe, and both arrows in
-the right fringe.
+Otherwise the value should be an alist that specifies which fringe
+indicators to display and where.  Each element of the alist should
+have the form @code{(@var{indicator} . @var{position})}.  Here,
+@var{indicator} is one of @code{top}, @code{bottom}, @code{up},
+@code{down}, and @code{t} (which covers all the icons not yet
+specified), while @var{position} is one of @code{left}, @code{right}
+and @code{nil}.
+
+For example, @code{((top . left) (t . right))} places the top angle
+bitmap in left fringe, and the bottom angle bitmap as well as both
+arrow bitmaps in right fringe.  To show the angle bitmaps in the left
+fringe, and no arrow bitmaps, use @code{((top .  left) (bottom . left))}.
 @end defvar
 
 @defvar default-indicate-buffer-boundaries
@@ -2893,20 +2905,19 @@ The value of this variable is the default value for
 @code{fringe-indicator-alist} in buffers that do not override it.
 @end defvar
 
-@table @asis
-@item Standard fringe bitmaps for indicators:
-@code{left-arrow}, @code{right-arrow}, @code{up-arrow}, @code{down-arrow},
-@code{left-curly-arrow}, @code{right-curly-arrow},
-@code{left-triangle}, @code{right-triangle},
-@code{top-left-angle}, @code{top-right-angle},
-@code{bottom-left-angle}, @code{bottom-right-angle},
-@code{left-bracket}, @code{right-bracket},
-@code{filled-rectangle}, @code{hollow-rectangle},
-@code{filled-square}, @code{hollow-square},
-@code{vertical-bar}, @code{horizontal-bar},
-@code{empty-line},
-@code{question-mark}.
-@end table
+Standard fringe bitmaps for indicators:
+@example
+left-arrow right-arrow up-arrow down-arrow
+left-curly-arrow right-curly-arrow
+left-triangle right-triangle
+top-left-angle top-right-angle
+bottom-left-angle bottom-right-angle
+left-bracket right-bracket
+filled-rectangle hollow-rectangle
+filled-square hollow-square
+vertical-bar horizontal-bar
+empty-line question-mark
+@end example
 
 @node Fringe Cursors
 @subsection Fringe Cursors
@@ -2938,7 +2949,7 @@ fringe.
 @defvar fringe-cursor-alist
 This variable specifies the mapping from logical cursor type to the
 actual fringe bitmaps displayed in the right fringe.  The value is an
-alist where each element @code{(@var{cursor}. @var{bitmap})} specifies
+alist where each element @code{(@var{cursor} . @var{bitmap})} specifies
 the fringe bitmaps used to display a specific logical cursor type in
 the fringe.  Here, @var{cursor} specifies the logical cursor type and
 @var{bitmap} is a symbol specifying the fringe bitmap to be displayed
@@ -2954,12 +2965,11 @@ The value of this variable is the default value for
 @code{fringe-cursor-alist} in buffers that do not override it.
 @end defvar
 
-@table @asis
-@item Standard bitmaps for displaying the cursor in right fringe:
-@code{filled-rectangle}, @code{hollow-rectangle},
-@code{filled-square}, @code{hollow-square},
-@code{vertical-bar}, @code{horizontal-bar}.
-@end table
+Standard bitmaps for displaying the cursor in right fringe:
+@example
+filled-rectangle hollow-rectangle filled-square hollow-square
+vertical-bar horizontal-bar
+@end example
 
 
 @node Fringe Bitmaps
@@ -3028,12 +3038,6 @@ The @var{align} argument may also be a list @code{(@var{align}
 If @var{periodic} is non-@code{nil}, it specifies that the rows in
 @code{bits} should be repeated enough times to reach the specified
 height.
-
-The return value on success is an integer identifying the new bitmap.
-You should save that integer in a variable so it can be used to select
-this bitmap.
-
-This function signals an error if there are no more free bitmap slots.
 @end defun
 
 @defun destroy-fringe-bitmap bitmap
@@ -3107,8 +3111,8 @@ Each variable on this list can have properties
 specify an overlay arrow string (for text-only terminals) or fringe
 bitmap (for graphical terminals) to display at the corresponding
 overlay arrow position.  If either property is not set, the default
-(@code{overlay-arrow-string} or @code{overlay-arrow-fringe-bitmap}) is
-used.
+@code{overlay-arrow-string} or @code{overlay-arrow} fringe indicator
+is used.
 
 @node Scroll Bars
 @section Scroll Bars
@@ -3532,13 +3536,11 @@ them a nonzero width.  The usual way to do that is to set these
 variables:
 
 @defvar left-margin-width
-@tindex left-margin-width
 This variable specifies the width of the left margin.
 It is buffer-local in all buffers.
 @end defvar
 
 @defvar right-margin-width
-@tindex right-margin-width
 This variable specifies the width of the right margin.
 It is buffer-local in all buffers.
 @end defvar
@@ -3551,14 +3553,12 @@ Thus, you can make changes take effect by calling
   You can also set the margin widths immediately.
 
 @defun set-window-margins window left &optional right
-@tindex set-window-margins
 This function specifies the margin widths for window @var{window}.
 The argument @var{left} controls the left margin and
 @var{right} controls the right margin (default @code{0}).
 @end defun
 
 @defun window-margins &optional window
-@tindex window-margins
 This function returns the left and right margins of @var{window}
 as a cons cell of the form @code{(@var{left} . @var{right})}.
 If @var{window} is @code{nil}, the selected window is used.
@@ -3572,6 +3572,13 @@ If @var{window} is @code{nil}, the selected window is used.
 descriptor, then use it as a display specifier in the @code{display}
 property of text that is displayed (@pxref{Display Property}).
 
+  Emacs is usually able to display images when it is run on a
+graphical terminal.  Images cannot be displayed in a text terminal, on
+certain graphical terminals that lack the support for this, or if
+Emacs is compiled without image support.  You can use the function
+@code{display-images-p} to determine if images can in principle be
+displayed (@pxref{Display Feature Testing}).
+
   Emacs can display a number of different image formats; some of them
 are supported only if particular support libraries are installed on
 your machine.  In some environments, Emacs can load image
@@ -3785,7 +3792,7 @@ $$\pmatrix{ 2 & -1 &  0 \cr
 @end ifnottex
 
 @item disabled
-Specifies transforming the image so that it looks ``disabled''.
+Specifies transforming the image so that it looks ``disabled.''
 @end table
 
 @item :mask @var{mask}
@@ -3841,7 +3848,6 @@ mouse event; for instance, @code{[area4 mouse-1]} if the hot-spot's
 @end table
 
 @defun image-mask-p spec &optional frame
-@tindex image-mask-p
 This function returns @code{t} if image @var{spec} has a mask bitmap.
 @var{frame} is the frame on which the image will be displayed.
 @var{frame} @code{nil} or omitted means to use the selected frame
@@ -4025,7 +4031,6 @@ background color.
 @code{find-image} provide convenient ways to create image descriptors.
 
 @defun create-image file-or-data &optional type data-p &rest props
-@tindex create-image
 This function creates and returns an image descriptor which uses the
 data in @var{file-or-data}.  @var{file-or-data} can be a file name or
 a string containing the image data; @var{data-p} should be @code{nil}
@@ -4048,7 +4053,6 @@ supported.  Otherwise it returns an image descriptor.
 @end defun
 
 @defmac defimage symbol specs &optional doc
-@tindex defimage
 This macro defines @var{symbol} as an image name.  The arguments
 @var{specs} is a list which specifies how to display the image.
 The third argument, @var{doc}, is an optional documentation string.
@@ -4077,7 +4081,6 @@ as @code{nil}.
 @end defmac
 
 @defun find-image specs
-@tindex find-image
 This function provides a convenient way to find an image satisfying one
 of a list of image specifications @var{specs}.
 
@@ -4095,7 +4098,6 @@ The image is looked for in @code{image-load-path}.
 @end defun
 
 @defvar image-load-path
-@tindex image-load-path
 This variable's value is a list of locations in which to search for
 image files.  If an element is a string or a variable symbol whose
 value is a string, the string is taken to be the name of a directory
@@ -4117,15 +4119,15 @@ should specify the image as follows:
 @end defvar
 
 @defun image-load-path-for-library library image &optional path no-error
-@tindex image-load-path-for-library
 This function returns a suitable search path for images used by the
 Lisp package @var{library}.
 
-It searches for @var{image} in @code{image-load-path} (excluding
-@file{@code{data-directory}/images}) and @code{load-path}, followed by
-a path suitable for @var{library}, which includes
-@file{../../etc/images} and @file{../etc/images} relative to the
-library file itself, and then in @file{@code{data-directory}/images}.
+The function searches for @var{image} first in @code{image-load-path}
+(excluding @file{@code{data-directory}/images}) and then in
+@code{load-path}, followed by a path suitable for @var{library}, which
+includes @file{../../etc/images} and @file{../etc/images} relative to
+the library file itself, and finally in
+@file{@code{data-directory}/images}.
 
 Then this function returns a list of directories which contains first
 the directory in which @var{image} was found, followed by the value of
@@ -4140,10 +4142,9 @@ Here is an example that uses a common idiom to provide compatibility
 with versions of Emacs that lack the variable @code{image-load-path}:
 
 @example
-;; Shush compiler.
-(defvar image-load-path)
-
-(let* ((load-path (image-load-path-for-library "mh-e" "mh-logo.xpm"))
+(defvar image-load-path) ; shush compiler
+(let* ((load-path (image-load-path-for-library
+                        "mh-e" "mh-logo.xpm"))
        (image-load-path (cons (car load-path)
                               (when (boundp 'image-load-path)
                                 image-load-path))))
@@ -4224,7 +4225,6 @@ This removes only images that were put into @var{buffer} the way
 @end defun
 
 @defun image-size spec &optional pixels frame
-@tindex image-size
 This function returns the size of an image as a pair
 @w{@code{(@var{width} . @var{height})}}.  @var{spec} is an image
 specification.  @var{pixels} non-@code{nil} means return sizes
@@ -4236,7 +4236,6 @@ Focus}).
 @end defun
 
 @defvar max-image-size
-@tindex max-image-size
 This variable is used to define the maximum size of image that Emacs
 will load.  Emacs will refuse to load (and display) any image that is
 larger than this limit.
@@ -4266,7 +4265,6 @@ with cached image specifications using @code{equal}.  This means that
 all images with equal specifications share the same image in the cache.
 
 @defvar image-cache-eviction-delay
-@tindex image-cache-eviction-delay
 This variable specifies the number of seconds an image can remain in the
 cache without being displayed.  When an image is not displayed for this
 length of time, Emacs removes it from the image cache.
@@ -4277,7 +4275,6 @@ debugging.
 @end defvar
 
 @defun clear-image-cache &optional frame
-@tindex clear-image-cache
 This function clears the image cache.  If @var{frame} is non-@code{nil},
 only the cache for that frame is cleared.  Otherwise all frames' caches
 are cleared.
@@ -4298,7 +4295,7 @@ etc.  Emacs uses buttons for the hyper-links in help text and the like.
 properties or overlays) to a region of text in an Emacs buffer.  These
 properties are called @dfn{button properties}.
 
-  One of the these properties (@code{action}) is a function, which will
+  One of these properties (@code{action}) is a function, which will
 be called when the user invokes it using the keyboard or the mouse.
 The invoked function may then examine the button and use its other
 properties as desired.
@@ -4399,7 +4396,6 @@ so that it's easy to define special-purpose types of buttons for
 specific tasks.
 
 @defun define-button-type name &rest properties
-@tindex define-button-type
 Define a `button type' called @var{name}.  The remaining arguments
 form a sequence of @var{property value} pairs, specifying default
 property values for buttons with this type (a button's type may be set
@@ -4448,13 +4444,11 @@ defines such a property).
 (@pxref{Overlays}) to hold the button properties:
 
 @defun make-button beg end &rest properties
-@tindex make-button
 This makes a button from @var{beg} to @var{end} in the
 current buffer, and returns it.
 @end defun
 
 @defun insert-button label &rest properties
-@tindex insert-button
 This insert a button with the label @var{label} at point,
 and returns it.
 @end defun
@@ -4468,13 +4462,11 @@ numbers of buttons.  Both functions return the position of the start
 of the new button:
 
 @defun make-text-button beg end &rest properties
-@tindex make-text-button
 This makes a button from @var{beg} to @var{end} in the current buffer, using
 text properties.
 @end defun
 
 @defun insert-text-button label &rest properties
-@tindex insert-text-button
 This inserts a button with the label @var{label} at point, using text
 properties.
 @end defun
@@ -4494,27 +4486,22 @@ Such an object is passed as the first argument to a button's
 invocation function when it is invoked.
 
 @defun button-start button
-@tindex button-start
 Return the position at which @var{button} starts.
 @end defun
 
 @defun button-end button
-@tindex button-end
 Return the position at which @var{button} ends.
 @end defun
 
 @defun button-get button prop
-@tindex button-get
 Get the property of button @var{button} named @var{prop}.
 @end defun
 
 @defun button-put button prop val
-@tindex button-put
 Set @var{button}'s @var{prop} property to @var{val}.
 @end defun
 
 @defun button-activate button &optional use-mouse-action
-@tindex button-activate
 Call @var{button}'s @code{action} property (i.e., invoke it).  If
 @var{use-mouse-action} is non-@code{nil}, try to invoke the button's
 @code{mouse-action} property instead of @code{action}; if the button
@@ -4522,38 +4509,31 @@ has no @code{mouse-action} property, use @code{action} as normal.
 @end defun
 
 @defun button-label button
-@tindex button-label
 Return @var{button}'s text label.
 @end defun
 
 @defun button-type button
-@tindex button-type
 Return @var{button}'s button-type.
 @end defun
 
 @defun button-has-type-p button type
-@tindex button-has-type-p
 Return @code{t} if @var{button} has button-type @var{type}, or one of
 @var{type}'s subtypes.
 @end defun
 
 @defun button-at pos
-@tindex button-at
 Return the button at position @var{pos} in the current buffer, or @code{nil}.
 @end defun
 
 @defun button-type-put type prop val
-@tindex button-type-put
 Set the button-type @var{type}'s @var{prop} property to @var{val}.
 @end defun
 
 @defun button-type-get type prop
-@tindex button-type-get
 Get the property of button-type @var{type} named @var{prop}.
 @end defun
 
 @defun button-type-subtype-p type supertype
-@tindex button-type-subtype-p
 Return @code{t} if button-type @var{type} is a subtype of @var{supertype}.
 @end defun
 
@@ -4579,7 +4559,6 @@ will also activate the @code{push-button} command.
 @xref{Links and Mouse-1}.
 
 @deffn Command push-button &optional pos use-mouse-action
-@tindex push-button
 Perform the action specified by a button at location @var{pos}.
 @var{pos} may be either a buffer position or a mouse-event.  If
 @var{use-mouse-action} is non-@code{nil}, or @var{pos} is a
@@ -4593,7 +4572,6 @@ nothing and return @code{nil}, otherwise return @code{t}.
 @end deffn
 
 @deffn Command forward-button n &optional wrap display-message
-@tindex forward-button
 Move to the @var{n}th next button, or @var{n}th previous button if
 @var{n} is negative.  If @var{n} is zero, move to the start of any
 button at point.  If @var{wrap} is non-@code{nil}, moving past either
@@ -4604,7 +4582,6 @@ is skipped over.  Returns the button found.
 @end deffn
 
 @deffn Command backward-button n &optional wrap display-message
-@tindex backward-button
 Move to the @var{n}th previous button, or @var{n}th next button if
 @var{n} is negative.  If @var{n} is zero, move to the start of any
 button at point.  If @var{wrap} is non-@code{nil}, moving past either
@@ -4615,14 +4592,12 @@ is skipped over.  Returns the button found.
 @end deffn
 
 @defun next-button pos &optional count-current
-@tindex next-button
 Return the next button after position @var{pos} in the current buffer.
 If @var{count-current} is non-@code{nil}, count any button at
 @var{pos} in the search, instead of starting at the next button.
 @end defun
 
 @defun previous-button pos &optional count-current
-@tindex previous-button
 Return the @var{n}th button before position @var{pos} in the current
 buffer.  If @var{count-current} is non-@code{nil}, count any button at
 @var{pos} in the search, instead of starting at the next button.
@@ -4854,7 +4829,7 @@ Any @var{args} are passed to @var{map-function}.
 @subsection Abstract Display Example
 
   Here is a simple example using functions of the ewoc package to
-implement a ``color components display'', an area in a buffer that
+implement a ``color components display,'' an area in a buffer that
 represents a vector of three integers (itself representing a 24-bit RGB
 value) in various ways.
 
@@ -4917,7 +4892,7 @@ design paradigm) by defining commands to modify @code{colorcomp-data}
 and to ``finish'' the selection process, and a keymap to tie it all
 together conveniently.
 
-@example
+@smallexample
 (defun colorcomp-mod (index limit delta)
   (let ((cur (aref colorcomp-data index)))
     (unless (= limit cur)
@@ -4955,7 +4930,7 @@ The string is formatted #RRGGBB (hash followed by six hex digits)."
         (define-key m "." 'colorcomp-B-more)
         (define-key m " " 'colorcomp-copy-as-kill-and-exit)
         m))
-@end example
+@end smallexample
 
 Note that we never modify the data in each node, which is fixed when the
 ewoc is created to be either @code{nil} or an index into the vector
@@ -5143,13 +5118,14 @@ This creates and returns a display table.  The table initially has
 
   The ordinary elements of the display table are indexed by character
 codes; the element at index @var{c} says how to display the character
-code @var{c}.  The value should be @code{nil} or a vector of glyph
-values (@pxref{Glyphs}).  If an element is @code{nil}, it says to
-display that character according to the usual display conventions
+code @var{c}.  The value should be @code{nil} or a vector of the
+glyphs to be output (@pxref{Glyphs}).  @code{nil} says to display the
+character @var{c} according to the usual display conventions
 (@pxref{Usual Display}).
 
-  If you use the display table to change the display of newline
-characters, the whole buffer will be displayed as one long ``line.''
+  @strong{Warning:} if you use the display table to change the display
+of newline characters, the whole buffer will be displayed as one long
+``line.''
 
   The display table also has six ``extra slots'' which serve special
 purposes.  Here is a table of their meanings; @code{nil} in any slot
@@ -5215,13 +5191,11 @@ This function stores @var{value} in the extra slot @var{slot} of
 @end defun
 
 @defun describe-display-table display-table
-@tindex describe-display-table
 This function displays a description of the display table
 @var{display-table} in a help buffer.
 @end defun
 
 @deffn Command describe-current-display-table
-@tindex describe-current-display-table
 This command displays a description of the current display table in a
 help buffer.
 @end deffn
@@ -5278,14 +5252,14 @@ are defined in the library @file{disp-table}.
   A @dfn{glyph} is a generalization of a character; it stands for an
 image that takes up a single character position on the screen.  Glyphs
 are represented in Lisp as integers, just as characters are.  Normally
-Emacs finds glyphs in the display table (@pxref{Display Tables}).
-
-  A glyph can be @dfn{simple} or it can be defined by the @dfn{glyph
-table}.  A simple glyph is just a way of specifying a character and a
-face to output it in.  The glyph code for a simple glyph, mod 524288,
-is the character to output, and the glyph code divided by 524288
-specifies the face number (@pxref{Face Functions}) to use while
-outputting it.  (524288 is
+glyph come from vectors in the display table (@pxref{Display Tables}).
+
+  A glyph code can be @dfn{simple} or it can be defined by the
+@dfn{glyph table}.  A simple glyph code is just a way of specifying a
+character and a face to output it in.  When a glyph code is simple,
+the code, mod 524288, is the character to output, and the code divided
+by 524288 specifies the face number (@pxref{Face Functions}) to use
+while outputting it.  (524288 is
 @ifnottex
 2**19.)
 @end ifnottex
@@ -5295,39 +5269,38 @@ $2^{19}$.)
 @xref{Faces}.
 
   On character terminals, you can set up a @dfn{glyph table} to define
-the meaning of glyph codes.  The glyph codes is the value of the
-variable @code{glyph-table}.
+the meaning of glyph codes.
 
 @defvar glyph-table
-The value of this variable is the current glyph table.  It should be a
-vector; the @var{g}th element defines glyph code @var{g}.
+The value of this variable is the current glyph table.  It should be
+@code{nil} or a vector whose @var{g}th element defines glyph code
+@var{g}.
 
 If a glyph code is greater than or equal to the length of the glyph
-table, that code is automatically simple.  If the value of
-@code{glyph-table} is @code{nil} instead of a vector, then all glyphs
-are simple.  The glyph table is not used on graphical displays, only
-on character terminals.  On graphical displays, all glyphs are simple.
+table, that code is automatically simple.  If @code{glyph-table} is
+@code{nil} then all glyph codes are simple.
+
+The glyph table is used only on character terminals.  On graphical
+displays, all glyph codes are simple.
 @end defvar
 
-  Here are the possible types of elements in the glyph table:
+  Here are the meaningful types of elements in the glyph table:
 
 @table @asis
 @item @var{string}
 Send the characters in @var{string} to the terminal to output
-this glyph.  This alternative is available on character terminals,
-but not on graphical displays.
+this glyph code.
 
 @item @var{integer}
 Define this glyph code as an alias for glyph code @var{integer}.  You
-can use an alias to specify a face code for the glyph and use a small
-number as its code.
+can use such an alias to define a small-numbered glyph code which
+specifies a face.
 
 @item @code{nil}
-This glyph is simple.
+This glyph code is simple.
 @end table
 
 @defun create-glyph string
-@tindex create-glyph
 This function returns a newly-allocated glyph code which is set up to
 display by sending @var{string} to the terminal.
 @end defun
@@ -5373,7 +5346,7 @@ variable.
 @section Window Systems
 
   Emacs works with several window systems, most notably the X Window
-System.  Both Emacs and X use the term ``window'', but use it
+System.  Both Emacs and X use the term ``window,'' but use it
 differently.  An Emacs frame is a single window as far as X is
 concerned; the individual Emacs windows are not known to X at all.