/[emacs]/emacs/lispref/minibuf.texi
ViewVC logotype

Diff of /emacs/lispref/minibuf.texi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.65 by rfrancoise, Fri Sep 30 18:29:01 2005 UTC revision 1.66 by jet, Thu Oct 27 05:43:37 2005 UTC
# Line 949  The list of completions is displayed as Line 949  The list of completions is displayed as
949  @samp{*Completions*}.  @samp{*Completions*}.
950  @end deffn  @end deffn
951    
952  @defun display-completion-list completions  @defun display-completion-list completions &optional common-substring
953  This function displays @var{completions} to the stream in  This function displays @var{completions} to the stream in
954  @code{standard-output}, usually a buffer.  (@xref{Read and Print}, for more  @code{standard-output}, usually a buffer.  (@xref{Read and Print}, for more
955  information about streams.)  The argument @var{completions} is normally  information about streams.)  The argument @var{completions} is normally
# Line 960  which is printed as if the strings were Line 960  which is printed as if the strings were
960  the two strings is the actual completion, the second string serves as  the two strings is the actual completion, the second string serves as
961  annotation.  annotation.
962    
963  This function is called by @code{minibuffer-completion-help}.  The  @var{common-substring} represents a string common prefix between all
964    completions.  @var{common-substring} is used to put faces on
965    @samp{*Completions*} to enhance visual feedback of the buffer;
966    @code{display-completion-list} use faces to highlight what all completions
967    have in common and where they begin to differ.  @var{common-substring}
968    specifies the common part.
969    
970    This function is called by @code{minibuffer-completion-help}.  The
971  most common way to use it is together with  most common way to use it is together with
972  @code{with-output-to-temp-buffer}, like this:  @code{with-output-to-temp-buffer}, like this:
973    
974  @example  @example
975  (with-output-to-temp-buffer "*Completions*"  (with-output-to-temp-buffer "*Completions*"
976    (display-completion-list    (display-completion-list
977      (all-completions (buffer-string) my-alist)))      (all-completions (buffer-string) my-alist)
978        (buffer-string)))
979  @end example  @end example
980  @end defun  @end defun
981    

Legend:
Removed from v.1.65  
changed lines
  Added in v.1.66

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26