widget.item(rowid, tags=()) elif(boolean): self.set_songs(rowid, widget, True) def generate(self): if(self.widgetVars["style"].get() in PySong.auxiliary.getStyles()): style = self.widgetVars["style"].get() else: style = PySong.handleNewStyle(self.widgetVars["style"].get()) self.pstyle.config(values = PySong.auxiliary.getStyles()) pdf = PySong.SongBooklet(self.widgetVars["name"].get(), style, self.widgetVars["logo"].get(), self.widgetVars["indexing"].get()) pdf.songLst = [{"title" : self.tree.set(x, "title"), "text" : self.tree.set(x, "song"), "options" : eval(self.tree.set(x, "options"))} for x in self.tree.tag_has("red")] pdf.makeBooklet(self.widgetVars["booklet"].get()) # main root = ttk.setup_master() root.title("SongBooklet") icon = tk.PhotoImage(data = DataFile.Valknut) root.iconphoto(root, icon) root.focus_force() app = Application(root) root.mainloop()
return (name, extension, date, size, fdir, owner, carousel) def handle_click(self, event): if self.TreeView.identify_region(event.x, event.y) == "separator": return "break" elif self.TreeView.identify_region( event.x, event.y) == "cell" or self.TreeView.identify_region( event.x, event.y) == "tree": self.item = self.TreeView.identify('item', event.x, event.y) #print("ITEM IS " + item) item_content = self.TreeView.item(self.item) self.item_id = item_content["tags"][0] conn = db.connectDB("test.db") self.Filedb = Files(conn) CS = self.Filedb.getCarouselStatus(self.item_id) conn.close() self.carouselState.set(CS) root = ttk.setup_master() root.title("RuralSync") root.geometry("1000x340") root.resizable(False, False) style = ttk.Style() style.configure("TButton", background="tomato") style.configure("Remove.TButton", background="red") style.configure("bottom.TFrame", width=40) app = Application(master=root) #root.protocol("WM_DELETE_WINDOW",app.on_close_window) app.mainloop()
def setUp(self): self.root = setup_master() self.text = tkinter.Text(self.root)
def setUp(self): self.root = ttk.setup_master()
def setUp(self): self.root = setup_master() self.scaling = float(self.root.call('tk', 'scaling')) if not self.root.wantobjects(): self.wantobjects = False
def setUp(self): self.root = ttk.setup_master() self.wantobjects = self.root.wantobjects()