-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcodigo01.py
More file actions
37 lines (30 loc) · 1.13 KB
/
codigo01.py
File metadata and controls
37 lines (30 loc) · 1.13 KB
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
from tkinter import *
class Application:
def __init__(self, master=None):
#---------------------------------------------------
# Definição dos Widgets
#---------------------------------------------------
self.lbtitulo = Label()
self.lbtitulo["text"] = "Quem é a pessoa da figura?"
self.lbtitulo["font"] = ("Verdana", "16", "bold")
self.lbtitulo.pack()
self.lbimagem = Label()
self.lbimagem.img = PhotoImage(file="imgs/gracehopper.png")
self.lbimagem["image"] = self.lbimagem.img
self.lbimagem.pack()
self.bt1 = Button()
self.bt1["text"] = "Grace Hopper"
self.bt1["font"] = ("Verdana", "10")
self.bt1.pack()
self.bt2 = Button()
self.bt2["text"] = "Margaret Hamilton"
self.bt2["font"] = ("Verdana", "10")
self.bt2.pack()
self.btavancar = Button()
self.btavancar["font"] = ("Verdana", "10", "bold")
self.btavancar.pack()
root = Tk()
root.title("Jogo de Perguntas e Respostas")
root.geometry("400x400")
Application(root)
root.mainloop()