-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathUI.py
More file actions
20 lines (16 loc) · 699 Bytes
/
UI.py
File metadata and controls
20 lines (16 loc) · 699 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
from tkinter import Tk,Frame,TOP,LEFT,BOTTOM,RAISED,BOTH
import controller
import model
# Construct a simple root window
root = Tk()
root.title("Simulation")
root.protocol("WM_DELETE_WINDOW",quit)
frame = Frame(root)
# Place buttons simply at the top
frame.pack(side=TOP)
controller.reset_button (frame,text="Reset") .pack(side=LEFT)
controller.reg_button (frame,text="regret") .pack(side=LEFT)
#controller.start_button (frame,text="Start") .pack(side=LEFT)
#model.progress (frame,text="",width=25,relief=RAISED).pack(side=TOP)
# Place canvas in the space below
controller.simulation_canvas(root,width=1000,height=1000,bg="#707070").pack(side=BOTTOM,expand=True,fill=BOTH)