aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2012-05-01 14:47:23 -0400
committerGlenn Morris2012-05-01 14:47:23 -0400
commitd80ac57b32c2cf2b3b86e60a550858c81f214ebc (patch)
tree5d5bd72f3856fc5f6a49eecd961eded7143bce77
parentc8f8221fd15ea7fdc3e7abb35f7d39b949c3acb9 (diff)
downloademacs-d80ac57b32c2cf2b3b86e60a550858c81f214ebc.tar.gz
emacs-d80ac57b32c2cf2b3b86e60a550858c81f214ebc.zip
* lisp/cus-edit.el (custom-variable-documentation): Simplify with format.
-rw-r--r--lisp/ChangeLog4
-rw-r--r--lisp/cus-edit.el16
2 files changed, 12 insertions, 8 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index cfc40bc01a8..e4c45a23478 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,7 @@
12012-05-01 Glenn Morris <rgm@gnu.org>
2
3 * cus-edit.el (custom-variable-documentation): Simplify with format.
4
12012-05-01 Aaron S. Hawley <aaron.s.hawley@gmail.com> 52012-05-01 Aaron S. Hawley <aaron.s.hawley@gmail.com>
2 Stefan Monnier <monnier@iro.umontreal.ca> 6 Stefan Monnier <monnier@iro.umontreal.ca>
3 7
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el
index 8198a4594c4..4458bb7b56f 100644
--- a/lisp/cus-edit.el
+++ b/lisp/cus-edit.el
@@ -1,6 +1,6 @@
1;;; cus-edit.el --- tools for customizing Emacs and Lisp packages 1;;; cus-edit.el --- tools for customizing Emacs and Lisp packages
2;; 2;;
3;; Copyright (C) 1996-1997, 1999-2012 Free Software Foundation, Inc. 3;; Copyright (C) 1996-1997, 1999-2012 Free Software Foundation, Inc.
4;; 4;;
5;; Author: Per Abrahamsen <abraham@dina.kvl.dk> 5;; Author: Per Abrahamsen <abraham@dina.kvl.dk>
6;; Maintainer: FSF 6;; Maintainer: FSF
@@ -2460,15 +2460,15 @@ If INITIAL-STRING is non-nil, use that rather than \"Parent groups:\"."
2460 "Return documentation of VARIABLE for use in Custom buffer. 2460 "Return documentation of VARIABLE for use in Custom buffer.
2461Normally just return the docstring. But if VARIABLE automatically 2461Normally just return the docstring. But if VARIABLE automatically
2462becomes buffer local when set, append a message to that effect." 2462becomes buffer local when set, append a message to that effect."
2463 (if (and (local-variable-if-set-p variable) 2463 (format "%s%s" (documentation-property variable 'variable-documentation)
2464 (or (not (local-variable-p variable)) 2464 (if (and (local-variable-if-set-p variable)
2465 (with-temp-buffer 2465 (or (not (local-variable-p variable))
2466 (local-variable-if-set-p variable)))) 2466 (with-temp-buffer
2467 (concat (documentation-property variable 'variable-documentation) 2467 (local-variable-if-set-p variable))))
2468 "\n 2468 "\n
2469This variable automatically becomes buffer-local when set outside Custom. 2469This variable automatically becomes buffer-local when set outside Custom.
2470However, setting it through Custom sets the default value.") 2470However, setting it through Custom sets the default value."
2471 (documentation-property variable 'variable-documentation))) 2471 "")))
2472 2472
2473(define-widget 'custom-variable 'custom 2473(define-widget 'custom-variable 'custom
2474 "A widget for displaying a Custom variable. 2474 "A widget for displaying a Custom variable.