;ELC ;;; Compiled by cyd@localhost on Mon Apr 23 22:21:16 2007 ;;; from file /home/cyd/emacs/lisp/wid-edit.el ;;; in Emacs version 22.0.99 ;;; with all optimizations. ;;; Function definitions are lazy-loaded. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. (if (and (boundp 'emacs-version) (< (aref emacs-version (1- (length emacs-version))) ?A) (or (and (boundp 'epoch::version) epoch::version) (string-lessp emacs-version "19.29"))) (error "`wid-edit.el' was compiled for Emacs 19.29 or later")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; #@64 Character position of the end of event if that exists, or nil. (defalias 'widget-event-point #[(event) #@178 ("\211:\2030\3028:\2030\302\2020\3038\2020\304 `\305\306F)\307 8\20670\303 8:\20340\303 8@\20270\303 8)\207" . [event position 2 1 selected-window (0 . 0) 0 5])(#$ . 715) nil 5 (#$ . 605)]) #@58 Non-nil if EVENT is a mouse-button-release event object. (defalias 'widget-button-release-event-p #[(event) #@342 ("\211\250\2030\302\303 \304\305\306\307\"S!\"!\2030\310\311 !!\20680 9\203)0 \312N\20680 :\20580 @9\20580 @\312N)\205Q0\311!\313>\205Q0\314\315!>\206Q0\316\315!>\207" . [event obj zerop logand lognot lsh 134217728 1 char-valid-p event-basic-type event-symbol-elements (mouse-1 mouse-2 mouse-3) click event-modifiers drag])(#$ . 1042) nil 8 (#$ . 927)]) (byte-code "\300\301\302\303\304\305\304\306\307\310\311\312\311\313& \210\300\314\302\315\311\301%\210\300\316\302\317\311\301\311\320&\207" [custom-declare-group widgets nil "Customization support for the Widget Library." :link (custom-manual "(widget)Top") (emacs-library-link :tag "Lisp File" "widget.el") :prefix "widget-" :group extensions hypermedia widget-documentation "Options controlling the display of documentation strings." widget-faces "Faces used by the widget library." faces] 14) #@120 Face used for documentation strings in widgets. This exists as a variable so it can be set locally in certain buffers. (defvar widget-documentation-face 'widget-documentation (#$ . 1919)) (byte-code "\300\301\302\303\304\301\304\305&\210\306\307\310\301#\207" [custom-declare-face widget-documentation ((((class color) (background dark)) (:foreground "lime green")) (((class color) (background light)) (:foreground "dark green")) (t nil)) "Face used for documentation text." :group widget-faces put widget-documentation-face face-alias] 8) #@106 Face used for buttons in widgets. This exists as a variable so it can be set locally in certain buffers. (defvar widget-button-face 'widget-button (#$ . 2467)) (byte-code "\300\301\302\303\304\305%\210\306\307\310\301#\207" [custom-declare-face widget-button ((t (:weight bold))) "Face used for widget buttons." :group widget-faces put widget-button-face face-alias] 6) #@60 Face used for widget buttons when the mouse is above them. (custom-declare-variable 'widget-mouse-face ''highlight '(#$ . 2843) :type 'face :group 'widget-faces) (byte-code "\300\301\302\303\304\305%\210\306\307\310\301#\210\300\311\312\313\304\305%\210\306\314\310\311#\207" [custom-declare-face widget-field ((((type tty)) :background "yellow3" :foreground "black") (((class grayscale color) (background light)) :background "gray85") (((class grayscale color) (background dark)) :background "dim gray") (t :slant italic)) "Face used for editable fields." :group widget-faces put widget-field-face face-alias widget-single-line-field ((((type tty)) :background "green3" :foreground "black") (((class grayscale color) (background light)) :background "gray85") (((class grayscale color) (background dark)) :background "dim gray") (t :slant italic)) "Face used for editable fields spanning only a single line." widget-single-line-field-face] 6) #@148 Return string representation of OBJECT, any Lisp object. No quoting characters are used; no delimiters are printed around the contents of strings. (defalias 'widget-princ-to-string #[(object) #@192 ("\302\303\304!!\211\305 !\210)rq\210\306 \307\310!\210*\207" . [standard-output object get-buffer-create generate-new-buffer-name " *string-output*" princ buffer-string kill-buffer nil])(#$ . 3992) nil 4 (#$ . 3793)]) #@29 Clear all undo information. (defalias 'widget-clear-undo #[nil #@68 ("\300p!\210\301 \207" . [buffer-disable-undo buffer-enable-undo])(#$ . 4289) nil 2 (#$ . 4220)]) #@96 Largest number of items allowed in a popup-menu. Larger menus are read through the minibuffer. (custom-declare-variable 'widget-menu-max-size '40 '(#$ . 4393) :group 'widgets :type 'integer) #@130 Largest number of items for which it works to choose one with a character. For a larger number of items, the minibuffer is used. (custom-declare-variable 'widget-menu-max-shortcuts '40 '(#$ . 4591) :group 'widgets :type 'integer) #@122 *Control how to ask for a choice from the keyboard. Non-nil means use the minibuffer; nil means read a single character. (custom-declare-variable 'widget-menu-minibuffer-flag 'nil '(#$ . -4828) :group 'widgets :type 'boolean) #@555 Choose an item from a list. First argument TITLE is the name of the list. Second argument ITEMS is a list whose members are either (NAME . VALUE), to indicate selectable items, or just strings to indicate unselectable items. Optional third argument EVENT is an input event. The user is asked to choose between each NAME from the items alist, and the VALUE of the chosen element will be returned. If EVENT is a mouse event, and the number of elements in items is less than `widget-menu-max-size', a popup menu will be used, otherwise the minibuffer. (defalias 'widget-choose #[(title items &optional event) #@1790 ("G W\2030\n\2030\306 \2030\307\n \310BD\"\207\f\204$0G V\203Q0\311\312\"\313 \314P\315\316$\211(;\205O0\317(\"\211);\203H0)(\320(\"A))\207\321 *\322+\315\211,-\315\211./\323*\324\321 !\211,#\210r\325\326!q\210\327 \210\330c\210\203\2670@-A-:\203\2570-@0-A1\331\332+0#c\210\323,\333+!1#\210\316.*+T+\202|0\334c\210).\204\3040\335\336!\210\323,\337\340#\210\323,\341\340#\210\323,\342\343#\210\323,\344\345#\210,\211A\237\241\210\346\213\210/\340=\203\3650\335\347!\210/.\207" . [items widget-menu-max-size event title widget-menu-minibuffer-flag widget-menu-max-shortcuts display-popup-menus-p x-popup-menu "" widget-remove-if stringp completing-read ": " nil t try-completion assoc make-sparse-keymap 48 define-key " " get-buffer-create " widget-choose" erase-buffer "Available choices:\n\n" format "%c = %s\n" vector "\nC-g = Quit" error "None of the choices is currently meaningful" [7] keyboard-quit [t] [134217750] scroll-other-window [134217773] negative-argument ((byte-code "\306\307!\310\311!!\210\312\313\314\315\n\250\203#0\n\316Y\203#0\n W\204w0\317=\204w0\320B\321!\322 \312# \315H\323=\203f0\324!\314 V\203]0\325\326!!\210\202`0\323 \210\315)\2020\327=\203r0\330\2020\315\2020-\313\207" [buf arg char keys cursor-in-echo-area next-digit get-buffer " widget-choose" fit-window-to-buffer display-buffer t nil 0 1 48 keyboard-quit 32 read-key-sequence lookup-key scroll-other-window get-buffer-window scroll-other-window-down window-height negative-argument -1 value unread-command-events title overriding-terminal-local-map minibuffer-scroll-window] 4)) "Canceled" val try overriding-terminal-local-map next-digit map choice some-choice-enabled value name function])(#$ . 5680) nil 6 (#$ . 5061)]) (defalias 'widget-remove-if #[(predictate list) #@99 ("\304 \2030 @!\2040 @\nB A\211\2040\n\237*\207" . [list tail result predictate nil])(#$ . 7554) nil 3]) #@148 Non-nil means add extra space at the end of editable text fields. If you don't add the space, it will become impossible to edit a zero size field. (defconst widget-field-add-space nil (#$ . 7678)) #@228 Non-nil means use `before-change-functions' to track editable fields. This enables the use of undo, but doesn't work on Emacs 19.34 and earlier. Using before hooks also means that the :notify function can't know the new value. (defvar widget-field-use-before-change t (#$ . 7882)) #@57 Specify editable button for WIDGET between FROM and TO. (defalias 'widget-specify-field #[(widget from to) #@801 ("\212b\210\306 \307\"\2040\310u\210\2020\n\2030\311\312!\210`)\306 \313\"\306 \314\"\206(0\315\306 \316\"\306 \317\"\n?\20690\306 \307\"_\320 !\203H0\321Sf\322U\203\2140\323S\324\325\324% \326 \327\330#\210\326 \331 #\210\326 \332_#\210\326 \333#\210\326 \304\f#\210\326 \305 #\210)S\325\323!\324\211 % \334 \335 #\210\326 \327 #\210\326 \332_#\210\326 \333#\210\326 \304\f#\210\326 \305 #\210.\336 !\207" . [to widget widget-field-add-space rear-sticky follow-link help-echo widget-get :size 1 insert-and-inherit " " :keymap :value-face widget-field :help-echo :follow-link functionp widget-mouse-help 10 make-overlay nil t overlay-put field boundary real-field local-map face widget-put :field-overlay widget-specify-secret keymap overlay from])(#$ . 8283) nil 7 (#$ . 8169)]) #@60 Replace text in FIELD with value of `:secret', if non-nil. (defalias 'widget-specify-secret #[(field) #@329 ("\306\307\"\306\310\"\211\205V0\311!\312! \203/0 \fV\203/0 Sf\313=\203/0 S\211\2020\f W\205U0\ff\211\n=\204N0\314\f\211T \n$\210\315\f\211T\302 $\210\fT)\202/0**\207" . [field size secret end begin old widget-get :secret :size widget-field-start widget-field-end 32 subst-char-in-region put-text-property])(#$ . 9229) nil 6 (#$ . 9120)]) #@48 Specify button for WIDGET between FROM and TO. (defalias 'widget-specify-button #[(widget from to) #@559 ("\306 \307\310\307%\311\n\312\"\311\n\313\"\314\n\315 #\210\316 !\203 0\317\320 \321\n#\210\320 \322\311\n\323\"#\210\320 \324\310#\210\311\n\325\"\204N0\320 \326\327\n\330\"#\210\320 \331\327\n\332\"#\210\320 \333\334#\210\320 \304\f#\210\320 \303 #+\207" . [from to widget help-echo follow-link overlay make-overlay nil t widget-get :follow-link :help-echo widget-put :button-overlay functionp widget-mouse-help overlay-put button keymap :keymap evaporate :suppress-face face widget-apply :button-face-get mouse-face :mouse-face-get pointer hand])(#$ . 9700) nil 6 (#$ . 9594)]) #@64 Help-echo callback for widgets whose :help-echo is a function. (defalias 'widget-mouse-help #[(window overlay point) #@186 ("r\303!q\210\304\305!!\211\2050\306 \307\"\310\n!\203!0\n !\202\"0\n+\207" . [overlay widget help-echo overlay-buffer widget-at overlay-start widget-get :help-echo functionp])(#$ . 10419) nil 4 (#$ . 10295)]) #@48 Specify sample for WIDGET between FROM and TO. (defalias 'widget-specify-sample #[(widget from to) #@218 ("\304 \305\306\305%\307\n\310\311 \312\"#\210\307\n\313\306#\210\314 \315\n#)\207" . [from to overlay widget make-overlay nil t overlay-put face widget-apply :sample-face-get evaporate widget-put :sample-overlay])(#$ . 10749) nil 6 (#$ . 10643)]) #@55 Specify documentation for WIDGET between FROM and TO. (defalias 'widget-specify-doc #[(widget from to) #@229 ("\305 \306\307\306%\310\n\311 #\210\310\n\312\f#\210\310\n\313\307#\210\314 \315\n#)\207" . [from to overlay widget widget-documentation-face make-overlay nil t overlay-put widget-doc face evaporate widget-put :doc-overlay])(#$ . 11115) nil 6 (#$ . 11005)]) #@54 Execute FORM without inheriting any text properties. (defalias 'widget-specify-insert '(macro . #[(&rest form) #@202 ("\301\302\303\304\305\306B\307BBFD\207" . [form save-restriction let ((inhibit-read-only t) (inhibit-modification-hooks t)) (narrow-to-region (point) (point)) prog1 progn ((goto-char (point-max)))])(#$ . 11500) nil 7 (#$ . 11382)])) (byte-code "\300\301\302\303\304\305%\210\306\307\310\301#\207" [custom-declare-face widget-inactive ((t :inherit shadow)) "Face used for inactive widgets." :group widget-faces put widget-inactive-face face-alias] 6) #@46 Make WIDGET inactive for user modifications. (defalias 'widget-specify-inactive #[(widget from to) #@313 ("\304\305\"?\205.0\306 \n\307\310\307%\311 \312\313#\210\311 \314\310#\210\311 \315\316#\210\311 \317\320#\210\321\305 #)\207" . [widget from to overlay widget-get :inactive make-overlay nil t overlay-put face widget-inactive evaporate priority 100 modification-hooks (widget-overlay-inactive) widget-put])(#$ . 12064) nil 6 (#$ . 11958)]) #@42 Ignoring the arguments, signal an error. (defalias 'widget-overlay-inactive #[(&rest junk) #@88 ("?\2050\301\302!\207" . [inhibit-read-only error "The widget here is not active"])(#$ . 12512) nil 2 (#$ . 12415)]) #@44 Make WIDGET active for user modifications. (defalias 'widget-specify-active #[(widget) #@129 ("\302\303\"\211\2050\304 !\210\305\303\306#)\207" . [widget inactive widget-get :inactive delete-overlay widget-put nil])(#$ . 12732) nil 5 (#$ . 12638)]) #@38 Return the type of WIDGET, a symbol. (defalias 'widget-type #[(widget) #@23 ("@\207" . [widget])(#$ . 12976) nil 1 (#$ . 12899)]) (put 'widget-type 'byte-optimizer 'byte-compile-inline-expand) #@40 Return non-nil iff WIDGET is a widget. (defalias 'widgetp #[(widget) #@78 ("9\203 0\301N\207:\2050@9\2050@\301N\207" . [widget widget-type])(#$ . 13175) nil 2 (#$ . 13100)]) #@119 In WIDGET, get the value of PROPERTY. If the value is a symbol, return its binding. Otherwise, just return the value. (defalias 'widget-get-indirect #[(widget property) #@81 ("\303 \"\2119\2030\nJ\2020\n)\207" . [widget property value widget-get])(#$ . 13467) nil 4 (#$ . 13292)]) #@59 Non-nil iff there is a definition in WIDGET for PROPERTY. (defalias 'widget-member #[(widget property) #@131 ("\302A \"\203\n0\303\207@\2030\304@\305N \"\207\306\207" . [widget property plist-member t widget-member widget-type nil])(#$ . 13696) nil 3 (#$ . 13586)]) #@38 Extract the current value of WIDGET. (defalias 'widget-value #[(widget) #@85 ("\301\302\301\303\"#\207" . [widget widget-apply :value-to-external :value-get])(#$ . 13943) nil 6 (#$ . 13865)]) #@43 Set the current value of WIDGET to VALUE. (defalias 'widget-value-set #[(widget value) #@91 ("\302\303\302\304 ##\207" . [widget value widget-apply :value-set :value-to-internal])(#$ . 14159) nil 7 (#$ . 14066)]) #@47 Extract the default external value of WIDGET. (defalias 'widget-default-get #[(widget) #@123 ("\301\302\303\304\"\2060\301\305\"#\207" . [widget widget-apply :value-to-external widget-get :value :default-get])(#$ . 14382) nil 6 (#$ . 14288)]) #@37 In WIDGET, match the start of VALS. (defalias 'widget-match-inline #[(widget vals) #@160 ("\302\303\"\203 0\304\305 #\207 <\203\"0\304\306 @#\203\"0 @C AB\207\307\207" . [widget vals widget-get :inline widget-apply :match-inline :match nil])(#$ . 14633) nil 4 (#$ . 14543)]) #@47 Apply :action in WIDGET in response to EVENT. (defalias 'widget-apply-action #[(widget &optional event) #@151 ("\302\303\"\203 0\302\304 #\207\305\306!\207" . [widget event widget-apply :active :action error "Attempt to perform action on inactive widget"])(#$ . 14942) nil 4 (#$ . 14831)]) #@120 Prompt for a value matching WIDGET, using PROMPT. The current value is assumed to be VALUE, unless UNBOUND is non-nil. (defalias 'widget-prompt-value #[(widget prompt &optional value unbound) #@243 ("<\2040C\305\306\211@) #\307!\310\311 \n %\310\312\f#\204,0\313\314@\"\210\f)\207" . [widget prompt value unbound answer format "[%s] %s" widget-convert widget-apply :prompt-value :match error "Value does not match %S type"])(#$ . 15331) nil 7 (#$ . 15132)]) #@110 Get the item WIDGET is assumed to toggle. This is only meaningful for radio buttons or checkboxes in a list. (defalias 'widget-get-sibling #[(widget) #@246 ("\303\211\304\"\305\"\306\302\307\215*\207" . [widget children child widget-get :parent :children nil (byte-code "\2030@A\303 \304\"\n=\20300\305\301 \"\210\20200\306\207" [children child widget widget-get :button throw nil] 3)])(#$ . 15770) nil 4 (#$ . 15613)]) #@237 Map FUNCTION over the buttons in BUFFER. FUNCTION is called with the arguments WIDGET and MAPARG. If FUNCTION returns non-nil, the walk is cancelled. The arguments MAPARG, and BUFFER default to nil and (current-buffer), respectively. (defalias 'widget-map-buttons #[(function &optional buffer maparg) #@227 ("e\306\2030rq\210\307 )\2020\307 \310 @ A\" \211A@\211\205<0\311 \312\"\211\2030\f\n \"\2030\306\211\2020+\207" . [buffer overlays widget cur function maparg nil overlay-lists append overlay-get button])(#$ . 16365) nil 4 (#$ . 16055)]) #@121 Where widget button images are located. If this variable is nil, widget will try to locate the directory automatically. (custom-declare-variable 'widget-image-directory '(file-name-as-directory (expand-file-name "custom" data-directory)) '(#$ . 16631) :group 'widgets :type 'directory) #@58 If non-nil, use image buttons in widgets when available. (custom-declare-variable 'widget-image-enable 't '(#$ . 16923) :version "21.1" :group 'widgets :type 'boolean) #@60 Conversion alist from image formats to file name suffixes. (custom-declare-variable 'widget-image-conversion ''((xpm ".xpm") (gif ".gif") (png ".png") (jpeg ".jpg" ".jpeg") (xbm ".xbm")) '(#$ . 17097) :group 'widgets :type '(repeat (cons :format "%v" (symbol :tag "Image Format" unknown) (repeat :tag "Suffixes" (string :format "%v"))))) #@224 Create a graphical button from IMAGE. IMAGE should either already be an image, or be a file name sans extension (xpm, xbm, gif, jpg, or png) located in `widget-image-directory' or otherwise where `find-image' will find it. (defalias 'widget-image-find #[(image) #@422 ("\203 0 \203 0\306 \2040\307\207:\2030@\300=\2030\207;\203p0\n B\307 \307 \211\f\203g0\f@\211 A\307 \211\203]0@ \310 @\311 PF\fBA\211\204B0*\fA\211\f\20420*\f\237\312\f!*\207\307\207" . [image widget-image-enable widget-image-directory load-path specs widget-image-conversion display-graphic-p nil :type :file find-image elt #1=#:--cl-dolist-temp-- ext #2=#:--cl-dolist-temp--])(#$ . 17711) nil 7 (#$ . 17442)]) #@114 Face used for pressed buttons in widgets. This exists as a variable so it can be set locally in certain buffers. (defvar widget-button-pressed-face 'widget-button-pressed (#$ . 18172)) #@340 In WIDGET, insert the text TAG or, if supported, IMAGE. IMAGE should either be an image or an image file name sans extension (xpm, xbm, gif, jpg, or png) located in `widget-image-directory'. Optional arguments DOWN and INACTIVE are used instead of IMAGE when the button is pressed or inactive, respectively. These are currently ignored. (defalias 'widget-image-insert #[(widget tag image &optional down inactive) #@231 ("\304 \2030\305!\211\2030\306 \307\310#\210\311\312\n\313 #\"\207\nc\207" . [image widget tag widget-button-pressed-face display-graphic-p widget-image-find widget-put :suppress-face t insert-image propertize mouse-face])(#$ . 18786) nil 6 (#$ . 18364)]) #@67 Move to where you click, and if it is an active field, invoke it. (defalias 'widget-move-and-invoke #[(event) #@157 ("\302!\210\303!\211\2050\304 \305\"\2050\306!)\207" . [event pos mouse-set-point widget-event-point get-char-property button widget-button-click])(#$ . 19172) nil 4 (#$ . 19055) "e"]) (custom-declare-group 'widget-button nil "The look of various kinds of buttons." :group 'widgets) #@36 String used as prefix for buttons. (custom-declare-variable 'widget-button-prefix '"" '(#$ . 19469) :type 'string :group 'widget-button) #@36 String used as suffix for buttons. (custom-declare-variable 'widget-button-suffix '"" '(#$ . 19612) :type 'string :group 'widget-button) #@76 Create widget of TYPE. The optional ARGS are additional keyword arguments. (defalias 'widget-create #[(type &rest args) #@104 ("\303\304 #\305\n\306\"\210\n)\207" . [type args widget apply widget-convert widget-apply :create])(#$ . 19882) nil 4 (#$ . 19755)]) #@117 As part of the widget PARENT, create a child widget TYPE. The child is converted, using the keyword arguments ARGS. (defalias 'widget-create-child-and-convert #[(parent type &rest args) #@283 ("\304\305 #\306\n\307 #\210\310\n\311\"\204.0\306\n\311\310 \311\"\2060\312\310\n\313\"\206&0\312\\\310 \314\"\\#\210\315\n\316\"\210\n)\207" . [type args widget parent apply widget-convert widget-put :parent widget-get :indent 0 :extra-offset :offset widget-apply :create])(#$ . 20218) nil 7 (#$ . 20025)]) #@24 Create widget of TYPE. (defalias 'widget-create-child #[(parent type) #@261 ("\303!\304 \305\n#\210\306 \307\"\204,0\304 \307\306\n\307\"\2060\310\306 \311\"\206$0\310\\\306\n\312\"\\#\210\313 \314\"\210 )\207" . [type widget parent widget-copy widget-put :parent widget-get :indent 0 :extra-offset :offset widget-apply :create])(#$ . 20616) nil 7 (#$ . 20539)]) #@41 Create widget of TYPE with value VALUE. (defalias 'widget-create-child-value #[(parent type value) #@316 ("\304!\305 \306\307 \310\n##\210\305 \311 #\210\312 \313\"\20460\305 \313\312 \313\"\206&0\314\312 \315\"\206.0\314\\\312 \316\"\\#\210\307 \317\"\210 )\207" . [type widget value parent widget-copy widget-put :value widget-apply :value-to-internal :parent widget-get :indent 0 :extra-offset :offset :create])(#$ . 21021) nil 7 (#$ . 20915)]) #@16 Delete WIDGET. (defalias 'widget-delete #[(widget) #@53 ("\301\302\"\207" . [widget widget-apply :delete])(#$ . 21432) nil 3 (#$ . 21375)]) #@29 Make a deep copy of WIDGET. (defalias 'widget-copy #[(widget) #@70 ("\301\302!\303\"\207" . [widget widget-apply copy-sequence :copy])(#$ . 21591) nil 3 (#$ . 21523)]) #@114 Convert TYPE to a widget without inserting it in the buffer. The optional ARGS are additional keyword arguments. (defalias 'widget-convert #[(type &rest args) #@747 ("9\203\n0C\202 0\306!\211\307\f\nA\203V0\310\n\211A@)!\203I0\n\211AA)\203I0\n\211A@)\311=\203A0\307\211\2020\nAA\211\2020\n\311\nAD\241\210\307\211\2020\f\203\2120 \204\2120\f@\311=\203r0\f\211A@)\312\202V0\310\f@!\203\2050\f\211AA)\211\202W0\312\202V0 \203\2240\313 \311\f#\210 \211\203\2640\314A\315\"\211\203\2520 !)@\316N\211\204\2320 \203\3310 @\310!\203\3230\313  A@#\210 AA\202\3250\307)\202\2640\317 \320\"\203\3550\313 \320\321 \322\323 \320\"##\210 ,\207" . [type widget current done args keys copy-sequence nil keywordp :args t widget-put plist-get :convert-widget widget-type widget-member :value widget-apply :value-to-internal widget-get x convert-widget next])(#$ . 21866) nil 10 (#$ . 21700)]) #@64 Call `insert' with ARGS even if surrounding text is read only. (defalias 'widget-insert #[(&rest args) #@102 ("\303\211\304\305\n\"*\207" . [inhibit-modification-hooks inhibit-read-only args t apply insert])(#$ . 22762) nil 3 (#$ . 22652)]) #@335 Return a widget of type TYPE with endpoint FROM TO. No text will be inserted to the buffer, instead the text between FROM and TO will be used as the widgets end points. If optional arguments BUTTON-FROM and BUTTON-TO are given, these will be used as the widgets button end points. Optional ARGS are extra keyword arguments for TYPE. (defalias 'widget-convert-text #[(type from to &optional button-from button-to &rest args) #@319 ("\306\307\310\311 %\312\n!\312 !\313\n\314\"\210\313 \315\"\210\316\f\317\n#\210\316\f\320 #\210 \20310\321\f #\210\f+\207" . [type args from to widget button-from apply widget-convert :delete widget-leave-text copy-marker set-marker-insertion-type t nil widget-put :from :to widget-specify-button button-to])(#$ . 23335) nil 6 (#$ . 22903)]) #@264 Return a widget of type TYPE with endpoint FROM TO. Optional ARGS are extra keyword arguments for TYPE. No text will be inserted to the buffer, instead the text between FROM and TO will be used as the widgets end points, as well as the widgets button end points. (defalias 'widget-convert-button #[(type from to &rest args) #@76 ("\304\305 \n \n &\207" . [type from to args apply widget-convert-text])(#$ . 24023) nil 8 (#$ . 23693)]) #@59 Remove markers and overlays from WIDGET and its children. (defalias 'widget-leave-text #[(widget) #@378 ("\305\306\"\305\307\"\305\310\"\305\311\"\305\312\"\313\211\223\210\305\314\"\313\211\223\210\f\203,0\315\f!\210 \20340\315 !\210\n\203<0\315\n!\210 \203D0\315 !\210\316\317\305\320\"\",\207" . [widget field doc sample button widget-get :button-overlay :sample-overlay :doc-overlay :field-overlay :from nil :to delete-overlay mapc widget-leave-text :children])(#$ . 24242) nil 6 (#$ . 24137)]) (defalias 'advertised-widget-backward 'widget-backward) #@122 Keymap containing useful binding for buffers containing widgets. Recommended as a parent keymap for modes using widgets. (defvar widget-keymap (byte-code "\301 \302\303\304#\210\302\305\306#\210\302\307\310#\210\302\311\306#\210\302\312\313#\210\302\314\313#\210\302\315\316#\210)\207" [map make-sparse-keymap define-key " " widget-forward " " widget-backward [(shift tab)] advertised-widget-backward [backtab] [down-mouse-2] widget-button-click [down-mouse-1] " " widget-button-press] 4) (#$ . 24715)) #@57 Keymap used for events a widget does not handle itself. (defvar widget-global-map global-map (#$ . 25234)) (make-variable-buffer-local 'widget-global-map) #@39 Keymap used inside an editable field. (defvar widget-field-keymap (byte-code "\302!\303 \304\305#\210\303 \306\307#\210\303 \310\311#\210\303 \312\313#\210 )\207" [widget-keymap map copy-keymap define-key " " widget-kill-line "\211" widget-complete " " widget-field-activate "" widget-end-of-line] 4) (#$ . 25395)) #@34 Keymap used inside a text field. (defvar widget-text-keymap (byte-code "\302!\303 \304\305#\210 )\207" [widget-keymap map copy-keymap define-key "" widget-end-of-line] 4) (#$ . 25719)) #@37 Invoke the editable field at point. (defalias 'widget-field-activate #[(pos &optional event) #@184 ("\304!\211\2030\305 \n\"\2020\306\307 \310 \"!)\207" . [pos field event widget-global-map widget-field-at widget-apply-action call-interactively lookup-key this-command-keys])(#$ . 26013) nil 5 (#$ . 25913) "@d"]) (byte-code "\300\301\302\303\304\305%\210\306\307\310\301#\207" [custom-declare-face widget-button-pressed ((((min-colors 88) (class color)) (:foreground "red1")) (((class color)) (:foreground "red")) (t (:weight bold :underline t))) "Face used for pressed buttons." :group widget-faces put widget-button-pressed-face face-alias] 6) #@150 If non-nil, `widget-button-click' moves point to a button after invoking it. If nil, point returns to its original position after invoking a button. (defvar widget-button-click-moves-point nil (#$ . 26574)) #@50 Invoke the button that the mouse is pointing at. (defalias 'widget-button-click #[(event) #@2594 ("\306!\203\2510\307!\310>\306!\211:\203_0\3118\202%0\312 `\313\314F)\315 \316\317\f\314 8)!\205=0\320\f\314 8)!#\321_\203N0\322\323\215\205\2460\324\321 !\n\203s0\325\"\326\"\211 \203i0\321!\202\2130\325\"\327\" \202\2130\325\"\330\"\211 \203\2040\321!\202\2130\325\"\331\" !\203\2340\332!\204\2340\333 \202\2200 \205\2450\334 !*.\207\335\336!\207" . [event oevent mouse-1 pos start position widget-event-point event-basic-type (mouse-1 down-mouse-1) 1 selected-window #1=(0 . 0) 0 get-char-property button windowp window-buffer nil button-press-cancelled (byte-code "\306 \307\310\311 \"r\312\216\313\n\211:\2030\314\n8\202 0\306 `\315\316F)\316 8)!\210\212\n\211:\20360\314\n8\202<0\306 `\315\316F)\317 8\206U0\314 8:\203R0\314 8@\202U0\314 8)b\210\320\f\321\"\320\f\322\"\206f0&'\323 \324\"\323 \325\"\326\216\212\203\2120\327 \324'#\210\327 \325'#\210\330\f\331\n#\204\n\332(\333\n!\204 \334 )\203\2740\n\211*\242)\335=\203\2740\n+B+,\336\337\332\"\210\n\250\204\2250\n@\340>\204\2250\n@\341=\204\2250\342\n!\211-\203\3700\343-\304\"\f=\203\3700\203\2250\327 \324'#\210\327 \325'#\210\202\2250\327 \324#\210\327 \325#\210\202\2250)-\203*\343-\304\"\f=\203*-b\210\344\f\n\"\210.\203*`/./\2035/b\210,\345\207" [save-selected-window-alist save-selected-window-window event position button overlay selected-window mapcar #[(frame) "\301!D\207" [frame frame-selected-window] 3] frame-list ((byte-code "\305\211\203/0\n@\306 @!\203(0\307 \211A@)!\203(0\310 @ \211A@)\"\210\nA\211\2040*\307\f!\203:0\311\f!\210\305\207" [save-selected-window-alist elt #2=#:--cl-dolist-temp-- x save-selected-window-window nil frame-live-p window-live-p set-frame-selected-window select-window] 4)) select-window 1 #1# 0 5 widget-get :button-overlay :pressed-face overlay-get face mouse-face ((byte-code "\303\301 #\210\303\302\n#\207" [overlay face mouse-face overlay-put] 4)) overlay-put widget-apply :mouse-down-action t widget-button-release-event-p read-event mouse-movement throw button-press-cancelled (switch-frame select-window) scroll-bar-movement widget-event-point get-char-property widget-apply-action nil widget-button-pressed-face pressed-face track-mouse mouse-1 object unread-command-events oevent pos widget-button-click-moves-point newpoint] 6) t lookup-key [down-mouse-1] [mouse-1] [down-mouse-2] [mouse-2] widget-button-release-event-p read-event call-interactively message "You clicked somewhere weird." newpoint command up widget-global-map])(#$ . 26885) nil 7 (#$ . 26787) "e"]) #@23 Invoke button at POS. (defalias 'widget-button-press #[(pos &optional event) #@228 ("\305\301\"\211\2030\306 \n\"\202 0\307 \310 \"\311\f!\205_0\312\f!))\207" . [pos button event widget-global-map command get-char-property widget-apply-action lookup-key this-command-keys commandp call-interactively])(#$ . 29605) nil 4 (#$ . 29521) "@d"]) #@81 Return the tabable widget at POS, or nil. POS defaults to the value of (point). (defalias 'widget-tabable-at #[(&optional pos) #@131 ("\303!\211\2050\304 \305\"\211\2030\n\306Y\2050 \2020 ))\207" . [pos widget order widget-at widget-get :tab-order 0])(#$ . 30010) nil 4 (#$ . 29876)]) #@134 If non-nil, use overlay change functions to tab around in the buffer. This is much faster, but doesn't work reliably on Emacs 19.34. (defvar widget-use-overlay-change t (#$ . 30180)) #@83 Move point to the ARG next field or button. ARG may be negative to move backward. (defalias 'widget-move #[(arg) #@651 ("o\204 0\306V\204 0\307u\210\306\310 \306V\203\\0m\203'0eb\210 T\20260\f\20330\311`!b\210\20260\312u\210 \313U\203F0\n=\203F0\314\315!\210\310 \211\203X0 =\204X0S )\2020\306W\203\2420o\203o0db\210 T\202~0\f\203{0\316`!b\210\202~0\307u\210 \313U\203\2160\n=\203\2160\314\315!\210\310 \211\203\2360 =\204\2360T)\202\\0\310 \310 =\203\2620\307u\210\202\2450)\317u\210+\320`!\210\321\322!\207" . [arg old number wrapped widget-use-overlay-change new 0 -1 widget-tabable-at next-overlay-change 1 2 error "No buttons or fields found" previous-overlay-change nil widget-echo-help run-hooks widget-move-hook])(#$ . 30489) nil 4 (#$ . 30369)]) #@90 Move point to the next field or button. With optional ARG, move across that many fields. (defalias 'widget-forward #[(arg) #@79 ("\301\302!\210\303!\207" . [arg run-hooks widget-forward-hook widget-move])(#$ . 31307) nil 2 (#$ . 31178) "p"]) #@94 Move point to the previous field or button. With optional ARG, move across that many fields. (defalias 'widget-backward #[(arg) #@81 ("\301\302!\210\303[!\207" . [arg run-hooks widget-backward-hook widget-move])(#$ . 31562) nil 2 (#$ . 31428) "p"]) (defalias 'widget-beginning-of-line 'beginning-of-line) #@138 Go to end of field or end of line, whichever is first. Trailing spaces at the end of padded fields are not considered part of the field. (defalias 'widget-end-of-line #[nil #@68 ("\300\210l?\2050\301\302`S!x\207" . [nil " " field-beginning])(#$ . 31921) nil 3 (#$ . 31742) nil]) #@58 Kill to end of field or end of line, whichever is first. (defalias 'widget-kill-line #[nil #@205 ("\302`!\211\205 0\303!\203_0\304\305! V\203_0\306` \"\202\"0\307\310!*\207" . [field end widget-field-find widget-field-end line-beginning-position 2 kill-region call-interactively kill-line])(#$ . 32129) nil 4 (#$ . 32031) nil]) #@56 Default function to call for completion inside fields. (custom-declare-variable 'widget-complete-field '(lookup-key global-map "\211") '(#$ . 32376) :options '(ispell-complete-word complete-tag lisp-complete-symbol) :type 'function :group 'widgets) #@18 Narrow to field. (defalias 'widget-narrow-to-field #[nil #@110 ("\301`!\211\205 0\302 \303 })\207" . [field widget-field-find line-beginning-position line-end-position])(#$ . 32695) nil 3 (#$ . 32631) nil]) #@111 Complete content of editable field from point. When not inside a field, move to the previous button or field. (defalias 'widget-complete #[nil #@177 ("\301`!\211\2030\214\302 \210\303\304\")\2020\305\306!)\207" . [field widget-field-find widget-narrow-to-field widget-apply :complete error "Not in an editable field"])(#$ . 32998) nil 4 (#$ . 32848) nil]) #@58 List of all newly created editable fields in the buffer. (defvar widget-field-new nil (#$ . 33217)) (make-variable-buffer-local 'widget-field-new) #@44 List of all editable fields in the buffer. (defvar widget-field-list nil (#$ . 33370)) (make-variable-buffer-local 'widget-field-list) #@46 The button or field at POS (default, point). (defalias 'widget-at #[(&optional pos) #@91 ("\301\2060`\302\"\2060\303!\207" . [pos get-char-property button widget-field-at])(#$ . 33601) nil 3 (#$ . 33511)]) #@55 Setup current buffer so editing string widgets works. (defalias 'widget-setup #[nil #@355 ("\306\211\307 \203;0 @ A\fB\310\311\"@\310\311\"A\312\313!\313 !#\210\307\211\223\210 \307\211\223\210*\2020+\314 \210\315 \207" . [field inhibit-modification-hooks inhibit-read-only widget-field-new widget-field-list to t nil widget-get :field-overlay widget-specify-field marker-position widget-clear-undo widget-add-change from])(#$ . 33821) nil 5 (#$ . 33730)]) (byte-code "\301B\302\301!\204\303\301\304\"\210\305\301!\210\306B\302\306!\204\"\303\306\304\"\210\305\306!\207" [current-load-list widget-field-last default-boundp set-default nil make-variable-buffer-local widget-field-was] 3) #@49 Return the widget field at POS, or nil if none. (defalias 'widget-field-at #[(pos) #@126 ("\302\2060`\301\"\211\303=\2030\302\2060`\304\"\2020 )\207" . [pos field get-char-property boundary real-field])(#$ . 34541) nil 4 (#$ . 34451)]) #@46 Return the buffer of WIDGET's editing field. (defalias 'widget-field-buffer #[(widget) #@148 ("\302\303\"\304 !\2030\305 !\2020 :\2050\306 @!)\207" . [widget overlay widget-get :field-overlay overlayp overlay-buffer marker-buffer])(#$ . 34799) nil 3 (#$ . 34705)]) #@45 Return the start of WIDGET's editing field. (defalias 'widget-field-start #[(widget) #@119 ("\302\303\"\304 !\2030\305 !\2020 @)\207" . [widget overlay widget-get :field-overlay overlayp overlay-start])(#$ . 35077) nil 3 (#$ . 34985)]) #@43 Return the end of WIDGET's editing field. (defalias 'widget-field-end #[(widget) #@318 ("\303\304\"\305 !\203>0\306 !\205@0r\307!q\210\214~\210\310\311 !\312\"*\313=\20480\n\20410\303\314\"\20480\311 !S\202@0\311 !\202@0 A)\207" . [widget overlay widget-field-add-space widget-get :field-overlay overlayp overlay-buffer widget-field-buffer get-char-property overlay-end field boundary :size])(#$ . 35322) nil 3 (#$ . 35234)]) #@99 Return the field at POS. Unlike (get-char-property POS 'field), this works with empty fields too. (defalias 'widget-field-find #[(pos) #@215 ("\305\211 \203-0 @ A\306\n!\fX\2030\f\307\n!X\2030 \203(0\310\311!\210\n\2020 +\207" . [widget-field-list found field fields pos nil widget-field-start widget-field-end error "Overlapping fields"])(#$ . 35820) nil 3 (#$ . 35678)]) (defalias 'widget-before-change #[(from to) #@463 ("?\205=0\306 !\306\n!\211 =\204!0\307\310\311\312\313$\210\314\315\316\"\202<0\f\20430\307\310\311\312\313$\210\314\315\317\"\202<0 \205<0\320\f\321\f#*\207" . [inhibit-read-only from to to-field from-field widget-field-use-before-change widget-field-find add-hook post-command-hook widget-add-change nil t signal text-read-only ("Change should be restricted to a single field") ("Attempt to change text outside editable field") widget-apply :notify])(#$ . 36118) nil 6]) (defalias 'widget-add-change #[nil #@232 ("\300\301\302\303#\210\304\305\306\307\303$\210\304\310\311\307\303$\207" . [remove-hook post-command-hook widget-add-change t add-hook before-change-functions widget-before-change nil after-change-functions widget-after-change])(#$ . 36642) nil 5]) #@40 Adjust field size and text properties. (defalias 'widget-after-change #[(from to old) #@525 ("\306!\306 !\211\205\2130 \n=\2040\307\310!\210\311 \312\"\211\203\2010\313 !\314 ! Z\fW\203C0\212 b\210\315\316\f\\ Z\"\210)\202\2000 Z\fV\203\2000`\f\\W\204[0` V\203d0\f\\\202g0`\212 b\210h\316=\2030`V\2030\317\320!\210\202k0)*\321 !\210)\322 \323 #*\207" . [from to other field size end widget-field-find error "Change in different fields" widget-get :size widget-field-start widget-field-end insert-char 32 delete-backward-char 1 widget-specify-secret widget-apply :notify begin])(#$ . 36992) nil 5 (#$ . 36899)]) #@102 Tell :parent of WIDGET to handle the :action. Optional EVENT is the event that triggered the action. (defalias 'widget-parent-action #[(widget &optional event) #@88 ("\302\303\304\"\305 #\207" . [widget event widget-apply widget-get :parent :action])(#$ . 37722) nil 4 (#$ . 37556)]) #@46 Delete all :children and :buttons in WIDGET. (defalias 'widget-children-value-delete #[(widget) #@167 ("\301\302\303\304\"\"\210\305\304\306#\210\301\302\303\307\"\"\210\305\307\306#\207" . [widget mapc widget-delete widget-get :children widget-put nil :buttons])(#$ . 37951) nil 5 (#$ . 37848)]) #@34 All the :children must be valid. (defalias 'widget-children-validate #[(widget) #@158 ("\304\305\"\306\211 \203_0 \204_0 @ A\307\n\310\"\202 0 +\207" . [widget found child children widget-get :children nil widget-apply :validate])(#$ . 38243) nil 3 (#$ . 38156)]) #@59 Get the value of the first member of :children in WIDGET. (defalias 'widget-child-value-get #[(widget) #@72 ("\301\302\303\"@!\207" . [widget widget-value widget-get :children])(#$ . 38548) nil 4 (#$ . 38439)]) #@66 Get the inline value of the first member of :children in WIDGET. (defalias 'widget-child-value-inline #[(widget) #@91 ("\301\302\303\"@\304\"\207" . [widget widget-apply widget-get :children :value-inline])(#$ . 38777) nil 4 (#$ . 38658)]) #@67 The result of validating the first member of :children in WIDGET. (defalias 'widget-child-validate #[(widget) #@87 ("\301\302\303\"@\304\"\207" . [widget widget-apply widget-get :children :validate])(#$ . 39022) nil 4 (#$ . 38906)]) #@200 Convert and instantiate the value of the :type attribute of WIDGET. Store the newly created widget in the :children attribute. The value of the :type attribute should be an unconverted widget type. (defalias 'widget-type-value-create #[(widget) #@168 ("\303\304\"\303\305\"\306\307\310\311 !\n#C#*\207" . [widget type value widget-get :value :type widget-put :children widget-create-child-value widget-convert])(#$ . 39401) nil 7 (#$ . 39148)]) #@127 Get default value from the :type attribute of WIDGET. The value of the :type attribute should be an unconverted widget type. (defalias 'widget-type-default-get #[(widget) #@93 ("\301\302\303\304\"!!\207" . [widget widget-default-get widget-convert widget-get :type])(#$ . 39786) nil 5 (#$ . 39608)]) #@125 Non-nil if the :type value of WIDGET matches VALUE. The value of the :type attribute should be an unconverted widget type. (defalias 'widget-type-match #[(widget value) #@105 ("\302\303\304\305\"!\306 #\207" . [widget value widget-apply widget-convert widget-get :type :match])(#$ . 40095) nil 5 (#$ . 39918)]) #@39 Copy :args as widget types in WIDGET. (defalias 'widget-types-copy #[(widget) #@104 ("\301\302\303\304\305\302\"\"#\210\207" . [widget widget-put :args mapcar widget-copy widget-get])(#$ . 40323) nil 8 (#$ . 40238)]) #@42 Convert :args as widget types in WIDGET. (defalias 'widget-types-convert-widget #[(widget) #@107 ("\301\302\303\304\305\302\"\"#\210\207" . [widget widget-put :args mapcar widget-convert widget-get])(#$ . 40563) nil 8 (#$ . 40465)]) (put 'widget-types-convert-widget 'byte-optimizer 'byte-compile-inline-expand) #@41 Initialize :value from :args in WIDGET. (defalias 'widget-value-convert-widget #[(widget) #@124 ("\302\303\"\211\2030\304\305 @#\210\304\303\306#\210)\207" . [widget args widget-get :args widget-put :value nil])(#$ . 40884) nil 5 (#$ . 40787)]) #@39 Return the :value property of WIDGET. (defalias 'widget-value-value-get #[(widget) #@50 ("\301\302\"\207" . [widget widget-get :value])(#$ . 41135) nil 3 (#$ . 41046)]) (byte-code "\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\302\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\344\352\353\354\355\356\357\360\344\361\362\363\364\365\366&9\207" [define-widget default nil "Basic widget other widgets are derived from." :value-to-internal #[(widget value) "\207" [value] 1] :value-to-external #[(widget value) "\207" [value] 1] :button-prefix widget-button-prefix :button-suffix widget-button-suffix :complete widget-default-complete :create widget-default-create :indent :offset 0 :format-handler widget-default-format-handler :button-face-get widget-default-button-face-get :mouse-face-get widget-default-mouse-face-get :sample-face-get widget-default-sample-face-get :delete widget-default-delete :copy identity :value-set widget-default-value-set :value-inline widget-default-value-inline :value-delete ignore :default-get widget-default-default-get :menu-tag-get widget-default-menu-tag-get :validate :active widget-default-active :activate widget-specify-active :deactivate widget-default-deactivate :mouse-down-action :action widget-default-action :notify widget-default-notify :prompt-value widget-default-prompt-value] 58) #@130 Call the value of the :complete-function property of WIDGET. If that does not exists, call the value of `widget-complete-field'. (defalias 'widget-default-complete #[(widget) #@116 ("\302\303\304\"\206 0 !\207" . [widget widget-complete-field call-interactively widget-get :complete-function])(#$ . 42646) nil 4 (#$ . 42464)]) #@47 Create WIDGET at point in the current buffer. (defalias 'widget-default-create #[(widget) #@1576 ("\214\306\211``}\210`\307\211\211\211\211\211\2113456\3107\311\"c\2106b\210\312\313\307\306#\203@\314\224f8\315\316!\2108\317=\203F0\317c\210\202<8\320=\203Z0`5\3217\322\"c\210\202<8\323=\203n0\3217\324\"c\210`4\202<8\325=\203{0`3\202<8\326=\203\2070`\202<8\327=\203\2450\3107\330\"\203<\331c\210\332\333\3107\330\"\"\210\202<8\334=\203\3470\3107\335\"\3107\336\"9\211:\203\3160\33779\206\3070\340:#\210\202\34309\203\33209c\210\202\3430\341\3107\342\"p\"\210*\202<8\343=\203\3107\344\"\211;\203`;c\210h\331=\203\f\315\314!\210\202\3770\331c\210`)\202<8\345=\20345\203/4\204/\3467\347\"\210\202<`\202<\3467\3508#\210)\202(05\203S4\203S\351754#\2103\203d \203d\35273 #\210\f\203s \203s\3537\f #\210\n\203\200\nb\210\3467\347\"\210.\354 \355 <6\3566\306\"\210\356<\307\"\210\3577\3606#\210\3577\361<#\210*db\210+\362 \207" . [inhibit-modification-hooks inhibit-read-only value-pos doc-end doc-begin sample-end t nil widget-get :format re-search-forward "%\\(.\\)" 1 delete-backward-char 2 37 91 widget-get-indirect :button-prefix 93 :button-suffix 123 125 110 :indent 10 insert-char 32 116 :tag-glyph :tag widget-image-insert "image" princ :value 100 :doc 118 widget-apply :value-create :format-handler widget-specify-button widget-specify-sample widget-specify-doc point-min-marker point-max-marker set-marker-insertion-type widget-put :from :to widget-clear-undo sample-begin button-end button-begin from widget escape tag image doc to])(#$ . 42898) nil 9 (#$ . 42800)]) (defalias 'widget-default-format-handler #[(widget escape) #@750 ("\306\307\"\n\310=\203\2340\306\311\"\306\312\"\20620\313 !\203&0 \306\314\"!\20220 9\20520\315\306\314\" \"\211;\205@0\fG\316V\205@0\f\306\317\" \203\2300h\320=\203`0\306\321\"\203`0\322\323\306\321\"\"\210 \324H\325=\203m0 \316\326O\327\330 \"\203z0 \324\211\224O\331\332\321\247\203\2110\202\2230\204\2220\326\202\2230\324 % B,\202\2410\333\334\n\"\210\335\307 #)\207" . [widget buttons escape doc-property doc-try doc-text widget-get :buttons 104 :documentation-property :doc functionp :value documentation-property 1 :documentation-indent 10 :indent insert-char 32 0 42 nil string-match "\n+\\'" widget-create-child-and-convert documentation-string error "Unknown escape `%c'" widget-put doc-indent])(#$ . 44572) nil 7]) (defalias 'widget-default-button-face-get #[(widget) #@171 ("\303\304\"\2060\303\305\"\211\2030\306 \307\"\2020\n)\207" . [widget parent widget-button-face widget-get :button-face :parent widget-apply :button-face-get])(#$ . 45401) nil 4]) (defalias 'widget-default-mouse-face-get #[(widget) #@168 ("\303\304\"\2060\303\305\"\211\2030\306 \307\"\2020\n)\207" . [widget parent widget-mouse-face widget-get :mouse-face :parent widget-apply :mouse-face-get])(#$ . 45650) nil 4]) (defalias 'widget-default-sample-face-get #[(widget) #@56 ("\301\302\"\207" . [widget widget-get :sample-face])(#$ . 45896) nil 3]) #@32 Remove widget from the buffer. (defalias 'widget-default-delete #[(widget) #@554 ("\306\307\"\306\310\"\306\311\"\306\312\"\306\313\"\306\314\"\315\211\316\317\"\210\320!\210\20380\321!\210 \203@0\321 !\210\f\203H0\321\f!\210 \203P0\321 !\210W\203^0|\210\322\211\223\210\322\211\223\210.\323 \207" . [widget inhibit-read-only inhibit-modification-hooks doc-overlay sample-overlay button-overlay widget-get :from :to :inactive :button-overlay :sample-overlay :doc-overlay t widget-apply :value-delete widget-children-value-delete delete-overlay nil widget-clear-undo inactive-overlay to from])(#$ . 46059) nil 8 (#$ . 45977)]) #@33 Recreate widget with new value. (defalias 'widget-default-value-set #[(widget value) #@361 ("`\306\307 \310\"!\306\307 \311\"!\nX\205.0 X\205.0 SY\203+0 Z\312Z\202.0\nZ\212\307 \310\"b\210\313 \314\"\210\315 \316 #\210\313 \317\"\210)\f\205g0\f\320W\203]0\307 \311\"\f\\\312\\b\202g0\n\f\\\307 \311\"S^b,\207" . [old-pos widget from to offset value copy-marker widget-get :from :to 1 widget-apply :delete widget-put :value :create 0])(#$ . 46743) nil 4 (#$ . 46651)]) #@43 Wrap value in a list unless it is inline. (defalias 'widget-default-value-inline #[(widget) #@88 ("\301\302\"\203 0\303!\207\303!C\207" . [widget widget-get :inline widget-value])(#$ . 47240) nil 3 (#$ . 47142)]) #@15 Get `:value'. (defalias 'widget-default-default-get #[(widget) #@50 ("\301\302\"\207" . [widget widget-get :value])(#$ . 47435) nil 3 (#$ . 47366)]) #@29 Use tag or value for menus. (defalias 'widget-default-menu-tag-get #[(widget) #@129 ("\301\302\"\2060\301\303\"\2060\304\301\305\"!\207" . [widget widget-get :menu-tag :tag widget-princ-to-string :value])(#$ . 47608) nil 4 (#$ . 47523)]) #@52 Return t iff this widget active (user modifiable). (defalias 'widget-default-active #[(widget) #@166 ("\302\303\"\2060\302\304\"?\2050\302\305\"\211?\2060\306 \307\")\207" . [widget parent widget-get :always-active :inactive :parent widget-apply :active])(#$ . 47877) nil 4 (#$ . 47775)]) #@46 Make WIDGET inactive for user modifications. (defalias 'widget-default-deactivate #[(widget) #@94 ("\301\302\303\"\302\304\"#\207" . [widget widget-specify-inactive widget-get :from :to])(#$ . 48180) nil 6 (#$ . 48081)]) #@42 Notify the parent when a widget changes. (defalias 'widget-default-action #[(widget &optional event) #@111 ("\303\304\"\211\2050\305 \306\n$)\207" . [widget parent event widget-get :parent widget-apply :notify])(#$ . 48420) nil 6 (#$ . 48312)]) #@30 Pass notification to parent. (defalias 'widget-default-notify #[(widget child &optional event) #@57 ("\302 \"\207" . [widget event widget-default-action])(#$ . 48670) nil 3 (#$ . 48569)]) #@55 Read an arbitrary value. Stolen from `set-variable'. (defalias 'widget-default-prompt-value #[(widget prompt value unbound) #@43 ("\301!\207" . [prompt eval-minibuffer])(#$ . 48896) nil 2 (#$ . 48765)]) (define-widget 'item 'default "Constant items for inclusion in other widgets." :convert-widget 'widget-value-convert-widget :value-create 'widget-item-value-create :value-delete 'ignore :value-get 'widget-value-value-get :match 'widget-item-match :match-inline 'widget-item-match-inline :action 'widget-item-action :format "%t\n") #@49 Insert the printed representation of the value. (defalias 'widget-item-value-create #[(widget) #@63 ("\301\302\303\"p\"\207" . [widget princ widget-get :value])(#$ . 49409) nil 4 (#$ . 49308)]) (defalias 'widget-item-match #[(widget value) #@61 ("\302\303\" \232\207" . [widget value widget-get :value])(#$ . 49556) nil 3]) (defalias 'widget-item-match-inline #[(widget values) #@155 ("\304\305\"\211<\205'0 G\nGX\205'0\306\n\307 G#\211 \232\205&0 \306\n G\"B))\207" . [widget value values head widget-get :value widget-sublist 0])(#$ . 49697) nil 5]) #@101 Return the sublist of LIST from START to END. If END is omitted, it defaults to the length of LIST. (defalias 'widget-sublist #[(list start &optional end) #@137 ("\303V\203\n0 \233\n\203%0\nX?\205(0\304 !\nZ\305Z \233\306\241\210 \207\304 !\207" . [start list end 0 copy-sequence 1 nil])(#$ . 50040) nil 2 (#$ . 49878)]) (defalias 'widget-item-action #[(widget &optional event) #@60 ("\302\303 $\207" . [widget event widget-apply :notify])(#$ . 50272) nil 5]) #@36 String used as prefix for buttons. (custom-declare-variable 'widget-push-button-prefix '"[" '(#$ . 50357) :type 'string :group 'widget-button) #@36 String used as suffix for buttons. (custom-declare-variable 'widget-push-button-suffix '"]" '(#$ . 50506) :type 'string :group 'widget-button) (define-widget 'push-button 'item "A pushable button." :button-prefix #1="" :button-suffix #1# :value-create 'widget-push-button-value-create :format "%[%v%]") #@53 Insert text representing the `on' and `off' states. (defalias 'widget-push-button-value-create #[(widget) #@223 ("\306\307\"\206 0\306\310\"\306\311\" \fQ\n\203\"0\312 \n#\202$0 c+\207" . [widget tag tag-glyph widget-push-button-prefix widget-push-button-suffix text widget-get :tag :value :tag-glyph widget-image-insert])(#$ . 50928) nil 4 (#$ . 50815)]) #@34 String used as prefix for links. (custom-declare-variable 'widget-link-prefix '"[" '(#$ . 51189) :type 'string :group 'widget-button) #@34 String used as suffix for links. (custom-declare-variable 'widget-link-suffix '"]" '(#$ . 51329) :type 'string :group 'widget-button) (byte-code "\300\301\302\303\304\305\306\307\310\311\312\313\314\315& \210\300\316\301\317\320\321%\207" [define-widget link item "An embedded link." :button-prefix widget-link-prefix :button-suffix widget-link-suffix :follow-link " " :help-echo "Follow the link." :format "%[%t%]" info-link "A link to an info file." :action widget-info-link-action] 14) #@41 Open the info node specified by WIDGET. (defalias 'widget-info-link-action #[(widget &optional event) #@50 ("\301\302!!\207" . [widget info widget-value])(#$ . 51932) nil 3 (#$ . 51824)]) (define-widget 'url-link 'link "A link to an www page." :action 'widget-url-link-action) #@35 Open the URL specified by WIDGET. (defalias 'widget-url-link-action #[(widget &optional event) #@56 ("\301\302!!\207" . [widget browse-url widget-value])(#$ . 52210) nil 3 (#$ . 52109)]) (define-widget 'function-link 'link "A link to an Emacs function." :action 'widget-function-link-action) #@40 Show the function specified by WIDGET. (defalias 'widget-function-link-action #[(widget &optional event) #@63 ("\301\302!!\207" . [widget describe-function widget-value])(#$ . 52520) nil 3 (#$ . 52409)]) (define-widget 'variable-link 'link "A link to an Emacs variable." :action 'widget-variable-link-action) #@40 Show the variable specified by WIDGET. (defalias 'widget-variable-link-action #[(widget &optional event) #@63 ("\301\302!!\207" . [widget describe-variable widget-value])(#$ . 52837) nil 3 (#$ . 52726)]) (define-widget 'file-link 'link "A link to a file." :action 'widget-file-link-action) #@36 Find the file specified by WIDGET. (defalias 'widget-file-link-action #[(widget &optional event) #@55 ("\301\302!!\207" . [widget find-file widget-value])(#$ . 53127) nil 3 (#$ . 53024)]) (define-widget 'emacs-library-link 'link "A link to an Emacs Lisp library file." :action 'widget-emacs-library-link-action) #@50 Find the Emacs library file specified by WIDGET. (defalias 'widget-emacs-library-link-action #[(widget &optional event) #@75 ("\301\302\303!!!\207" . [widget find-file locate-library widget-value])(#$ . 53470) nil 4 (#$ . 53344)]) (define-widget 'emacs-commentary-link 'link "A link to Commentary in an Emacs Lisp library file." :action 'widget-emacs-commentary-link-action) #@68 Find the Commentary section of the Emacs file specified by WIDGET. (defalias 'widget-emacs-commentary-link-action #[(widget &optional event) #@63 ("\301\302!!\207" . [widget finder-commentary widget-value])(#$ . 53874) nil 3 (#$ . 53727)]) (define-widget 'editable-field 'default "An editable text field.\nNote: In an `editable-field' widget, the `%v' escape must be preceded\nby some other text in the `:format' string (if specified)." :convert-widget 'widget-value-convert-widget :keymap widget-field-keymap :format "%v" :help-echo "M-TAB: complete field; RET: enter value" :value #1="" :prompt-internal 'widget-field-prompt-internal :prompt-history 'widget-field-history :prompt-value 'widget-field-prompt-value :action 'widget-field-action :validate 'widget-field-validate :valid-regexp #1# :error "Field's value doesn't match allowed forms" :value-create 'widget-field-value-create :value-delete 'widget-field-value-delete :value-get 'widget-field-value-get :match 'widget-field-match) #@36 History of field minibuffer edits. (defvar widget-field-history nil (#$ . 54726)) #@130 Read string for WIDGET prompting with PROMPT. INITIAL is the initial input and HISTORY is a symbol containing the earlier input. (defalias 'widget-field-prompt-internal #[(widget prompt initial history) #@58 ("\303 \n#\207" . [prompt initial history read-string])(#$ . 55024) nil 4 (#$ . 54815)]) #@22 Prompt for a string. (defalias 'widget-field-prompt-value #[(widget prompt value unbound) #@197 ("\304\305\304\306 \n?\2050\304\307 #\310B\311\312\"%#\207" . [widget prompt unbound value widget-apply :value-to-external :prompt-internal :value-to-internal 0 widget-get :prompt-history])(#$ . 55217) nil 11 (#$ . 55120)]) (byte-code "\301B\302\301!\204\303\301\304\"\210\304\207" [current-load-list widget-edit-functions default-boundp set-default nil] 3) #@21 Move to next field. (defalias 'widget-field-action #[(widget &optional event) #@103 ("\301\302!\210\303\304\"\207" . [widget widget-forward 1 run-hook-with-args widget-edit-functions])(#$ . 55676) nil 3 (#$ . 55591)]) #@47 Valid if the content matches `:valid-regexp'. (defalias 'widget-field-validate #[(widget) #@120 ("\301\302\303\"\304\305\"\"?\2050\207" . [widget string-match widget-get :valid-regexp widget-apply :value-get])(#$ . 55914) nil 5 (#$ . 55817)]) #@32 Create an editable text field. (defalias 'widget-field-value-create #[(widget) #@385 ("\306\307\"\306\310\"`\311 \311 B\312\313 #\210 c\210\f\203.0 G\fW\203.0\314\315\f GZ\"\210 >\204:0B A`\316\223\210\317 A\316\"\210\f\204M0\320c\210 @\n\316\223\210\317 @\321\",\207" . [widget overlay from value size widget-field-list widget-get :size :value make-marker widget-put :field-overlay insert-char 32 nil set-marker-insertion-type 10 t widget-field-new])(#$ . 56158) nil 5 (#$ . 56072)]) #@59 Remove the widget from the list of active editing fields. (defalias 'widget-field-value-delete #[(widget) #@170 ("\304 \"\304\n\"\305\306\"\307 !\2050\310 !)\207" . [widget widget-field-list widget-field-new overlay delq widget-get :field-overlay overlayp delete-overlay])(#$ . 56694) nil 3 (#$ . 56581)]) #@39 Return current text in editing field. (defalias 'widget-field-value-get #[(widget) #@452 ("\306!\307!\310!\311\312\"\311\313\"p\211\203{0 \203{0\fq\210 \203C0\314 !\204C0 V\203C0 Sf\315=\203C0 S\202$0\316 \"\n\203r0\317\\ W\203q0\320\\\302\"I\210T\202Q0) q\210)\2020\311\321\".\207" . [widget old secret size buffer to widget-field-start widget-field-end widget-field-buffer widget-get :size :secret zerop 32 buffer-substring-no-properties 0 get-char-property :value from result index])(#$ . 56992) nil 8 (#$ . 56902)]) (defalias 'widget-field-match #[(widget value) #@22 (";\207" . [value])(#$ . 57529) nil 1]) (byte-code "\301\302\303\304\305%\210\301\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350&#\207" [widget-text-keymap define-widget text editable-field "A multiline text area." :keymap menu-choice default "A menu of options." :convert-widget widget-types-convert-widget :copy widget-types-copy :format "%[%t%]: %v" :case-fold t :tag "choice" :void (item :format "invalid (%t)\n") :value-create widget-choice-value-create :value-get widget-child-value-get :value-inline widget-child-value-inline :default-get widget-choice-default-get :mouse-down-action widget-choice-mouse-down-action :action widget-choice-action :error "Make a choice" :validate widget-choice-validate :match widget-choice-match :match-inline widget-choice-match-inline] 36) #@49 Insert the first choice that matches the value. (defalias 'widget-choice-value-create #[(widget) #@474 ("\306\307\"\306\310\"\306\311\"\312\n\203.0\313\314\315\n\f#C#\210\313\316\n#\210\313\311\312#\202s0 \203X0 @ A\317 \320\f#\203.0\313\314\315 \f#C#\210\313\316 #\210\312\211\202.0 \205s0\306\321\"\313\314\322 \307\f$C#\210\313\316 #),\207" . [widget current explicit args value void widget-get :value :args :explicit-choice nil widget-put :children widget-create-child-value :choice widget-apply :match :void widget-create-child-and-convert])(#$ . 58515) nil 9 (#$ . 58411)]) (defalias 'widget-choice-default-get #[(widget) #@74 ("\301\302\303\"@!\207" . [widget widget-default-get widget-get :args])(#$ . 59075) nil 4]) #@162 If non-nil, a binary choice will just toggle between the values. Otherwise, the user will explicitly have to choose between the values when he invoked the menu. (custom-declare-variable 'widget-choice-toggle 'nil '(#$ . 59175) :type 'boolean :group 'widgets) (defalias 'widget-choice-mouse-down-action #[(widget &optional event) #@285 ("\305\306\"\305\307\"\310 \2040\311\202C0\nG\312W\2030\311\202C0\nG V\203)0\311\202C0\nG\312V\20340\313\202C0\f\203B0 \n>\203B0\311\202C0\313*\207" . [widget old args widget-menu-max-size widget-choice-toggle widget-get :args :choice display-popup-menus-p nil 2 t])(#$ . 59511) nil 4]) (defalias 'widget-choice-action #[(widget &optional event) #@854 ("\306\307\"\306\310\"\311\312\"\306\313\"\314\211\211_ _\203?0\311\315\"\204?0\316!!\311_\317!#\"\320_\321\"#\210* G\322U\203K0\314\202\2500 G\323U\203Y0 @\202\2500#\203\2040 G\324U\203\2040_ >\203\2040_ @=\203~0 A@\202\2500 @\202\2500 \203\2360 @ A \311\n\312\"\nB B\202\2040\325\326 \327 !$#\211\203\3110 \203\2670\320\330\n#\210\331\332\n!\"\210\333 \210\311\334$$\210.\335\336\"\207" . [widget choices current this-explicit completion-ignore-case tag widget-get :args :choice widget-apply :menu-tag-get :case-fold nil :validate widget-value :value-to-internal widget-put :value 0 1 2 t widget-choose reverse :explicit-choice widget-value-set widget-default-get widget-setup :notify run-hook-with-args widget-edit-functions old args external internal widget-choice-toggle event])(#$ . 59881) nil 8]) (defalias 'widget-choice-validate #[(widget) #@136 ("\301\302\"\301\303\"=\2030\207\304\301\305\"@\306\"\207" . [widget widget-get :void :choice widget-apply :children :validate])(#$ . 60806) nil 4]) (defalias 'widget-choice-match #[(widget value) #@154 ("\305\306\"\307\211 \203 0 \204 0 @ A\310\n\311\f#\202 0 +\207" . [widget found current args value widget-get :args nil widget-apply :match])(#$ . 61016) nil 4]) (defalias 'widget-choice-match-inline #[(widget values) #@154 ("\305\306\"\307\211 \203_0 \204_0 @ A\310\n\f\"\202 0 +\207" . [widget found current args values widget-get :args nil widget-match-inline])(#$ . 61252) nil 3]) (define-widget 'toggle 'item "Toggle between two states." :format "%[%v%]\n" :value-create 'widget-toggle-value-create :action 'widget-toggle-action :match #[(widget value) "\300\207" [t] 1] :on "on" :off "off") #@53 Insert text representing the `on' and `off' states. (defalias 'widget-toggle-value-create #[(widget) #@334 ("\302!\20300\303\304\"\305 \203&0 <\203&0 @\301=\204&0\306\304\307 !\211#\210\310\303\311\" #)\207\303\312\"\305 \203P0 <\203P0 @\301=\204P0\306\312\307 !\211#\210\310\303\313\" #)\207" . [widget image widget-value widget-get :on-glyph display-graphic-p widget-put eval widget-image-insert :on :off-glyph :off])(#$ . 61751) nil 5 (#$ . 61643)]) (defalias 'widget-toggle-action #[(widget &optional event) #@164 ("\302\303!?\"\210\304\305 $\210\306\307\"\207" . [widget event widget-value-set widget-value widget-apply :notify run-hook-with-args widget-edit-functions])(#$ . 62183) nil 5]) (define-widget 'checkbox 'toggle "A checkbox toggle." :button-suffix #1="" :button-prefix #1# :format "%[%v%]" :on "[X]" :on-glyph '(create-image "\300\300ac7>" 'xbm t :width 8 :height 8 :background "grey75" :foreground "black" :relief -2 :ascent 'center) :off "[ ]" :off-glyph '(create-image (make-string 8 0) 'xbm t :width 8 :height 8 :background "grey75" :foreground "black" :relief -2 :ascent 'center) :help-echo "Toggle this item." :action 'widget-checkbox-action) #@66 Toggle checkbox, notify parent, and set active state of sibling. (defalias 'widget-checkbox-action #[(widget &optional event) #@230 ("\303 \"\210\304!\211\205\"0\305!\2030\306\n\307\"\210\202 0\306\n\310\"\210\311 )\207" . [widget event sibling widget-toggle-action widget-get-sibling widget-value widget-apply :activate :deactivate widget-clear-undo])(#$ . 62977) nil 4 (#$ . 62844)]) (define-widget 'checklist 'default "A multiple choice widget." :convert-widget 'widget-types-convert-widget :copy 'widget-types-copy :format "%v" :offset 4 :entry-format "%b %v" :greedy nil :value-create 'widget-checklist-value-create :value-get 'widget-checklist-value-get :validate 'widget-checklist-validate :match 'widget-checklist-match :match-inline 'widget-checklist-match-inline) (defalias 'widget-checklist-value-create #[(widget) #@231 ("\303\304\305\"\"\304\306\" \203\"0\307 @ @\n\236#\210 A\211\2040\310\311\304\311\"\237#*\207" . [widget args alist widget-checklist-match-find widget-get :value :args widget-checklist-add-item widget-put :children])(#$ . 63686) nil 7]) #@112 Create checklist item in WIDGET of type TYPE. If the item is checked, CHOSEN is a cons whose cdr is the value. (defalias 'widget-checklist-add-item #[(widget type chosen) #@1051 ("h\306=\2030\307\310\"\2030\311\312\307\310\"\"\210\214\313\211``}\210\307\314\"\307\315\"\307 \316\"\20630\307\317\"'`(\320\211)*\307\321\"c\210(b\210\322\323\320\313#\203\3050\324\224f+\325\326!\210+\327=\203f0\327c\210\202\3010+\330=\2030\331\332\333\334,??'&*\202\3010+\335=\203\2730,\204\2350\336 \")\337)\340\"\210))\202\2660\307 \341\"\203\2560\342 ,A#\202\2660\342 ,A@#)\202\3010\343\344+\"\210)\202H0*\203\3270)\203\3270\345)\346*#\210*\203\3450\345\315*\fB#\210)\205\3620\345\314) B#.db\210+\207" . [widget inhibit-modification-hooks inhibit-read-only children buttons type 10 widget-get :indent insert-char 32 t :children :buttons :sibling-args :button-args nil :entry-format re-search-forward "%\\([bv%]\\)" 1 delete-backward-char 2 37 98 apply widget-create-child-and-convert checkbox :value 118 widget-create-child widget-apply :deactivate :inline widget-create-child-value error "Unknown escape `%c'" widget-put :button button-args from child button escape chosen])(#$ . 64122) nil 8 (#$ . 63943)]) (defalias 'widget-checklist-match #[(widget values) #@77 ("<\205 0\302 \"A?\207" . [values widget widget-checklist-match-inline])(#$ . 65263) nil 3]) (defalias 'widget-checklist-match-inline #[(widget values) #@334 ("\306\307\"\310\306\311\"!\312\211 \203V0\313 \"\211\203:0\314 \"\315\n@\"A\316 \")\202R0\f\203K0\315 @C\" A\202R0\315 \"\312)\2020\n ,B\207" . [widget rest found args greedy values widget-get :greedy copy-sequence :args nil widget-checklist-match-up widget-match-inline append delq answer vals])(#$ . 65425) nil 6]) #@85 Find the vals which match a type in the checklist. Return an alist of (TYPE MATCH). (defalias 'widget-checklist-match-find #[(widget vals) #@291 ("\306\307\"\310\306\311\"!\312\f\203F0\313\n\f\"\211\20360\314 \f\" @B BA\315 \n\")\202B0 \203@0\fA\202B0\312)\2020 +\207" . [widget found args greedy vals answer widget-get :greedy copy-sequence :args nil widget-checklist-match-up widget-match-inline delq match])(#$ . 65930) nil 6 (#$ . 65784)]) #@52 Return the first type from ARGS that matches VALS. (defalias 'widget-checklist-match-up #[(args vals) #@124 ("\304\211\n\2030\2040\n@\nA\305 \"\2020\205_0 *\207" . [found current args vals nil widget-match-inline])(#$ . 66368) nil 3 (#$ . 66259)]) (defalias 'widget-checklist-value-get #[(widget) #@212 ("\304\305\"\306\211 \203'0 @ A\307\304\n\310\"!\203 0\311 \312\n\313\"\"\202 0 +\207" . [widget result child children widget-get :children nil widget-value :button append widget-apply :value-inline])(#$ . 66580) nil 5]) (defalias 'widget-checklist-validate #[(widget) #@217 ("\305\306\"\307\211\211\f\203,0 \204,0\f@\fA\305 \310\"\311\n!\205(0\312 \313\"\202 0 ,\207" . [widget found button child children widget-get :children nil :button widget-value widget-apply :validate])(#$ . 66866) nil 4]) (byte-code "\300\301\302\303\304\305%\210\300\306\307\310\311\312\313\314&\210\300\315\316\317\320\321\313\322\323\324\325\324\326\327\330\331\332\333\334\335&\207" [define-widget option checklist "An widget with an optional item." :inline t choice-item item "Button items that delegate action events to their parents." :action widget-parent-action :format "%[%t%] \n" radio-button toggle "A radio button for use in the `radio' widget." :notify widget-radio-button-notify "%[%v%]" :button-suffix "" :button-prefix :on "(*)" :on-glyph "radio1" :off "( )" :off-glyph "radio0"] 20) (defalias 'widget-radio-button-notify #[(widget child &optional event) #@89 ("\302\303\304\"\305 $\207" . [widget event widget-apply widget-get :parent :action])(#$ . 67760) nil 5]) (define-widget 'radio-button-choice 'default "Select one of multiple options." :convert-widget 'widget-types-convert-widget :copy 'widget-types-copy :offset 4 :format "%v" :entry-format "%b %v" :value-create 'widget-radio-value-create :value-get 'widget-radio-value-get :value-inline 'widget-radio-value-inline :value-set 'widget-radio-value-set :error "You must push one of the buttons" :validate 'widget-radio-validate :match 'widget-choice-match :match-inline 'widget-choice-match-inline :action 'widget-radio-action) (defalias 'widget-radio-value-create #[(widget) #@127 ("\303\304\"\305\n\2050\n@\nA\306 \"\210\2020*\207" . [widget arg args widget-get :args nil widget-radio-add-item])(#$ . 68444) nil 3]) #@66 Add to radio widget WIDGET a new radio button item of type TYPE. (defalias 'widget-radio-add-item #[(widget type) #@1100 ("h\306=\2030\307\310\"\2030\311\312\307\310\"\"\210\214\313\211``}\210\307\314\"\307\315\"\307\316\"\307(\317\"\20690\307\320\")`*\307\321\"?\205L0\322(\323 #+\324\211,-\307\325\"c\210*b\210\326\327\324\313#\203\3110\330\224f.\331\332!\210.\333=\203|0\333c\210\202\3050.\334=\203\2250\335\336\337\314+??)&-\202\3050.\340=\203\2770+\203\2520\341( #\202\2570\342(\",+\204\3050\322,\343\"\210\202\3050\344\345.\"\210)\202^0+\203\3250\346\321(#\210-\203\3540\346,\347-#\210\346\316 -C\244#\210,\203\3730\346\315\f,C\244#\210,.db\210+\207" . [widget inhibit-modification-hooks inhibit-read-only value children buttons 10 widget-get :indent insert-char 32 t :value :children :buttons :sibling-args :button-args :choice widget-apply :match nil :entry-format re-search-forward "%\\([bv%]\\)" 1 delete-backward-char 2 37 98 apply widget-create-child-and-convert radio-button 118 widget-create-child-value widget-create-child :deactivate error "Unknown escape `%c'" widget-put :button type button-args from chosen child button escape])(#$ . 68718) nil 8 (#$ . 68596)]) (defalias 'widget-radio-value-get #[(widget) #@86 ("\302!\211\205 0\303 !)\207" . [widget chosen widget-radio-chosen widget-value])(#$ . 69901) nil 3]) #@57 Return the widget representing the chosen radio button. (defalias 'widget-radio-chosen #[(widget) #@187 ("\304\305\"\306\211 \203%0 @ A\307\304\n\310\"\311\"\203 0\n\306\211\204 0 +\207" . [widget found current children widget-get :children nil widget-apply :button :value-get])(#$ . 70117) nil 5 (#$ . 70012)]) (defalias 'widget-radio-value-inline #[(widget) #@211 ("\304\305\"\306\211 \203(0 @ A\307\304\n\310\"\311\"\203 0\307\n\312\"\306\211\204 0 +\207" . [widget found current children widget-get :children nil widget-apply :button :value-get :value-inline])(#$ . 70391) nil 5]) (defalias 'widget-radio-value-set #[(widget value) #@323 ("\306\307\"\310\211 \205L0 @ A\306\n\311\" ?\205\"0\312\n\313 #\314\f\"\210\203<0\314\n \"\210\312\n\315\"\210\202A0\312\n\316\"\210 \206G0*\202 0+\207" . [widget found current children button value widget-get :children nil :button widget-apply :match widget-value-set :activate :deactivate match])(#$ . 70679) nil 4]) (defalias 'widget-radio-validate #[(widget) #@231 ("\305\306\"\307\211\211\f\203&0\n\204&0\f@\fA\305 \310\"\311 \312\"\202 0\n\20310\311 \313\"\20220,\207" . [widget button found current children widget-get :children nil :button widget-apply :value-get :validate])(#$ . 71072) nil 4]) (defalias 'widget-radio-action #[(widget child event) #@363 ("\306\307\"\306\310\"\311\f\n>\203H0 \203H0 @ A\306 \312\"\f =\20340\313 \314\"\210\315 \316\"\210\202D0\317 !\203D0\313 \311\"\210\315 \320\"\210)\2020+\315\321\f$\207" . [widget current buttons children child button widget-get :children :buttons nil :button widget-value-set t widget-apply :activate widget-value :deactivate :notify event])(#$ . 71383) nil 5]) (define-widget 'insert-button 'push-button "An insert button for the `editable-list' widget." :tag "INS" :help-echo "Insert a new item into the list at this position." :action 'widget-insert-button-action) (defalias 'widget-insert-button-action #[(widget &optional event) #@107 ("\301\302\303\"\304\302\305\"#\207" . [widget widget-apply widget-get :parent :insert-before :widget])(#$ . 72044) nil 6]) (define-widget 'delete-button 'push-button "A delete button for the `editable-list' widget." :tag "DEL" :help-echo "Delete this item from the list." :action 'widget-delete-button-action) (defalias 'widget-delete-button-action #[(widget &optional event) #@103 ("\301\302\303\"\304\302\305\"#\207" . [widget widget-apply widget-get :parent :delete-at :widget])(#$ . 72430) nil 6]) (define-widget 'editable-list 'default "A variable list of widgets of the same type." :convert-widget 'widget-types-convert-widget :copy 'widget-types-copy :offset 12 :format "%v%i\n" :format-handler 'widget-editable-list-format-handler :entry-format "%i %d %v" :value-create 'widget-editable-list-value-create :value-get 'widget-editable-list-value-get :validate 'widget-children-validate :match 'widget-editable-list-match :match-inline 'widget-editable-list-match-inline :insert-before 'widget-editable-list-insert-before :delete-at 'widget-editable-list-delete-at) (defalias 'widget-editable-list-format-handler #[(widget escape) #@262 ("\302=\203_0\303 \304\"\2030\305\306\303 \304\"\"\210\307\310 \311\303 \312\"$\207\313 \"\207" . [escape widget 105 widget-get :indent insert-char 32 apply widget-create-child-and-convert insert-button :append-button-args widget-default-format-handler])(#$ . 73193) nil 7]) (defalias 'widget-editable-list-value-create #[(widget) #@400 ("\305\306\"\305\307\"@\310\311\312\313`!#\210\314\305\312\"\315\"\210 \203L0\316\n \"\211\203F0\317\305\n\320\"\20380\f@\202;0\f@@\315# B\fA\202H0\310)\2020\311\321 \237#+\207" . [widget value type children answer widget-get :value :args nil widget-put :value-pos copy-marker set-marker-insertion-type t widget-match-inline widget-editable-list-entry-create :inline :children])(#$ . 73537) nil 6]) (defalias 'widget-editable-list-value-get #[(widget) #@159 ("\301\302\303\304\305\306\"\"\"\207" . [widget apply append mapcar #[(child) "\301\302\"\207" [child widget-apply :value-inline] 3] widget-get :children])(#$ . 74016) nil 7]) (defalias 'widget-editable-list-match #[(widget value) #@80 ("<\205 0\302 \"A?\207" . [value widget widget-editable-list-match-inline])(#$ . 74255) nil 3]) (defalias 'widget-editable-list-match-inline #[(widget value) #@199 ("\306\307\"@\310\311\f\203-0\n\203-0\312 \f\"\211\203'0\313 @\" A\202)0\311)\202\n0 \f+B\207" . [widget found ok type value answer widget-get :args t nil widget-match-inline append])(#$ . 74423) nil 4]) (defalias 'widget-editable-list-insert-before #[(widget before) #@508 ("\212\306\307\"\310\311\211 \2030\306 \312\"b\210\202_0\306\313\"b\210\314\311\211#\306\312\"\306\315\"W\203?0\306\315\"\306\312\"\311\223\210\f@ =\203R0\316\307\fB#\210\202i0\fA@ =\204a0\fA\211\202S0\f\fAB\241\210.\317 \210\320\321#\207" . [widget after-change-functions before-change-functions inhibit-read-only children before widget-get :children t nil :entry-from :value-pos widget-editable-list-entry-create :from widget-put widget-setup widget-apply :notify child])(#$ . 74712) nil 6]) (defalias 'widget-editable-list-delete-at #[(widget child) #@554 ("\212\306\307\310\"!\311\312\311\211 \20370 @ A\307\f\313\"=\2030\314\310\315\f\307\310\"\"#\210\316\f!\210\2020-\307\317\"\307\320\"\312\311\211\316!\210|\210\311\211\223\210\311\211\223\210-\314\321\315\307\321\"\"#\210)\322 \210\323\324#\207" . [widget after-change-functions before-change-functions inhibit-read-only button buttons copy-sequence widget-get :buttons nil t :widget widget-put delq widget-delete :entry-from :entry-to :children widget-setup widget-apply :notify child entry-to entry-from])(#$ . 75305) nil 8]) (defalias 'widget-editable-list-entry-create #[(widget value conv) #@1161 ("\306\307\"@\310\211\211\214\311\211)``}\210\212\306\312\"\203&0\313\314\306\312\"\"\210\306\315\"c\210)\316\317\310\311#\203\2360\320\224f*\321\322!\210*\323=\203K0\323c\210\202\2320*\324=\203_0\325\326\327\306\330\"$\202\2320*\331=\203s0\325\326\332\306\333\"$\202\2320*\334=\203\2240+\203\2110\335\f,#\202\2320\335\f\336\f!#\202\2320\337\340*\"\210)\202-0\306\341\"- \203\2560 -B-\n\203\2700\n-B-\342\341-#\210)\343 \344 ./\345/\311\"\210\345.\310\"\210\342 \346/#\210\342 \347.#\210*db\210+ \203\3610\342 \350 #\210\n\203\3730\342\n\350 #\210 ,\207" . [widget insert delete child type inhibit-modification-hooks widget-get :args nil t :indent insert-char 32 :entry-format re-search-forward "%\\(.\\)" 1 delete-backward-char 2 37 105 apply widget-create-child-and-convert insert-button :insert-button-args 100 delete-button :delete-button-args 118 widget-create-child-value widget-default-get error "Unknown escape `%c'" :buttons widget-put point-min-marker point-max-marker set-marker-insertion-type :entry-from :entry-to :widget inhibit-read-only escape conv value buttons entry-to entry-from])(#$ . 75953) nil 7]) (define-widget 'group 'default "A widget which groups other widgets inside." :convert-widget 'widget-types-convert-widget :copy 'widget-types-copy :format "%v" :value-create 'widget-group-value-create :value-get 'widget-editable-list-value-get :default-get 'widget-group-default-get :validate 'widget-children-validate :match 'widget-group-match :match-inline 'widget-group-match-inline) (defalias 'widget-group-value-create #[(widget) #@422 ("\306\307\"\306\310\"\311\211\211 \203_0 @ A\312 \f\"\211Ah\313=\20370\306\314\"\20370\315\316\306\314\"\"\210\n\204B0\317 \"\202Y0\306 \320\"\203R0\321 \n@#\202Y0\321 \n@@# B\2020\322\323 \237#-\207" . [widget children answer arg value args widget-get :args :value nil widget-match-inline 10 :indent insert-char 32 widget-create-child :inline widget-create-child-value widget-put :children])(#$ . 77576) nil 6]) (defalias 'widget-group-default-get #[(widget) #@85 ("\301\302\303\304\"\"\207" . [widget mapcar widget-default-get widget-get :args])(#$ . 78070) nil 5]) (defalias 'widget-group-match #[(widget values) #@94 ("<\2050\303 \"\211\2050\nA?)\207" . [values widget match widget-group-match-inline])(#$ . 78228) nil 4]) (defalias 'widget-group-match-inline #[(widget vals) #@221 ("\306\307\"\310\211\211\f\20320\f@\fA\311 \"\211\203*0\nA\312 \n@\"\202 0\310\211\211\2040\n\20590 B,\207" . [widget found answer argument args vals widget-get :args nil widget-match-inline append])(#$ . 78401) nil 5]) (define-widget 'visibility 'item "An indicator and manipulator for hidden items." :format "%[%v%]" :button-prefix #1="" :button-suffix #1# :on "Hide" :off "Show" :value-create 'widget-visibility-value-create :action 'widget-toggle-action :match #[(widget value) "\300\207" [t] 1]) (defalias 'widget-visibility-value-create #[(widget) #@312 ("\305\306\"\305\307\"\211\2030 \n\fQ\2020\310 \203$0 \fQ\202&0\310\311!\20350\312\n\313\314$\202;0\312 \315\316$*\207" . [widget off on widget-push-button-prefix widget-push-button-suffix widget-get :on :off "" widget-value widget-image-insert "down" "down-pushed" "right" "right-pushed"])(#$ . 78982) nil 6]) (define-widget 'documentation-link 'link "Link type used in documentation strings." :tab-order -1 :help-echo "Describe this symbol" :action 'widget-documentation-link-action) #@76 Display documentation for WIDGET's value. Ignore optional argument EVENT. (defalias 'widget-documentation-link-action #[(widget &optional event) #@254 ("\303\304\"\305 !\306\n!\203 0\307\n!\203 0\310\311\312 !\313Q!\202/0\306\n!\203,0\314\n!\202/0\315\n!*\207" . [widget string symbol widget-get :value intern fboundp boundp apropos "\\`" regexp-quote "\\'" describe-function describe-variable])(#$ . 79647) nil 4 (#$ . 79494)]) #@55 Add hyperlinks to documentation strings when non-nil. (custom-declare-variable 'widget-documentation-links 't '(#$ . 79939) :type 'boolean :group 'widget-documentation) #@106 Regexp for matching potential links in documentation strings. The first group should be the link itself. (custom-declare-variable 'widget-documentation-link-regexp '"`\\([^\n`' ]+\\)'" '(#$ . 80115) :type 'regexp :group 'widget-documentation) #@216 Predicate used to test if a string is useful as a link. The value should be a function. The function will be called with one argument, a string, and should return non-nil if there should be a link for that string. (custom-declare-variable 'widget-documentation-link-p ''intern-soft '(#$ . 80365) :type 'function :options '(widget-documentation-link-p) :group 'widget-documentation) #@54 Widget type used for links in documentation strings. (custom-declare-variable 'widget-documentation-link-type ''documentation-link '(#$ . 80754) :type 'symbol :group 'widget-documentation) (defalias 'widget-documentation-link-add #[(widget from to) #@762 ("\306 \n#\210 \203]0\f\307\310\"\311\312! \211\n\212 b\210\313\n\314#\203T0\315\316!\316\224\316\225_ _!\203P0\317!\320_%B+\202\"0)\321\310#\210-\307\322\"\211\"\205\2120\323\"!?\205\2120\212\214 \n}\210eb\210\324\325\326\314#\205\2110\327\330\"\"\210\202x0*)\207" . [widget from to widget-documentation-links widget-documentation-link-regexp widget-documentation-face widget-specify-doc widget-get :buttons default-value widget-mouse-face re-search-forward t match-string 1 widget-convert-button :value widget-put :indent zerop search-forward "\n" nil insert-char 32 widget-button-pressed-face widget-button-face buttons regexp end begin name widget-documentation-link-p widget-documentation-link-type indent])(#$ . 81010) nil 7]) (define-widget 'documentation-string 'item "A documentation string." :format "%v" :action 'widget-documentation-string-action :value-create 'widget-documentation-string-value-create) (defalias 'widget-documentation-string-value-create #[(widget) #@694 ("\306!\307\310\"\307\211\311\"\312\"`\313\314\f\"\203p0\f\315\211\224O\f\315\224\316O\316\"\211#\317\261\210\320 `#\210\321\322\323\324\325\326\327\330\331\332\333\334\n& \n\203e0` \203[0\335 !\204[0\336\317 \"\210\"c\210\320 `#\210\337\340 C#\210+\202y0\fc\210\320 `#\210,\341c\207" . [widget start shown indent doc button widget-value widget-get :indent :parent :documentation-shown string-match "\n" 0 nil 32 widget-documentation-link-add widget-create-child-and-convert visibility :help-echo "Show or hide rest of the documentation." :on "Hide Rest" :off "More" :always-active t :action widget-parent-action zerop insert-char widget-put :buttons 10 after before])(#$ . 82044) nil 15]) (defalias 'widget-documentation-string-action #[(widget &rest ignore) #@161 ("\302\303\"\304 \305\302 \305\"?#\210)\306\307!\"\207" . [widget parent widget-get :parent widget-put :documentation-shown widget-value-set widget-value])(#$ . 82835) nil 6]) (define-widget 'const 'item "An immutable sexp." :prompt-value 'widget-const-prompt-value :format "%t\n%d") (defalias 'widget-const-prompt-value #[(widget prompt value unbound) #@40 ("\301!\207" . [widget widget-value])(#$ . 83198) nil 2]) (byte-code "\300\301\302\303\304\305\306\307&\210\300\310\302\311\304\305\306\312&\210\300\313\314\315\316\317\304\320\321\313& \207" [define-widget function-item const "An immutable function name." :format "%v\n%h" :documentation-property #[(symbol) "\300\301\302\217\207" [nil (documentation symbol t) ((error))] 3] variable-item "An immutable variable name." variable-documentation other sexp "Matches any value, but doesn't let the user edit the value.\nThis is useful as last item in a `choice' widget.\nYou should use this widget type with a default value,\nas in (other DEFAULT) or (other :tag \"NAME\" DEFAULT).\nIf the user selects this alternative, that specifies DEFAULT\nas the value." :tag "Other" "%t%n" :value] 10) #@51 History of input to `widget-string-prompt-value'. (defvar widget-string-prompt-value-history nil (#$ . 83995)) (byte-code "\300\301\302\303\304\305\306\307\310\311\312\313& \210\300\314\301\315\316\317\320\321\304\322& \207" [define-widget string editable-field "A string" :tag "String" :format "%{%t%}: %v" :complete-function ispell-complete-word :prompt-history widget-string-prompt-value-history regexp "A regular expression." :match widget-regexp-match :validate widget-regexp-validate "Regexp"] 12) (defalias 'widget-regexp-match #[(widget value) #@125 (";\205 0\301\302\303\217\207" . [value nil (byte-code "\301\302\303\"\210\207" [value t string-match ""] 4) ((error))])(#$ . 84554) nil 3]) #@51 Check that the value of WIDGET is a valid regexp. (defalias 'widget-regexp-validate #[(widget) #@227 ("\300\301\302\217\207" . [data (byte-code "\301\302\303!\304\"\210\207" [widget nil string-match widget-value ""] 4) ((error (byte-code "\302\303\304 !#\210\207" [widget data widget-put :error error-message-string] 5)))])(#$ . 84806) nil 3 (#$ . 84704)]) (define-widget 'file 'string "A file widget.\nIt reads a file name from an editable text field." :complete-function 'widget-file-complete :prompt-value 'widget-file-prompt-value :format "%{%t%}: %v" :tag "File") #@50 Perform completion on file name preceding point. (defalias 'widget-file-complete #[nil #@582 ("`\306 !\211{\307 !\310 !\2060\311\312\f \"\211\313=\206[0\20410\314\315 \"\210\316 \202[0\f\230\204E0\n|\210\317 \"c\202[0\314\320!\210\321\220\322\323\324\f \"\325\"\f\"\221\210\314\326\327\".\207" . [end widget beg pattern name-part directory widget-field-start file-name-nondirectory file-name-directory "/" file-name-completion t message "Can't find completion for \"%s\"" ding expand-file-name "Making completion list..." "*Completions*" display-completion-list sort file-name-all-completions string< "Making completion list...%s" "done" completion])(#$ . 85377) nil 7 (#$ . 85283) nil]) (defalias 'widget-file-prompt-value #[(widget prompt value unbound) #@289 ("\306\203 0\307 !\202*0\310\311 \n#\312\n!\313\n!\314 \315\"\307\316\f %,!\207" . [unbound prompt value widget must-match file abbreviate-file-name read-file-name format "%s (default %s): " file-name-directory file-name-nondirectory widget-get :must-match nil dir prompt2])(#$ . 86070) nil 7]) (define-widget 'directory 'file "A directory widget.\nIt reads a directory name from an editable text field." :tag "Directory") #@51 History of input to `widget-symbol-prompt-value'. (defvar widget-symbol-prompt-value-history nil (#$ . 86512)) (define-widget 'symbol 'editable-field "A Lisp symbol." :value nil :tag "Symbol" :format "%{%t%}: %v" :match #[(widget value) "9\207" [value] 1] :complete-function 'lisp-complete-symbol :prompt-internal 'widget-symbol-prompt-internal :prompt-match 'symbolp :prompt-history 'widget-symbol-prompt-value-history :value-to-internal #[(widget value) "9\203 \301!\207\207" [value symbol-name] 2] :value-to-external #[(widget value) ";\203 \301!\207\207" [value intern] 2]) (defalias 'widget-symbol-prompt-internal #[(widget prompt initial history) #@199 ("\306 \307\n\310\"\311 \f&\211;\2030\312 G!\2040 \202 0\313\314!)\207" . [prompt obarray widget initial history answer completing-read widget-get :prompt-match nil zerop error "No value"])(#$ . 87181) nil 8]) #@53 History of input to `widget-function-prompt-value'. (defvar widget-function-prompt-value-history nil (#$ . 87405)) (define-widget 'function 'restricted-sexp "A Lisp function." :complete-function #[nil "\300\301!\207" [lisp-complete-symbol fboundp] 2 nil nil] :prompt-value 'widget-field-prompt-value :prompt-internal 'widget-symbol-prompt-internal :prompt-match 'fboundp :prompt-history 'widget-function-prompt-value-history :action 'widget-field-action :match-alternatives '(functionp) :validate #[(widget) "\301\302!!?\205\303\304\305\306\302!\"#\210\207" [widget functionp widget-value widget-put :error format "Invalid function: %S"] 7] :value 'ignore :tag "Function") #@53 History of input to `widget-variable-prompt-value'. (defvar widget-variable-prompt-value-history nil (#$ . 88090)) (define-widget 'variable 'symbol "A Lisp variable." :prompt-match 'boundp :prompt-history 'widget-variable-prompt-value-history :complete-function #[nil "\300\301!\207" [lisp-complete-symbol boundp] 2 nil nil] :tag "Variable") #@58 History of input to `widget-coding-system-prompt-value'. (defvar widget-coding-system-prompt-value-history nil (#$ . 88438)) (define-widget 'coding-system 'symbol "A MULE coding-system." :format "%{%t%}: %v" :tag "Coding system" :base-only nil :prompt-history 'widget-coding-system-prompt-value-history :prompt-value 'widget-coding-system-prompt-value :action 'widget-coding-system-action :complete-function #[nil "\300\301!\207" [lisp-complete-symbol coding-system-p] 2 nil nil] :validate #[(widget) "\301\302!!?\205\303\304\305\306\302!\"#\210\207" [widget coding-system-p widget-value widget-put :error format "Invalid coding system: %S"] 7] :value 'undecided :prompt-match 'coding-system-p) #@37 Read coding-system from minibuffer. (defalias 'widget-coding-system-prompt-value #[(widget prompt value unbound) #@281 ("\304\305\"\2030\306\307\310\311 \n#\312\313\314\315!\"\316\211\211 &!\207\317\310\311 \n#\n\"\207" . [widget prompt value coding-system-history widget-get :base-only intern completing-read format "%s (default %s): " mapcar list coding-system-list t nil read-coding-system])(#$ . 89265) nil 8 (#$ . 89145)]) (defalias 'widget-coding-system-action #[(widget &optional event) #@211 ("\303\304\305\"\306!\307$\310 \"\210\304\311\n$\210\312 )\207" . [widget answer event widget-coding-system-prompt-value widget-apply :menu-tag-get widget-value t widget-value-set :notify widget-setup])(#$ . 89651) nil 5]) #@57 History of input to `widget-key-sequence-prompt-value'. (defvar widget-key-sequence-prompt-value-history nil (#$ . 89887)) #@42 Default value for an empty key sequence. (defvar widget-key-sequence-default-value [ignore] (#$ . 90016)) (byte-code "\304B\305\304!\204\306\304\307 \310 \n\"\210\311 \312\313#\210 )\"\210\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342 \343\f\344\345\346\347&\207" [current-load-list map widget-field-keymap widget-key-sequence-default-value widget-key-sequence-map default-boundp set-default make-sparse-keymap set-keymap-parent define-key [(control 113)] widget-key-sequence-read-event define-widget key-sequence restricted-sexp "A key sequence." :prompt-value widget-field-prompt-value :prompt-internal widget-symbol-prompt-internal :prompt-history widget-key-sequence-prompt-value-history :action widget-field-action :match-alternatives (stringp vectorp) :format "%{%t%}: %v" :validate widget-key-sequence-validate :value-to-internal widget-key-sequence-value-to-internal :value-to-external widget-key-sequence-value-to-external :value :keymap :help-echo "C-q: insert KEY, EVENT, or CODE; RET: enter value" :tag "Key sequence"] 30) (defalias 'widget-key-sequence-read-event #[(ev) #@684 ("\306\307!>\205\n0\310 \311 !\2050\312 \313!\"\250\203\\0\314X\203-0\315\f^\314\\W\204?0\316\227X\203\\0\227\317\f^\320\\W\203\\0 B\321\322\323\f\"!\324\250\203\\0\325!\204\\0\326!c\210\327C!\330\n!\203}0\327\n\331HC!\332\322\333\n\211$!\203}0\n\324`Sf\334U\203\2110\335\202\2120\336\336\261\210 \205\2320\327 C!\336\261*\207" . [ev function-key-map tr ev2 read-quoted-char-radix unread-command-events down event-modifiers read-event keymapp lookup-key vector 48 10 97 36 87 read-quoted-char format "Enter code (radix %d)" nil char-valid-p char-to-string key-description arrayp 0 y-or-n-p "Key %s is translated to %s -- use %s? " 32 "" " "])(#$ . 91159) nil 6 nil (list (let ((inhibit-quit t) quit-flag) (read-event "Insert KEY, EVENT, or CODE: ")))]) (defalias 'widget-key-sequence-validate #[(widget) #@159 ("\301!;\206\f0\302\301!!?\2050\303\304\305\306\301!\"#\210\207" . [widget widget-value vectorp widget-put :error format "Invalid key sequence: %S"])(#$ . 92010) nil 7]) (defalias 'widget-key-sequence-value-to-internal #[(widget value) #@151 ("\303\304 #\2030 \n\232\2030\305\207\306 !\207 \207" . [widget value widget-key-sequence-default-value widget-apply :match "" key-description])(#$ . 92261) nil 4]) (defalias 'widget-key-sequence-value-to-external #[(widget value) #@146 (";\2030\302\303\"\2030 \207\304!\207\207" . [value widget-key-sequence-default-value string-match "\\`[[:space:]]*\\'" read-kbd-macro])(#$ . 92504) nil 3]) (define-widget 'sexp 'editable-field "An arbitrary Lisp expression." :tag "Lisp expression" :format "%{%t%}: %v" :value nil :validate 'widget-sexp-validate :match #[(widget value) "\300\207" [t] 1] :value-to-internal 'widget-sexp-value-to-internal :value-to-external #[(widget value) "\301!\207" [value read] 2] :prompt-history 'widget-sexp-prompt-value-history :prompt-value 'widget-sexp-prompt-value) (defalias 'widget-sexp-value-to-internal #[(widget value) #@198 ("9\203 0\302!\2020\303!\304\305 \"\2030 \306\307O\2020\304\305 \"\204,0 G\310V\20320\311 P\20230 )\207" . [value pp prin1-to-string pp-to-string string-match "\n\\'" 0 -1 40 "\n"])(#$ . 93138) nil 3]) (defalias 'widget-sexp-validate #[(widget) #@739 ("\303\304!\305\216rq\210\306 \307\"c\210eb\210\310\311\312\313\217\210\n\205%0\314 \315\n#\210 ,\207" . [#1=#:temp-buffer widget err generate-new-buffer " *temp*" ((byte-code "\301!\203\n0\302!\210\301\207" [#1# buffer-name kill-buffer] 2)) widget-apply :value-get nil data (byte-code "\302\303!\210m\203 0\304\2020\305 \306\307p!#\2040\310 \311\"\302\303!\210m\204/0\204/0\312\313`d{\"\302\207" [err widget skip-syntax-forward "\\s-" "Empty sexp -- use `nil'?" widget-apply :match read widget-get :type-error format "Junk at end of expression: %s"] 5) ((end-of-file (byte-code "\301\302\207" [err "Unbalanced sexp" nil] 1)) (error (byte-code "\302!\302\207" [data err error-message-string] 2))) widget-put :error])(#$ . 93405) nil 4]) #@49 History of input to `widget-sexp-prompt-value'. (defvar widget-sexp-prompt-value-history nil (#$ . 94169)) (defalias 'widget-sexp-prompt-value #[(widget prompt value unbound) #@261 ("\306 ?\205\f0\307\n!\310B\311 \312\"#\313\f!\211A\fGU\204'0\314\315\f A\316O\"\210 @*\207" . [prompt unbound value widget found answer read-string prin1-to-string 0 widget-get :prompt-history read-from-string error "Junk at end of expression: %s" nil])(#$ . 94351) nil 7]) (define-widget 'restricted-sexp 'sexp "A Lisp expression restricted to values that match.\nTo use this type, you must define :match or :match-alternatives." :type-error "The specified value is not valid" :match 'widget-restricted-sexp-match :value-to-internal #[(widget value) "\302\303 #\203\f\304 !\207 \207" [widget value widget-apply :match prin1-to-string] 4]) (defalias 'widget-restricted-sexp-match #[(widget value) #@227 ("\304\305\"\306\211\203=0 \204=0\307\n@!\2030\n@ !\20210\n@:\20360\n@@\310=\20360 \n@A@=\20360\311\nA\211\204 0 *\207" . [widget matched alternatives value widget-get :match-alternatives nil functionp quote t])(#$ . 95063) nil 4]) (byte-code "\300\301\302\303\304\305\306\307\310\311\312\313& \210\300\314\302\315\304\316\306\317\310\320\312\321& \210\300\322\302\323\304\324\306\325\310\326\312\327& \210\300\330\331\332\304\333\306\307\334\335\336\337\340\341\342\343\344\345\346\347\350\351&\210\300\352\353\354\304\355\336\356&\210\300\357\353\360\304\361\336\356\350\362\344\363\346\364& \207" [define-widget integer restricted-sexp "An integer." :tag "Integer" :value 0 :type-error "This field should contain an integer" :match-alternatives (integerp) number "A number (floating point or integer)." "Number" 0.0 "This field should contain a number (floating point or integer)" (numberp) float "A floating point number." "Floating point number" 0.0 "This field should contain a floating point number" (floatp) character editable-field "A character." "Character" :size 1 :format "%{%t%}: %v\n" :valid-regexp "\\`.\\'" :error "This field should contain a single character" :value-to-internal #[(widget value) ";\203\207\301!\207" [value char-to-string] 2] :value-to-external #[(widget value) ";\203 \301H\207\207" [value 0] 2] :match #[(widget value) "\301!\207" [value char-valid-p] 2] list group "A Lisp list." "List" "%{%t%}:\n%v" vector "A Lisp vector." "Vector" widget-vector-match #[(widget value) "\301\302\"\207" [value append nil] 3] #[(widget value) "\301\302\"\207" [value apply vector] 3]] 22) (defalias 'widget-vector-match #[(widget value) #@117 ("\302!\2050\303 \304 \305#\"\207" . [value widget vectorp widget-group-match widget-apply :value-to-internal])(#$ . 96756) nil 6]) (define-widget 'cons 'group "A cons-cell." :tag "Cons-cell" :format "%{%t%}:\n%v" :match 'widget-cons-match :value-to-internal #[(widget value) "@AD\207" [value] 2] :value-to-external #[(widget value) "\301\302\"\207" [value apply cons] 3]) (defalias 'widget-cons-match #[(widget value) #@105 (":\205 0\302 \303 \304#\"\207" . [value widget widget-group-match widget-apply :value-to-internal])(#$ . 97189) nil 6]) (byte-code "\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323&\210\300\324\325\326\327\330\331\332\306\333\334\335& \207" [define-widget lazy default "Base widget for recursive datastructures.\n\nThe `lazy' widget will, when instantiated, contain a single inferior\nwidget, of the widget type specified by the :type parameter. The\nvalue of the `lazy' widget is the same as the value of the inferior\nwidget. When deriving a new widget from the 'lazy' widget, the :type\nparameter is allowed to refer to the widget currently being defined,\nthus allowing recursive datastructures to be described.\n\nThe :type parameter takes the same arguments as the defcustom\nparameter with the same name.\n\nMost composite widgets, i.e. widgets containing other widgets, does\nnot allow recursion. That is, when you define a new widget type, none\nof the inferior widgets may be of the same type you are currently\ndefining.\n\nIn Lisp, however, it is custom to define datastructures in terms of\nthemselves. A list, for example, is defined as either nil, or a cons\ncell whose cdr itself is a list. The obvious way to translate this\ninto a widget type would be\n\n (define-widget 'my-list 'choice\n \"A list of sexps.\"\n :tag \"Sexp list\"\n :args '((const nil) (cons :value (nil) sexp my-list)))\n\nHere we attempt to define my-list as a choice of either the constant\nnil, or a cons-cell containing a sexp and my-lisp. This will not work\nbecause the `choice' widget does not allow recursion.\n\nUsing the `lazy' widget you can overcome this problem, as in this\nexample:\n\n (define-widget 'sexp-list 'lazy\n \"A list of sexps.\"\n :tag \"Sexp list\"\n :type '(choice (const nil) (cons :value (nil) sexp sexp-list)))" :format "%{%t%}: %v" :convert-widget widget-value-convert-widget :value-create widget-type-value-create :value-get widget-child-value-get :value-inline widget-child-value-inline :default-get widget-type-default-get :match widget-type-match :validate widget-child-validate plist list "A property list." :key-type (symbol :tag "Key") :value-type (sexp :tag "Value") widget-plist-convert-widget :tag "Plist"] 20) (defalias 'widget-plist-convert-widget #[(widget) #@348 ("\305\306\"\305\307\"\310\311\312\313\311\312\305\314\"\n\257F \20300\315\311\312\316\312\317\320 \"BBBBB D\20220 C\321\322\f#\210,\207" . [widget options widget-plist-value-type other args widget-get :options :value-type editable-list :inline t group :key-type checklist :greedy mapcar widget-plist-convert-option widget-put :args])(#$ . 99550) nil 9]) (defalias 'widget-plist-convert-option #[(option) #@215 ("\305\211\n<\203\"0\n@\nA@ <\2030 \2020\306 D)\202(0\306\nD\f\307\310\311\312\313 \257*\207" . [value-type key-type option key widget-plist-value-type nil const group :format "Key: %v" :inline t])(#$ . 99974) nil 7]) (define-widget 'alist 'list "An association list." :key-type '(sexp :tag "Key") :value-type '(sexp :tag "Value") :convert-widget 'widget-alist-convert-widget :tag "Alist") (defalias 'widget-alist-convert-widget #[(widget) #@360 ("\305\306\"\305\307\"\310\311\312\313\314\315\305\316\"\n\257F \20300\317\311\312\320\312\321\322 \"BBBBB D\20220 C\323\324\f#\210,\207" . [widget options widget-alist-value-type other args widget-get :options :value-type editable-list :inline t cons :format "%v" :key-type checklist :greedy mapcar widget-alist-convert-option widget-put :args])(#$ . 100437) nil 9]) (defalias 'widget-alist-convert-option #[(option) #@196 ("\305\211\n<\203\"0\n@\nA@ <\2030 \2020\306 D)\202(0\306\nD\f\307\310\311 \257*\207" . [value-type key-type option key widget-alist-value-type nil const cons :format "Key: %v"])(#$ . 100874) nil 5]) (define-widget 'choice 'menu-choice "A union of several sexp types." :tag "Choice" :format "%{%t%}: %[Value Menu%] %v" :button-prefix 'widget-push-button-prefix :button-suffix 'widget-push-button-suffix :prompt-value 'widget-choice-prompt-value) #@16 Make a choice. (defalias 'widget-choice-prompt-value #[(widget prompt value unbound) #@618 ("\306\307\"\306\310\"\311\211\211\211\211\20360\312@\313#\203-0@\311\211\2020A\211\2040) G\314U\203B0\311\202\2510 G\315U\203N0 @\202\2510 G\316U\203m0 >\203m0 @=\203h0 A@\202\2510 @\202\2510 \203\2030 @ A\312 \317\" B\nB\202m0\320\n\311\321$\211;\205\2500\322\n\"\211;\203\2410\323\n\"A))\211\203\2700\324 \311\321$\202\2720-\207" . [widget old choices current completion-ignore-case args widget-get :args :case-fold nil widget-apply :match 0 1 2 :menu-tag-get completing-read t try-completion assoc widget-prompt-value look value prompt val try])(#$ . 101434) nil 6 (#$ . 101342)]) (byte-code "\300\301\302\303\304\305\306\307\310\311& \210\300\312\313\314\304\315\306\316&\210\300\317\320\321\304\322\306\307&\210\300\323\324\325\304\326\310\327\330\331\332\333\306\334\335\336\337\340&\207" [define-widget radio radio-button-choice "A union of several sexp types." :tag "Choice" :format "%{%t%}:\n%v" :prompt-value widget-choice-prompt-value repeat editable-list "A variable length homogeneous list." "Repeat" "%{%t%}:\n%v%i\n" set checklist "A list of members from a fixed set." "Set" boolean toggle "To be nil or non-nil, that is the question." "Boolean" widget-boolean-prompt-value :button-prefix widget-push-button-prefix :button-suffix widget-push-button-suffix "%{%t%}: %[Toggle%] %v\n" :on "on (non-nil)" :off "off (nil)"] 18) (defalias 'widget-boolean-prompt-value #[(widget prompt value unbound) #@36 ("\301!\207" . [prompt y-or-n-p])(#$ . 102921) nil 2]) (define-widget 'color 'editable-field "Choose a color name (with sample)." :format "%{%t%}: %v (%{sample%})\n" :size 10 :tag "Color" :value "black" :complete 'widget-color-complete :sample-face-get 'widget-color-sample-face-get :notify 'widget-color-notify :action 'widget-color-action) #@31 Complete the color in WIDGET. (defalias 'widget-color-complete #[(widget) #@569 ("\305\306!\210\307\310!`\"\n\2060\311 \312 \"\211\313=\203#0\314\315!\202Q0\f\204.0\316\317 \"\202Q0 \f\230\204>0\320\f G\321O!\202Q0\314\322!\210\323\220\324\325 \321# \"\221\210\314\326!+\207" . [widget prefix facemenu-color-alist list completion require facemenu buffer-substring-no-properties widget-field-start defined-colors try-completion t message "Exact match." error "Can't find completion for \"%s\"" insert-and-inherit nil "Making completion list..." "*Completions*" display-completion-list all-completions "Making completion list...done"])(#$ . 103351) nil 7 (#$ . 103270)]) (defalias 'widget-color-sample-face-get #[(widget) #@173 ("\301\302\303\217\304!\2030\305BC\2020\306)\207" . [value nil (widget-value widget) ((error (widget-get widget :value))) color-defined-p foreground-color default])(#$ . 104012) nil 3]) #@21 Prompt for a color. (defalias 'widget-color-action #[(widget &optional event) #@279 ("\306\307\"\211\310P\311!\312!\313\n!\314 G!?\205,0\315 \"\210\316 \210\306\317$-\207" . [widget tag prompt value start answer widget-apply :menu-tag-get ": " widget-value widget-field-start facemenu-read-color zerop widget-value-set widget-setup :notify event])(#$ . 104296) nil 6 (#$ . 104211)]) #@43 Update the sample, and notify the parent. (defalias 'widget-color-notify #[(widget child &optional event) #@173 ("\303\304\305\"\306\307\310\"#\210\311 \n#\207" . [widget child event overlay-put widget-get :sample-overlay face widget-apply :sample-face-get widget-default-notify])(#$ . 104728) nil 6 (#$ . 104615)]) #@43 Display help-echo text for widget at POS. (defalias 'widget-echo-help #[(pos) #@172 ("\303!\211\205\f0\304 \305\"\306\n!\2030\n !\n\205!0\307\310\311\n!\"*\207" . [pos widget help-echo widget-at widget-get :help-echo functionp message "%s" eval])(#$ . 105026) nil 5 (#$ . 104941)]) (provide 'wid-edit)