QT backend bug + patch

Hi all!

The QT backend (backend_qt.py) does not enter QT's event loop when
multiple figures were created. It works fine with a single figure
though.

I have tested this with Suse Linux 10.2.
matplotlib.__version__ : 0.90.1

I have attached a little test program that illustrates the bug: When
this program is run, two windows will appear for a split second, and
the program finishes immediately.
When lines 10 and 11 are commented out, the program works as expected:
One window with a figure appears, and the program finishes when the
window is closed.

The attached patch fixes this bug. It is against the current HEAD in
trunk.

From reading the code, the exact same fix should be done in the QT4

backend.

Regards,
Eike.

mpl-test.py (278 Bytes)

backend_qt.diff (1.21 KB)

Sorry, I've sent a corrupted patch. This one should work.

Regards,
Eike.

backend_qt.diff (1.11 KB)

Thank you for the report and for solving the problem. I applied your fix to
backend_qt and backend_qt4 in svn-3879.

Darren

ยทยทยท

On Saturday 22 September 2007 08:06:56 pm Eike Welk wrote:

Hi all!

The QT backend (backend_qt.py) does not enter QT's event loop when
multiple figures were created. It works fine with a single figure
though.

I have tested this with Suse Linux 10.2.
matplotlib.__version__ : 0.90.1

I have attached a little test program that illustrates the bug: When
this program is run, two windows will appear for a split second, and
the program finishes immediately.
When lines 10 and 11 are commented out, the program works as expected:
One window with a figure appears, and the program finishes when the
window is closed.

The attached patch fixes this bug. It is against the current HEAD in
trunk.

>From reading the code, the exact same fix should be done in the QT4

backend.