ListCtrl flicker when updating quickly

Hi Guys,

I saw this wxPython question over on StackOverflow about a fellow trying to update a ListCtrl quickly and it flickering. I told him to try Freeze/Thaw, but that has no effect. He has a small runnable example posted. Hopefully someone here will know the answer. Here’s the link: http://stackoverflow.com/q/12967703/393194

  • Mike

What is the use case to have an update speed of 10 ms with lots of message per update? Maybe make the update interval something readable by a user, i.e. at 200 ms there is basically no more flicker and I can more or less follow what is being thrown at me.

Probably not the answer Paul wants:-( .

As this is to monitor some "bus" I would think it is not that useful to throw the data at a listctrl and expect a user to be able to follow it, maybe the bus data should be written to something and then the user can walk through this something with a listctrl with a next/prev button or show me next 10 until I hit stop and then use next/prev button or ..........

Werner

···

On 22/10/2012 15:27, Mike Driscoll wrote:

Hi Guys,

I saw this wxPython question over on StackOverflow about a fellow trying to update a ListCtrl quickly and it flickering. I told him to try Freeze/Thaw, but that has no effect. He has a small runnable example posted. Hopefully someone here will know the answer. Here's the link: wxPython listctrl flickers with rapid updates - Stack Overflow

Yeah, I thought that update speed was too quick too. I ran his code and you can’t really read the display as it’s changing so fast.

  • Mike
···

On Mon, Oct 22, 2012 at 9:59 AM, Werner werner.bruhin@sfr.fr wrote:

On 22/10/2012 15:27, Mike Driscoll wrote:

Hi Guys,

I saw this wxPython question over on StackOverflow about a fellow trying to update a ListCtrl quickly and it flickering. I told him to try Freeze/Thaw, but that has no effect. He has a small runnable example posted. Hopefully someone here will know the answer. Here’s the link: http://stackoverflow.com/q/12967703/393194

What is the use case to have an update speed of 10 ms with lots of message per update? Maybe make the update interval something readable by a user, i.e. at 200 ms there is basically no more flicker and I can more or less follow what is being thrown at me.

Probably not the answer Paul wants:-( .

As this is to monitor some “bus” I would think it is not that useful to throw the data at a listctrl and expect a user to be able to follow it, maybe the bus data should be written to something and then the user can walk through this something with a listctrl with a next/prev button or show me next 10 until I hit stop and then use next/prev button or …

Werner

I eventually looked at this again and updated my StackOverflow post. In short solved by using self.SetDoubleBuffered(True) on the message wx.Panel. But a side effect is no column headers can be used (need wx.LC_NO_HEADER in style), otherwise the list is wiped out or flickers really badly when the mouse highlights the column name. I’m curious why but that’s maybe the subject of a another post.

Paul