| |
- Option
- OptionGroup
class Option |
|
An Option stores a single value. Every option is part of exactly one OptionGroup.
The read-only attributes value and int_value can be used to get the current setting
for the Option. int_value will be -1 if the value is not a valid integer.
The has_changed attribute is used during notify() calls to indicate whether this
Option's value has changed since the last notify (or option creation).
You may set has_changed = 1 right after creating an option if you want to force
notification the first time even if the default is used. |
|
Methods defined here:
- __init__(self, name, value, group=None)
- Create a new option with this name and default value.
Add to 'group', or to rox.app_options if no group is given.
The value cannot be used until the first notify() call to
the group.
|
class OptionGroup |
|
|
|
Methods defined here:
- __init__(self, program, leaf)
- program/leaf is a Choices pair for the saved options.
- add_notify(self, callback)
- Call callback() after one or more options have changed value.
- notify(self)
- Call this after creating any new options or changing their values.
- remove_notify(self, callback)
- Remove a callback added with add_notify().
- save(self)
- Save all option values. Usually called by OptionsBox().
| |