Xlib async question

Oh, no. It's another async Xlib problem:
   Xlib: unexpected async reply (sequence 0x25ae)!

My code is very similar to the threading at:
   http://wiki.wxpython.org/index.cgi/LongRunningTasks

One big difference is that my worker thread invokes wxPostEvent()
several times in its run() method, whereas the example on the wiki page
just does one. I tried using addPendingEvent() in place of
wxPostEvent(), with no result.

Another difference is that my worker thread is invoking
someImage.convertToBitmap(). Is it possible that convertToBitmap()
involves Xlib calls, which then interfere with the GUI thread?

I'm just curious. I got the program working using events and yield in
place of threading. So the panel adds a pending event and then in the
handler invokes wx.Yield() followed by adding another event if needed.
Works fine.

···

--
Chuck
http://ChuckEsterbrook.com

Hello,

Another difference is that my worker thread is invoking
someImage.convertToBitmap(). Is it possible that convertToBitmap()
involves Xlib calls, which then interfere with the GUI thread?

I think that this is definitely the case.

Alberto

Alberto Griggio wrote:

Hello,

Another difference is that my worker thread is invoking someImage.convertToBitmap(). Is it possible that convertToBitmap() involves Xlib calls, which then interfere with the GUI thread?

I think that this is definitely the case.

It is. In order to make a bitmap compatible with the display it has to make Xlib calls.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!