Skip to content

Commit

Permalink
Added basic GUI
Browse files Browse the repository at this point in the history
  • Loading branch information
OxPoly committed May 23, 2014
1 parent 17144e2 commit 07df864
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions gui.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/usr/bin/python3

import tkinter as tk

class Application(tk.Frame):
def __init__(self, master=None):
tk.Frame.__init__(self, master)
self.pack()
self.createWidgets()

def createWidgets(self):
self.title=tk.Label(self)
self.title["text"] = "Centry"
self.title["font"] = ('',26,'bold')
self.title.pack(side='top')
self.hi_there = tk.Button(self)
# self.hi_there["text"] = "Hello World\n(click me)"
# self.hi_there["command"] = self.say_hi
# self.hi_there.pack(side="right")

self.QUIT = tk.Button(self, text="PANIC",font=('',32,''), bg="red", fg="black",
command=root.destroy)
self.QUIT.pack(side="bottom")

def say_hi(self):
print("hi there, everyone!")

root = tk.Tk()
app = Application(master=root)
app.master.title("Centry Panic Systems")
app.master.geometry("400x300")
app.mainloop()

0 comments on commit 07df864

Please sign in to comment.