from tkinter import * class Application(Frame): """ GUI application. """ def __init__(self, master): """ Initialize the frame. """ super(Application, self).__init__(master) self.grid() self.create_widgets() frame = Frame(master) frame.pack() def create_widgets(self): # create instruction label self.inst_lbl = Label(self, text = "Test") self.inst_lbl.grid(row = 1, column = 1, columnspan = 2, sticky = W) # create submit button self.submit_bttn = Button(self, text = "OK", command = ?????) self.submit_bttn.grid(row = 3, column = 2, sticky = W) # create submit button self.submit_bttn = Button(self, text = "Cancel", command = ????) self.submit_bttn.grid(row = 3, column = 4, sticky = W) # main root = Tk() root.title("Test") root.geometry("100x50") app = Application(root) root.mainloop()