Closed picca closed 8 years ago
so it seems that all these signales moved from guiqwt.signals to guiqwt.baseplot.
So I just need to do
but it does not work
Using experimental 'pure Python' qwt API
Traceback (most recent call last):
File "/home/experiences/sixs/com-sixs/Fitnxs/Fitnxs3.2.py", line 21, in
what is the right way to use the signals now ?
The transition from guiqwt 2.3 to 2.4 will have to be documented and it will state that supporting PyQt5 forced me to switch from PyQt API 1 to API 2. So the old-style signals/slots (from PyQt4.QtCore import SIGNAL, SLOT) are no longer supported in guiqwt 2.4.
In other words, you have to switch to the new-style signals and slots: http://pyqt.sourceforge.net/Docs/PyQt4/new_style_signals_slots.html http://pyqt.sourceforge.net/Docs/PyQt5/pyqt4_differences.html#old-style-signals-and-slots
So, to make it work, you have to do something like this (it's actuall simpler because you have nothing to import): plot.SIG_ACTIVE_ITEM_CHANGED.connect(func_name) # where plot is the BasePlot instance and func_name the slot function
I'll close this issue as soon as this change is well documented.
thanks for your help :)
Done.
See here: http://pythonhosted.org/guiqwt/migrating_from_v2_to_v3.html
Hello,
I am testing on of our application with the new guiqwt, but I get this error message.
Using experimental 'pure Python' qwt API Traceback (most recent call last): File "/home/experiences/sixs/com-sixs/Fitnxs/Fitnxs3.2.py", line 21, in
from guiqwt.signals import (SIG_ACTIVE_ITEM_CHANGED,SIG_START_TRACKING,
ImportError: cannot import name SIG_ACTIVE_ITEM_CHANGED