def __init__(self): wal.MainWindow.__init__(self) self.set_size(SIZE) items = ['One', 'Two', 'Three', 'One', 'Two', 'Three'] lst1 = wal.SimpleList(self, items, False) self.pack(lst1, padding=5, fill=True) lst2 = wal.SimpleList(self, items, False, alt_color=True) self.pack(lst2, padding=5, fill=True)
def build(self): self.set_profiles() vp = wal.VPanel(self.panel) vp.set_bg(wal.UI_COLORS['border']) self.viewer = wal.SimpleList(vp, self.pf_list, on_select=self.selection_changed) vp.pack(self.viewer, expand=True, fill=True, padding_all=1) self.panel.pack(vp, expand=True, fill=True, padding_all=5) btn_box = wal.VPanel(self.panel) self.panel.pack(btn_box, fill=True, padding_all=5) self.import_btn = wal.Button(btn_box, _('Import'), onclick=self.import_profile) btn_box.pack(self.import_btn, fill=True, end_padding=5) self.remove_btn = wal.Button(btn_box, _('Remove'), onclick=self.remove_profile) btn_box.pack(self.remove_btn, fill=True, end_padding=5) self.info_btn = wal.Button(btn_box, _('Info'), onclick=self.profile_info) btn_box.pack(self.info_btn, fill=True, end_padding=5) self.viewer.set_active(0)
def __init__(self, parent): self.app = parent.app self.parent = parent wal.HPanel.__init__(self, parent) self.pal_list = wal.SimpleList(self, self.parent.data, on_select=self.change_palette) self.pack(self.pal_list, expand=True, fill=True, padding_all=5) self.preview = PreViewer(self) self.pack(self.preview, fill=True, padding_all=5)
def __init__(self, app, prefpanel, parent): self.app = app self.prefpanel = prefpanel wal.HPanel.__init__(self, parent) data = self.get_palette_list() self.pal_list = wal.SimpleList(self, data, on_select=self.change_palette) self.pack(self.pal_list, expand=True, fill=True, padding_all=5) self.pal_viewer = PaletteViewer(self, self.app.default_cms) self.pack(self.pal_viewer, fill=True, padding_all=5) btn_box = wal.VPanel(self) self.pack(btn_box, fill=True, padding_all=5) btn_box.pack(wal.Button(btn_box, _('Import'), onclick=self.import_palette), fill=True, end_padding=5) btn_box.pack(wal.Button(btn_box, _('Export'), onclick=self.export_palette), fill=True, end_padding=5) self.remove_btn = wal.Button(btn_box, _('Remove'), onclick=self.remove_palette) btn_box.pack(self.remove_btn, fill=True, end_padding=5) self.edit_btn = wal.Button(btn_box, _('Edit info'), onclick=self.edit_info) btn_box.pack(self.edit_btn, fill=True, end_padding=5) btn_box.pack(wal.VPanel(btn_box), fill=True, expand=True) btn_box.pack(wal.ImageButton(btn_box, icons.PD_DOWNLOAD48, tooltip=_('Download more palettes'), flat=False, onclick=self.download_more), fill=True, end_padding=5) # btn_box.pack(CollectionButton(btn_box, self.app, self, # self.prefpanel.dlg), fill=True, end_padding=5) self.update_palette_list()
def __init__(self, parent): self.app = parent.app self.parent = parent wal.HPanel.__init__(self, parent) vp = wal.VPanel(self) vp.set_bg(wal.UI_COLORS['border']) self.pal_list = wal.SimpleList(vp, PALETTE_LIST, on_select=self.change_palette) vp.pack(self.pal_list, expand=True, fill=True, padding_all=1) self.pack(vp, expand=True, fill=True, padding_all=5) self.preview = PreViewer(self) self.pack(self.preview, fill=True, padding_all=5)
def __init__(self, parent): wal.HPanel.__init__(self, parent) self.slist = wal.SimpleList(self, TESTLIST, on_select=self.selected, on_activate=self.activated) self.pack(self.slist, expand=True, fill=True, padding=10) self.report = wal.ReportList(self, TESTMULTILIST, on_select=self.selected, on_activate=self.activated) self.pack(self.report, expand=True, fill=True, padding=10)
def __init__(self, parent, attrs): wal.VPanel.__init__(self, parent) hpanel = wal.HPanel(self) vp = wal.VPanel(hpanel) vp.set_bg(wal.UI_COLORS['border']) self.attrs_list = wal.SimpleList(vp, [], on_select=self.attrs_changed, on_activate=self.attrs_changed) vp.pack(self.attrs_list, expand=True, fill=True, padding_all=1) hpanel.pack(vp, expand=True, fill=True) hpanel.pack((10, 10)) self.value = wal.Entry(hpanel, '', multiline=True, editable=False) hpanel.pack(self.value, expand=True, fill=True) self.pack(hpanel, fill=True, expand=True, padding_all=10) self.status_label = wal.Label(self, '---') self.pack(self.status_label, fill=True, align_center=False, padding_all=10) self.set_prn_attrs(attrs)
def __init__(self, parent, details): wal.VPanel.__init__(self, parent) hpanel = wal.HPanel(self) self.details_list = wal.SimpleList(hpanel, [], on_select=self.details_changed, on_activate=self.details_changed) hpanel.pack(self.details_list, expand=True, fill=True) hpanel.pack((10, 10)) self.value = wal.Entry(hpanel, '', multiline=True, editable=False) hpanel.pack(self.value, expand=True, fill=True) self.pack(hpanel, fill=True, expand=True, padding_all=10) self.status_label = wal.Label(self, '---') self.pack(self.status_label, fill=True, align_center=False, padding_all=10) self.set_prn_details(details)