Mercurial > hg > xemacs-beta
diff lisp/x-faces.el @ 4215:de99c4dbad18
[xemacs-hg @ 2007-10-07 06:54:59 by stephent]
Fix list-colors-display bug on X11. <87bqbb2z4c.fsf@uwakimon.sk.tsukuba.ac.jp>
author | stephent |
---|---|
date | Sun, 07 Oct 2007 06:55:00 +0000 |
parents | 4f2243a0dc04 |
children | 49480d838d32 |
line wrap: on
line diff
--- a/lisp/x-faces.el Sat Oct 06 21:51:00 2007 +0000 +++ b/lisp/x-faces.el Sun Oct 07 06:55:00 2007 +0000 @@ -603,6 +603,15 @@ (defvar x-color-list-internal-cache) +;; Ben originally coded this in 2005/01 to return a list of lists each +;; containing a single string. This is apparently derived from use of +;; this list in completion, but in fact `read-color-completion-table' +;; already does this wrapping. So I'm changing this to return a list of +;; strings as the TTY code does, and as expected by r-c-c-t. +;; -- sjt 2007-10-06 + +;; This function is probably also used by the GTK platform. Cf. +;; gtk_color_list in src/objects-gtk.c. (defun x-color-list-internal () (if (boundp 'x-color-list-internal-cache) x-color-list-internal-cache @@ -623,12 +632,12 @@ (setq p (point)) (end-of-line) (setq color (buffer-substring p (point)) - clist (cons (list color) clist)) + clist (cons color clist)) ;; Ugh. If we want to be able to complete the lowercase form ;; of the color name, we need to add it twice! Yuck. (let ((dcase (downcase color))) (or (string= dcase color) - (push (list dcase) clist))) + (push dcase clist))) (forward-char 1)) (kill-buffer (current-buffer)))) (setq x-color-list-internal-cache clist)