annotate lisp/packages/cu-edit-faces.el @ 110:fe104dbd9147 r20-1b7

Import from CVS: tag r20-1b7
author cvs
date Mon, 13 Aug 2007 09:19:45 +0200
parents 441bb1e64a06
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
26
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
1 ;;; edit-faces.el -- interactive face editing mode
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
2
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
3 ;; Copyright (C) 1997 Jens Lautenbacher
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
4 ;;
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
5 ;; This file is part of XEmacs.
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
6 ;;
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
7 ;; XEmacs is free software; you can redistribute it and/or modify
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
8 ;; it under the terms of the GNU General Public License as published by
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
9 ;; the Free Software Foundation; either version 2 of the License, or
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
10 ;; (at your option) any later version.
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
11 ;;
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
12 ;; XEmacs is distributed in the hope that it will be useful,
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
13 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
14 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
15 ;; GNU General Public License for more details.
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
16 ;;
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
17 ;; You should have received a copy of the GNU General Public License
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
18 ;; along with XEmacs; if not, write to the Free Software
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
19 ;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
20
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
21 ;;; Synched up with: Not in FSF.
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
22
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
23 ;;; Just another TTPC (Totally Trivial Piece of Code (TM)). All the
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
24 ;;; needed functionality for editing faces is already in custom.el. So
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
25 ;;; why don't use it, you may ask. OK, here I am...
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
26
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
27 (require 'custom)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
28 (require 'cl)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
29
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
30 ;;;###autoload
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
31 (defun cu-edit-faces ()
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
32 (interactive)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
33 (let (tmp-list elem)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
34 (put 'available-faces 'custom-group nil)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
35 (setq tmp-list (sort (face-list)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
36 '(lambda (one two)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
37 (if (string< (symbol-name one)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
38 (symbol-name two)) t
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
39 nil))))
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
40 (while (setq elem (pop tmp-list))
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
41 (custom-add-to-group 'available-faces elem 'custom-face))
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
42 (message "Please stand by while generating list of faces...")
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
43 (customize 'available-faces)))
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
44
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
45 (provide 'cu-edit-faces)
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
46
441bb1e64a06 Import from CVS: tag r19-15b96
cvs
parents:
diff changeset
47 ;;; cu-edit-faces.el ends here.