(completions-first-difference): Rename from completion-emphasis. Suggested by RMS.
to the text before point. If there is text in the buffer after point,
it remains unchanged.
-** Visual feedback of *Completions* buffer is enhanced.
-Faces are put on the common prefix substrings and the first uncommon
-charachters of each completion candidate in the *Completions* buffer.
-`completion-de-emphasis' is put on the common prefix substrings as the
-face; and `completion-emphasis' is put on the first uncommon
-charachters. By default `completion-de-emphasis' is inherited from
-`default' face. `completion-emphasis' is inherited from `bold' face.
+** Enhanced visual feedback in *Completions* buffer.
+
+Completions lists use faces to highlight what all completions
+have in common and where they begin to differ.
+
+The common prefix shared by all possible completions uses the face
+`completions-common-part', while the first character that isn't the
+same uses the face `completions-first-difference'. By default,
+`completions-common-part' inherits from `default', and
+`completions-first-difference' inherits from `bold'. The idea of
+`completions-common-part' is that you can use it to make the common
+parts less visible than normal, so that the rest of the differing
+parts is, by contrast, slightly highlighted.
+++
** New user option `inhibit-startup-buffer-menu'.
to `element-common-end' at the end of loop.
The bug is reported by Juri Linkov <juri@jurta.org> in emacs-devel
list.
+ (completions-common-part): Rename from completion-de-emphasis.
+ (completions-first-difference): Rename from completion-emphasis.
+ Suggested by RMS.
2004-04-16 Juanma Barranquero <lektu@terra.es>
;; This function goes in completion-setup-hook, so that it is called
;; after the text of the completion list buffer is written.
-(defface completion-emphasis
+(defface completions-first-difference
'((t (:inherit bold)))
"Face put on the first uncommon character in completions in *Completions* buffer."
:group 'completion)
-(defface completion-de-emphasis
+(defface completions-common-part
'((t (:inherit default)))
"Face put on the common prefix substring in completions in *Completions* buffer."
:group 'completion)
(save-match-data
(if (minibufferp mainbuf)
(setq completion-base-size 0))))
- ;; Put emphasis and de-emphasis faces on completions.
+ ;; Put faces on first uncommon characters and common parts.
(when completion-base-size
(let* ((common-string-length (length
(substring mbuf-contents
(when (and (get-char-property element-start 'mouse-face)
(get-char-property element-common-end 'mouse-face))
(put-text-property element-start element-common-end
- 'font-lock-face 'completion-de-emphasis)
+ 'font-lock-face 'completions-common-part)
(put-text-property element-common-end (1+ element-common-end)
- 'font-lock-face 'completion-emphasis))
+ 'font-lock-face 'completions-first-difference))
(setq element-start (next-single-property-change
element-start
'mouse-face))