My favorites | Sign in
Project Home Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
tkinter  
Python GUI Development
Phase-Implementation, Phase-Design
Updated Nov 11, 2012 by eski...@gmail.com

See Also Tk Docs

Introduction

The project standard GUI is Tkinter and ttk, as both are included in the standard Python distribution. Other GUIs may be implemented, but links to the download page for the GUI must be included in the module.py file.

Tkinter is the base GUI module, ttk is an extension of Tkinter that allows for more modern-looking cross-platform widgets.

Recommended Usage

root   # Toplevel Window
font   # Custom font
label  # Text label
button # Buton
entry  # Text Field
import tkinter as tk
import tkinter.ttk as ttk

root = tk.Tk()
root.title('Game Name')

font = 'Arial 16 italic'

label = ttk.Label(root, text='Hello World', font=font)
label.grid(row=0, column=0)

button = ttk.Buton(root, text='Push Me', command=exit)
button.grid(row=1, column=0)

entry = ttk.Entry(root)
entry.grid(row=2, column=0)

root.mainloop() # Actually display root to user.

For advanced usage see Tk Docs

Powered by Google Project Hosting