Problems using the qt5 toolkit

1,096 views
Skip to first unread message

Thomas Haslwanter

unread,
Sep 1, 2016, 1:47:50 PM9/1/16
to WinPython
Hi,
Running IPython Qt Console.exe in WinPython-64bit-3.5.2.2Qt5 I run into the following problem:

What works:

import numpy as np
import matplotlib.pyplot as plt
plt.plot(np.arange(5))
plt.show()
%matplotlib tk
plt.plot(np.arange(5))
%matplotlib inline
plt.plot(np.arange(5))

In other words, I can generate inline plots, as well as plots with the tk-framework. However, if I try

%matplotlib qt5

I get the error message

Warning: Cannot change to a different GUI toolkit: qt5. Using tk instead.

In contrast, in 
WinPython-64bit-3.5.2.2 I can switch to qt4 without problems.

Could someone please explain to me why the qt5 toolkit is not supported in WinPython-64bit-3.5.2.2Qt5 ? Or in other words: what is the advantage of the WinPython-64bit-3.5.2.2Qt5 build over the WinPython-64bit-3.5.2.2 build?

Thanks, Thomas

stonebig

unread,
Sep 1, 2016, 3:13:28 PM9/1/16
to WinPython
procedure:

open google
type the error message
  failed between NavigationToolbar2QT.message[str] and _show_message() 
click on first proposed (not commercial) link
follow the answer ...
tacaswell closed this on 31 Jul
... solved in coming Matplotlib2.0.0b4 (not yet released by Matplotlib)

==> Next release will be with Matplolib 2.0.0b4 or higher

stonebig

unread,
Sep 1, 2016, 3:17:47 PM9/1/16
to WinPython
if you follow the fix, there is only one file changed: Lib\site-packages\matplotlib\backends\backend_qt5.py
==> you may try just to replace it in your winPython

stonebig

unread,
Sep 1, 2016, 3:21:31 PM9/1/16
to WinPython
it doesn't work, you have to wait beta 4

stonebig

unread,
Sep 3, 2016, 2:40:30 PM9/3/16
to WinPython
This default of Quality of current PyQt5 implementation is for me a sign that the community at large is trying to keep afloat too much technologies at the same time:
- the old: Python 2.7, Qt4,
- the new necessary: Python 3.5, Qt5.7 (which is truly a breaking change on Windows),
- the next: Jupyterlab, Web compilation (forgot the name), android, ...

==> The drop of Python2.7 in next Jupyter and Pandas version will hopefully help.
==> Maybe PyQt4 support should also be dropped by Jupyter next version.
Reply all
Reply to author
Forward
0 new messages