def __init__(self, label, value): """ @param label: A friendly label to be applied to this option. Example: "Filter" @type label: string @param value: A default value for the option. Example: 1 @type label: int @return: nothing """ EnumeratedListOption.__init__(self, label, value) self.__filters = []
def __init__(self, label, default_style, module_name): """ @param label: A friendly label to be applied to this option. Example: "Style" @type label: string @param default_style: A docgen StyleSheet instance which provides the default styles. @type default_style: docgen StyleSheet @param module_name: The name of the module the style sheets belong to. Example: "web_cal" @type module_name: string @return: nothing """ EnumeratedListOption.__init__(self, label, "default") self.__default_style = default_style self.__default_style.set_name("default") self.__style_file = "%s_style.xml" % module_name style_list = StyleSheetList(self.__style_file, self.__default_style) for style_name in style_list.get_style_names(): self.add_item(style_name, style_name)