rox.options | index |
To use the Options system:
1. Create an OptionGroup:
options = OptionGroup('MyProg', 'Options')
You can also use the handy rox.setup_app_options() in most applications.
2. Create the options:
colour = Option('colour', 'red', options)
size = Option('size', 3, options)
3. Register any callbacks (notification of options changing):
def my_callback():
if colour.has_changed:
print "The colour is now", colour.value
options.add_notify(my_callback)
4. Notify any changes from defaults:
options.notify()
See OptionsBox for editing options. Do not change the value of options
yourself.
Classes | ||||||||||||||||||
|
Functions | ||
|