122
123
124
125
126
127
128
129
130
131
132
133
134
135
136 | for name,meta in sorted(ls.items(), key=lambda e: e[1]["type"]+e[1]["title"].lower(), reverse=False):
if not name in conf.plugins:
conf.plugins[name] = False
self.add_plg(name, meta)
# add configuration setting definitions from plugins
plugin_text = "<span size='larger' weight='heavy'>%s</span> <span style='italic' foreground='slate blue'>(%s/%s)</span> <span weight='bold' foreground='orange'>%s</span>\n<span size='smaller' stretch='ultraexpanded'>%s</span>"
def add_plg(self, name, meta):
# add plugin load entry
cb = gtk.CheckButton(name)
cb.set_sensitive(not meta.get("priority") in ("core", "required", "builtin"))
cb.get_children()[0].set_markup(self.plugin_text % (meta.get("title", name), meta.get("type", "plugin"), meta.get("category", "addon"), meta.get("version", "./."), meta.get("description", "no description")))
cb.set_tooltip_text(re.sub("(?<=\S) *\n(?! *\n)", " ",meta.get("doc", "")).strip())
self.add_( "config_plugins_"+name, cb, color=meta.get("color"), image=meta.get("png")) |
|
>
>
>
| 122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139 | for name,meta in sorted(ls.items(), key=lambda e: e[1]["type"]+e[1]["title"].lower(), reverse=False):
if not name in conf.plugins:
conf.plugins[name] = False
self.add_plg(name, meta)
# add configuration setting definitions from plugins
plugin_text = "<span size='larger' weight='heavy'>%s</span> "\
+ "<span style='italic' foreground='slate blue'>(%s/%s)</span> "\
+ "<span weight='bold' foreground='#777777'>%s</span>\n"\
+ "<span size='smaller' stretch='ultraexpanded'>%s</span>"
def add_plg(self, name, meta):
# add plugin load entry
cb = gtk.CheckButton(name)
cb.set_sensitive(not meta.get("priority") in ("core", "required", "builtin"))
cb.get_children()[0].set_markup(self.plugin_text % (meta.get("title", name), meta.get("type", "plugin"), meta.get("category", "addon"), meta.get("version", "./."), meta.get("description", "no description")))
cb.set_tooltip_text(re.sub("(?<=\S) *\n(?! *\n)", " ",meta.get("doc", "")).strip())
self.add_( "config_plugins_"+name, cb, color=meta.get("color"), image=meta.get("png")) |