comparison lisp/cus-edit.el @ 438:84b14dcb0985 r21-2-27

Import from CVS: tag r21-2-27
author cvs
date Mon, 13 Aug 2007 11:32:25 +0200
parents 9d177e8d4150
children 8de8e3f6228a
comparison
equal deleted inserted replaced
437:e2a4e8b94b82 438:84b14dcb0985
1 ;;; cus-edit.el --- Tools for customizating Emacs and Lisp packages. 1 ;;; cus-edit.el --- Tools for customizating Emacs and Lisp packages.
2 ;; 2 ;;
3 ;; Copyright (C) 1996, 1997 Free Software Foundation, Inc. 3 ;; Copyright (C) 1996, 1997, 2000 Free Software Foundation, Inc.
4 ;; 4 ;;
5 ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> 5 ;; Author: Per Abrahamsen <abraham@dina.kvl.dk>
6 ;; Maintainer: Hrvoje Niksic <hniksic@xemacs.org> 6 ;; Maintainer: Hrvoje Niksic <hniksic@xemacs.org>
7 ;; Keywords: help, faces 7 ;; Keywords: help, faces
8 ;; Version: 1.9960-x 8 ;; Version: 1.9960-x
2270 (define-widget 'custom-face-edit 'checklist 2270 (define-widget 'custom-face-edit 'checklist
2271 "Edit face attributes." 2271 "Edit face attributes."
2272 :format "%t: %v" 2272 :format "%t: %v"
2273 :tag "Attributes" 2273 :tag "Attributes"
2274 :extra-offset 12 2274 :extra-offset 12
2275 :button-args '(:help-echo "Control whether this attribute have any effect") 2275 :button-args '(:help-echo "Control whether this attribute has any effect")
2276 :args (mapcar (lambda (att) 2276 :args (mapcar (lambda (att)
2277 (list 'group 2277 (list 'group
2278 :inline t 2278 :inline t
2279 :sibling-args (widget-get (nth 1 att) :sibling-args) 2279 :sibling-args (widget-get (nth 1 att) :sibling-args)
2280 (list 'const :format "" :value (nth 0 att)) 2280 (list 'const :format "" :value (nth 0 att))
2754 (widget-group-match widget value))) 2754 (widget-group-match widget value)))
2755 :convert-widget 'custom-hook-convert-widget 2755 :convert-widget 'custom-hook-convert-widget
2756 :tag "Hook") 2756 :tag "Hook")
2757 2757
2758 (defun custom-hook-convert-widget (widget) 2758 (defun custom-hook-convert-widget (widget)
2759 ;; Handle `:custom-options'. 2759 ;; Handle `:options'.
2760 (let* ((options (widget-get widget :options)) 2760 (let* ((options (widget-get widget :options))
2761 (other `(editable-list :inline t 2761 (other `(editable-list :inline t
2762 :entry-format "%i %d%v" 2762 :entry-format "%i %d%v"
2763 (function :format " %v"))) 2763 (function :format " %v")))
2764 (args (if options 2764 (args (if options