[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
intern-soft, find-face/get-face, and facep for determining faces' define
From: |
Brian Palmer |
Subject: |
intern-soft, find-face/get-face, and facep for determining faces' definedness |
Date: |
Mon, 01 Nov 2004 13:40:35 -0800 |
User-agent: |
Gnus/5.1002 (Gnus v5.10.2) XEmacs/21.4 (Reasonable Discussion, usg-unix-v) |
In vc.el, vc-annotate-lines, the following binding is established:
(face (or (intern-soft face-name)
(let ((tmp-face (make-face (intern face-name))))
(set-face-foreground tmp-face (cdr color))
(if vc-annotate-background
(set-face-background tmp-face
vc-annotate-background))
tmp-face))); Return the face
This is true in both emacs and the recently-synced xemacs vc.el (a
similar issue was present in the older xemacs code). This seems
frankly wrong to me; it doesn't matter whether the symbol has been
interned, it matters whether the face has been defined. A fix would be
in emacs to use (facep face-name) and in xemacs to use (find-face
face-name), instead.
The two different approaches seems troublesome to me; it'd be nice if
the same functions could be used in both . Xemacs developers, is there
any reason that xemacs's facep should not be extended to take either
face objects or names (so, for example, (facep 'bold) => t )? Or
could find-face/get-face be implemented for emacs? (They seem like
probably useful functions to me). It seems like it'd be as simple as
(if (facep FACE)
(make-face FACE)
(cerror 'nonexistent-face (format "Face %s doesn't exist" FACE)))
Or, both. Thoughts appreciated.
--
I'm awfully glad I'm a Beta, because I don't work so hard.
- intern-soft, find-face/get-face, and facep for determining faces' definedness,
Brian Palmer <=
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Stephen J. Turnbull, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Brian Palmer, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Miles Bader, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Brian Palmer, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Miles Bader, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Brian Palmer, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Miles Bader, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Stephen J. Turnbull, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Miles Bader, 2004/11/02
- Re: intern-soft, find-face/get-face, and facep for determining faces' definedness, Oliver Scholz, 2004/11/06