[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/faces.el
From: |
Juri Linkov |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/faces.el |
Date: |
Sun, 03 Jul 2005 21:03:26 -0400 |
Index: emacs/lisp/faces.el
diff -c emacs/lisp/faces.el:1.327 emacs/lisp/faces.el:1.328
*** emacs/lisp/faces.el:1.327 Thu Jun 30 15:04:57 2005
--- emacs/lisp/faces.el Mon Jul 4 01:03:23 2005
***************
*** 869,875 ****
(aliasfaces nil)
(nonaliasfaces nil)
faces)
! ;; Make a list of the named faces that the `face' property uses.
(if (and (listp faceprop)
;; Don't treat an attribute spec as a list of faces.
(not (keywordp (car faceprop)))
--- 869,878 ----
(aliasfaces nil)
(nonaliasfaces nil)
faces)
! ;; Try to get a face name from the buffer.
! (if (memq (intern-soft (thing-at-point 'symbol)) (face-list))
! (setq faces (list (intern-soft (thing-at-point 'symbol)))))
! ;; Add the named faces that the `face' property uses.
(if (and (listp faceprop)
;; Don't treat an attribute spec as a list of faces.
(not (keywordp (car faceprop)))
***************
*** 879,888 ****
(push f faces)))
(if (symbolp faceprop)
(push faceprop faces)))
- ;; If there are none, try to get a face name from the buffer.
- (if (and (null faces)
- (memq (intern-soft (thing-at-point 'symbol)) (face-list)))
- (setq faces (list (intern-soft (thing-at-point 'symbol)))))
;; Build up the completion tables.
(mapatoms (lambda (s)
--- 882,887 ----
***************
*** 896,917 ****
(unless multiple
(if faces
(setq faces (list (car faces)))))
(let* ((input
;; Read the input.
! (completing-read
(if (or faces string-describing-default)
(format "%s (default %s): " prompt
! (if faces (mapconcat 'symbol-name faces ", ")
string-describing-default))
(format "%s: " prompt))
! (complete-in-turn nonaliasfaces aliasfaces) nil t))
;; Canonicalize the output.
(output
! (if (equal input "")
! faces
! (if (stringp input)
! (list (intern input))
! input))))
;; Return either a list of faces or just one face.
(if multiple
output
--- 895,921 ----
(unless multiple
(if faces
(setq faces (list (car faces)))))
+ (require 'crm)
(let* ((input
;; Read the input.
! (completing-read-multiple
(if (or faces string-describing-default)
(format "%s (default %s): " prompt
! (if faces (mapconcat 'symbol-name faces ",")
string-describing-default))
(format "%s: " prompt))
! (complete-in-turn nonaliasfaces aliasfaces)
! nil t nil nil
! (if faces (mapconcat 'symbol-name faces ","))))
;; Canonicalize the output.
(output
! (cond ((or (equal input "") (equal input '("")))
! faces)
! ((stringp input)
! (mapcar 'intern (split-string input ", *" t)))
! ((listp input)
! (mapcar 'intern input))
! (input))))
;; Return either a list of faces or just one face.
(if multiple
output
- [Emacs-diffs] Changes to emacs/lisp/faces.el,
Juri Linkov <=