Mercurial > emacs
diff lisp/custom.el @ 69922:dc1f0ab7e276
* custom.el (defcustom, custom-handle-keyword): Add :package-version
keyword.
(custom-add-package-version): New function. Sets value of new property
'custom-package-version from :package-version keyword.
* cus-edit.el (customize-package-emacs-version-alist): New variable.
(customize-changed-options): Add check for custom-package-version.
(customize-package-emacs-version): New function to look up Emacs
version corresponding to the given package version.
author | Bill Wohler <wohler@newt.com> |
---|---|
date | Mon, 10 Apr 2006 23:43:34 +0000 |
parents | efd1add5bedf |
children | 9319f873855b |
line wrap: on
line diff
--- a/lisp/custom.el Mon Apr 10 22:33:51 2006 +0000 +++ b/lisp/custom.el Mon Apr 10 23:43:34 2006 +0000 @@ -268,6 +268,12 @@ VALUE should be a string specifying that the variable was first introduced, or its default value was changed, in Emacs version VERSION. +:package-version + VALUE should be a list with the form (PACKAGE VERSION) + specifying that the variable was first introduced, or its + default value was changed, in PACKAGE version VERSION. This + keyword takes priority over :version. The PACKAGE and VERSION + must appear in the alist `customize-package-emacs-version-alist'. :tag LABEL Use LABEL, a string, instead of the item's name, to label the item in customization menus and buffers. @@ -489,6 +495,8 @@ (custom-add-to-group value symbol type)) ((eq keyword :version) (custom-add-version symbol value)) + ((eq keyword :package-version) + (custom-add-package-version symbol value)) ((eq keyword :link) (custom-add-link symbol value)) ((eq keyword :load) @@ -540,6 +548,10 @@ "To the custom option SYMBOL add the version VERSION." (put symbol 'custom-version (purecopy version))) +(defun custom-add-package-version (symbol version) + "To the custom option SYMBOL add the package version VERSION." + (put symbol 'custom-package-version (purecopy version))) + (defun custom-add-load (symbol load) "To the custom option SYMBOL add the dependency LOAD. LOAD should be either a library file name, or a feature name."