1 """an example of fancy event handling, ProgressBars, etc"""
4 from pygame.locals import *
6 # the following line is not needed if pgu is installed
7 import sys; sys.path.insert(0, "..")
14 c = gui.Container(width=440,height=420)
16 c.add(gui.Label("Click on Cuzco's Face!"),0,0)
18 img = gui.Image("cuzco.png")
20 def myfnc(_event,_widget,_code,a,b,c):
21 print(_event,_widget,_code,a,b,c)
23 img.value.fill((255,0,0),(pos[0],pos[1],2,2))
26 t.td(gui.Label(str(("point at ",pos))))
29 #box.set_vertical_scroll()
31 img.connect(gui.CLICK,myfnc,1,2,3)
36 box = gui.ScrollArea(t,300,240)
42 prog = gui.ProgressBar(10,0,40,width=200)
45 app.connect(gui.QUIT,app.quit,None)