/[emacs]/emacs/lisp/cus-edit.el
ViewVC logotype

Diff of /emacs/lisp/cus-edit.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.157.2.8 by miles, Tue Jul 6 09:44:42 2004 UTC revision 1.157.2.9 by miles, Tue Jul 6 10:17:15 2004 UTC
# Line 2074  If INITIAL-STRING is non-nil, use that r Line 2074  If INITIAL-STRING is non-nil, use that r
2074    :group 'custom-buffer    :group 'custom-buffer
2075    :version "20.3")    :version "20.3")
2076    
2077    (defun custom-variable-documentation (variable)
2078      "Return documentation of VARIABLE for use in Custom buffer.
2079    Normally just return the docstring.  But if VARIABLE automatically
2080    becomes buffer local when set, append a message to that effect."
2081      (if (and (local-variable-if-set-p variable)
2082               (or (not (local-variable-p variable))
2083                   (with-temp-buffer
2084                     (local-variable-if-set-p variable))))
2085          (concat (documentation-property variable 'variable-documentation)
2086                  "\n
2087    This variable automatically becomes buffer-local when set outside Custom.
2088    However, setting it through Custom sets the default value.")
2089        (documentation-property variable 'variable-documentation)))
2090    
2091  (define-widget 'custom-variable 'custom  (define-widget 'custom-variable 'custom
2092    "Customize variable."    "Customize variable."
2093    :format "%v"    :format "%v"
2094    :help-echo "Set or reset this variable."    :help-echo "Set or reset this variable."
2095    :documentation-property 'variable-documentation    :documentation-property #'custom-variable-documentation
2096    :custom-category 'option    :custom-category 'option
2097    :custom-state nil    :custom-state nil
2098    :custom-menu 'custom-variable-menu-create    :custom-menu 'custom-variable-menu-create

Legend:
Removed from v.1.157.2.8  
changed lines
  Added in v.1.157.2.9

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26