diff options
| author | Dave Love | 1999-10-01 22:04:30 +0000 |
|---|---|---|
| committer | Dave Love | 1999-10-01 22:04:30 +0000 |
| commit | 6171a9453950a147396eef409d30d98054ae2d74 (patch) | |
| tree | 145656b597aed672c502a7486ec196063ee79d93 | |
| parent | 4a8adb0bc7d0c673128c448b6e1888de8ad67c09 (diff) | |
| download | emacs-6171a9453950a147396eef409d30d98054ae2d74.tar.gz emacs-6171a9453950a147396eef409d30d98054ae2d74.zip | |
(custom-comment-create): Fill :from and :to slots
| -rw-r--r-- | lisp/cus-edit.el | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el index ef9abde7892..5f876b66dce 100644 --- a/lisp/cus-edit.el +++ b/lisp/cus-edit.el | |||
| @@ -1955,9 +1955,13 @@ If INITIAL-STRING is non-nil, use that rather than \"Parent groups:\"." | |||
| 1955 | 1955 | ||
| 1956 | (defun custom-comment-create (widget) | 1956 | (defun custom-comment-create (widget) |
| 1957 | (let* ((null-comment (equal "" (widget-value widget)))) | 1957 | (let* ((null-comment (equal "" (widget-value widget)))) |
| 1958 | (when (or (widget-get (widget-get widget :parent) :comment-shown) | 1958 | (if (or (widget-get (widget-get widget :parent) :comment-shown) |
| 1959 | (not null-comment)) | 1959 | (not null-comment)) |
| 1960 | (widget-default-create widget)))) | 1960 | (widget-default-create widget) |
| 1961 | ;; `widget-default-delete' expects markers in these slots -- | ||
| 1962 | ;; maybe it shouldn't. | ||
| 1963 | (widget-put widget :from (point-marker)) | ||
| 1964 | (widget-put widget :to (point-marker))))) | ||
| 1961 | 1965 | ||
| 1962 | (defun custom-comment-hide (widget) | 1966 | (defun custom-comment-hide (widget) |
| 1963 | (widget-put (widget-get widget :parent) :comment-shown nil)) | 1967 | (widget-put (widget-get widget :parent) :comment-shown nil)) |