help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to obtain customize :type for an option at runtime?


From: Lennart Borgman
Subject: Re: How to obtain customize :type for an option at runtime?
Date: Sun, 29 Jan 2006 03:09:29 +0100
User-agent: Thunderbird 1.5 (Windows/20051201)

Drew Adams wrote:
How can I determine, for a given user option, what its Customize :type is?

For example, function `user-variable-p' tests whether a symbol is a user
option, but what if I want to test whether a variable is a toggle (binary)
option?

Although not all options that can act as toggles are defined with a simple
":type 'boolean" in Customize (far from it, and there are good reasons for
that), obtaining such :type info would be a start.
It is in the symbol property list:

   (get 'your-symbol 'custom-type)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]