changeset 99672:ad3c9b9265d3

(custom-group-value-create): Don't insert docstring twice.
author Chong Yidong <cyd@stupidchicken.com>
date Mon, 17 Nov 2008 18:05:42 +0000
parents 800639e86fb2
children 1d9acf55fb04
files lisp/cus-edit.el
diffstat 1 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/cus-edit.el	Mon Nov 17 18:05:30 2008 +0000
+++ b/lisp/cus-edit.el	Mon Nov 17 18:05:42 2008 +0000
@@ -4005,7 +4005,8 @@
 	   (let ((start (point)))
 	     (insert tag " group: ")
 	     (widget-specify-sample widget start (point)))
-	   (insert (widget-docstring widget))
+	   (if (< (length (widget-docstring widget)) 50)
+	       (insert (widget-docstring widget)))
 	   ;; Create visibility indicator.
 	   (unless (eq custom-buffer-style 'links)
 	     (insert "--------")
@@ -4032,8 +4033,9 @@
 	   ;; Update buttons.
 	   (widget-put widget :buttons buttons)
 	   ;; Insert documentation.
-	   (widget-add-documentation-string-button
-	    widget :visibility-widget 'custom-visibility)
+	   (if (>= (length (widget-docstring widget)) 50)
+	       (widget-add-documentation-string-button
+		widget :visibility-widget 'custom-visibility))
 
 	   ;; Parent groups.
 	   (if nil  ;;; This should test that the buffer