]>
git.saurik.com Git - wxWidgets.git/blob - wxPython/samples/wxPIA_book/Chapter-07/gauge.py
3 class GaugeFrame(wx
.Frame
):
5 wx
.Frame
.__init
__(self
, None, -1, 'Gauge Example',
7 panel
= wx
.Panel(self
, -1)
9 self
.gauge
= wx
.Gauge(panel
, -1, 50, (20, 50), (250, 25))
10 self
.gauge
.SetBezelFace(3)
11 self
.gauge
.SetShadowWidth(3)
12 self
.Bind(wx
.EVT_IDLE
, self
.OnIdle
)
14 def OnIdle(self
, event
):
15 self
.count
= self
.count
+ 1
18 self
.gauge
.SetValue(self
.count
)
20 if __name__
== '__main__':
21 app
= wx
.PySimpleApp()