| Download Documentation Tutorial Screenshots Demo Apps Cookbook FAQs Contact |
EasyGUI is a module for very simple, very easy GUI programming in Python.
Experienced Pythonistas need support for quick and dirty GUI features. New Python programmers need GUI capabilities that don't require any knowledge of Tkinter, frames, widgets, callbacks or lambda. This is what EasyGUI provides. Using EasyGUI, all GUI interactions are invoked by simple function calls.
EasyGUI is different from other GUIs in that EasyGUI is NOT event-driven. It allows you to program in a traditional linear fashion, and to put up dialogs for simple input and output when you need to. If you have not yet learned the event-driven paradigm for GUI programming, EasyGUI will allow you to be productive with very basic tasks immediately. Later, if you wish to make the transition to an event-driven GUI paradigm, you can do so with a more powerful GUI package such as anygui, PythonCard, Tkinter, wxPython, etc.
There is the EasyGui tutorial.
A nice way to learn about EasyGui is by watching two videos that Austrian teacher Horst Jens has made with some children in his Python programming class. In one video Lexi shows msgbox, and in the other Leo shows buttonbox. The videos are several minutes each. The kids speak in German and the videos have English subtitles.
Horst says that "I can proudly report that EasyGui is very popular with my students (game programming courses)." Mira and Teresa, two of his students, have used EasyGui to make a simple graphic adventure game. Watch the video here.While you are visiting ShowMeDo, check out the other Python videos.
September 8, 2008: At Linux.com: Dress up your Python scripts with EasyGui by Dmitri Popov
August 25, 2009: The University of Toronto will be using EasyGui while using Python as a first-year programming language. "We’ve dropped Tkinter this fall in favour of EasyGUI, which has major limitations but is much more teachable." You can read more about what it’s been like switching to Python as a first-year programming language, here
multenterbox
choicebox
multchoicebox
passwordbox
msgbox
continue/cancel box
buttonbox with image
... and see the demo program (below).
A simple demo program using EasyGui |
(screenshots to different scales) |
from easygui import *
import sys
while 1:
msgbox("Hello, world!")
|
|
msg ="What is your favorite flavor?" title = "Ice Cream Survey" choices = ["Vanilla", "Chocolate", "Strawberry", "Rocky Road"] choice = choicebox(msg, title, choices) |
|
# note that we convert choice to string, in case
# the user cancelled the choice, and we got None.
msgbox("You chose: " + str(choice), "Survey Result")
|
![]() |
msg = "Do you want to continue?" title = "Please Confirm" if ccbox(msg, title): # show a Continue/Cancel dialog pass # user chose Continue else: sys.exit(0) # user chose Cancel |
![]() |