(1) What are code tags?
(2) I am running wxPython version 2.8.4.0 (mac-ansi) under MacOsX darwin.
(3) I have implemented a work-around by running a loop in a separate thread that calls time.sleep(1) and fires off a custom wxPython event. But I'd still rather use wxTimer if at all possible....
User Profile
Collapse
-
I recommend this book: "wxPython in Action", by Noel Rappin and Robin Dunn. It takes you by the hand, step by step, is easy to read and has lots and lots of examples.Leave a comment:
-
wx.Timer in wxPython
I am using wx.Timer to update a clock on a wxPython display. The relevant lines of code look like this:
[CODE=python]
timer = wx.Timer(self, -1)
self.Bind(wx.EV T_TIMER, self.onTick, timer)
timer.Start(mil liseconds=1000, oneShot=False)
[/CODE]
where self.onTick(sel f.event) handles the event every second by printing "TICK".
This works on WindowsXP...Leave a comment:
-
wx.Timer in wxPython
I am using wx.Timer to update a clock on a wxPython display. The relevant lines of code look like this:
timer = wx.Timer(self, -1)
self.Bind(wx.EV T_TIMER, self.onTick, timer)
timer.Start(mil liseconds=1000, oneShot=False)
where self.onTick(sel f.event) handles the event every second by printing "TICK".
This works on WindowsXP but not on MacOSX. On MacOSX,...
No activity results to display
Show More
Leave a comment: