-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgui test.py
More file actions
50 lines (32 loc) · 1017 Bytes
/
gui test.py
File metadata and controls
50 lines (32 loc) · 1017 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
from tkinter import *
class App(Frame):
def __init__(self, parent):
Frame.__init__(self)
self.b1 = Button(parent, text = "bye bye", command = self.quit)
self.b1.pack()
self.b2 = Button(parent, text = "Hype", command = self.say)
self.b2.pack()
def say():
pass
def quit():
pass
window = Tk()
window.title("Test Window")
# app = App(window)
# l1 = Label(window, bg = "yellow")
# l1.pack(side = LEFT, expand = 1, fill = BOTH)
# l2 = Label(window, bg = "red")
# l2.pack(side = LEFT, expand = 1, fill = BOTH)
# l3 = Label(window, bg = "blue")
# l3.pack(side = LEFT, expand = 1, fill = BOTH)
l4 = Label(window, text = "oh no...")
l4.grid(row = 0, column = 0)
l5 = Label(window, text = "anyway")
l5.grid(row = 1, column = 0)
e1 = Entry(window, width = 15)
e1.grid(row = 0, column = 1)
e2 = Entry(window, width = 15)
e2.grid(row = 1, column = 1)
window.mainloop()
# l1 = Label(window, text = "Among Us")
# l1.mainloop()