GithubHelp home page GithubHelp logo

pyqt-qwt's People

Contributors

gauistori avatar mitya57 avatar rizzoa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pyqt-qwt's Issues

sip build issues - multiple deleted function errors

sip build of the v1.02.02 via the Arch Linux AUR
Build instructions - PKGBUILD
The full build log is attached - python-pyqt-qwt-1.02.02-1-x86_64-build.log

TL/DR multiple errors due to usage of deleted functions:

make[1]: *** [Makefile:829: sipQwtQwtPowerTransform.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: *** [Makefile:837: sipQwtQwtNullTransform.o] Error 1
make[1]: *** [Makefile:833: sipQwtQwtLogTransform.o] Error 1
make[1]: *** [Makefile:841: sipQwtQwtTransform.o] Error 1
make[1]: *** [Makefile:825: sipQwtQwtDialNeedle.o] Error 1
make[1]: *** [Makefile:817: sipQwtQwtCompassMagnetNeedle.o] Error 1
make[1]: *** [Makefile:813: sipQwtQwtCompassWindArrow.o] Error 1
make[1]: *** [Makefile:797: sipQwtQwtCompassScaleDraw.o] Error 1
sip-build: 'make' failed returning 2
make[1]: *** [Makefile:821: sipQwtQwtDialSimpleNeedle.o] Error 1
make[1]: *** [Makefile:801: sipQwtQwtSimpleCompassRose.o] Error 1
make[1]: *** [Makefile:805: sipQwtQwtCompassRose.o] Error 1
make[1]: Leaving directory '/build/python-pyqt-qwt/src/PyQt-Qwt-1.02.02/build/Qwt'
make: *** [Makefile:47: sub-Qwt-make_first-ordered] Error 2

I am receiving the same build errors when building from the latest commit in the master branch.

Compatibility with sip <= 4.19.8

Hi Gudjon, and thanks again for your work on issue #4

here is another questionning we have with PyQt-Qwt :

since the latest sip version released on PIPY is sip 4.19.8, it would be convenient for us that PyQt-Qwt compiles with this version. The need for sip >= 4.19.11 seems to complexify the deployment of packages using PyQt-Qwt, and I'm not sure about the reason of this requirement.

Moreover, if you plan to publish one day the PyQt-Qwt on PIPY, I think it will be easier with a sip version available on PIPY.

I tried to compile and quickly test PyQt-Qwt with sip 4.19.8, and just had to remove the sip -n (new in sip 4.19.9) argument in the configure.py script to make it work.

In my opinion, a good change in the configure script for PyQt-Qwt would be to replace this line :

argv.append('-n sip')

by this :

    # -n arg new in sip 4.19.9
    if target_config.sip_version >= version_from_string("4.19.9"):
        argv.append('-n sip')

What do you think about this ? I can prepare a pullrequest if you like.

Thanks again,

Regards,

Olivier

why is drawSymbols in qwtPlotCurve commented out?

In sip/qwt_plot_curve.sip you have commented out the drawSymbols function (lines 238 to 240). Why is that? I make use of drawSymbols in one of my test programs and could not figure out why i could call it in the earlier PyQwt 5.2 and not in your version (!) until I looked at your sip code.

This issue is not that critical as I don't appear to be using the function anywhere in production code but just in a test program I wrote.

Thanks

Tony

Compile Error

I tried building the project and ran into some build issues
Configuration output:

ekigwana@test ~/PyQt-Qwt $ python configure.py --qwt-incdir=/usr/include/qwt6/
/usr/include/qwt6
Configuring Qwt 6.1.3...
Qwt 6.1.3 is being used.
The Qwt .sip files will be installed in
/usr/lib/python-exec/python2.7/../../../share/sip/PyQt5.
Qwt will be installed in /usr/lib64/python2.7/site-packages/PyQt5.
PyQt 5.10.1 is being used.
Qt 5.10.1 is being used.
sip 4.19.8 is being used.
The sip executable is /usr/bin/sip.
Qwt is being built with 'protected' redefined as 'public'.
The PEP 484 stubs will be installed in
/usr/lib64/python2.7/site-packages/PyQt5.
The Qwt API file will be installed in /usr/share/qt5/qwt/api/python.
Generating the C++ source for the Qwt module...
Generating the .pro file for the Qwt module...
Generating the Qwt API file...
Generating the top-level .pro file...
Generating the Makefiles...

Build output:

g++ -c -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQWT_PYTHON_WRAPPER -DQWT_DLL -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -isystem /usr/include/qwt6 -isystem /usr/include/python2.7 -isystem /usr/include/python2.7 -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtSvg -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtCore -I. -isystem /usr/include/libdrm -I/usr/lib64/qt5/mkspecs/linux-g++ -o sipQwtQwtSeriesStoreQwtSetSample.o sipQwtQwtSeriesStoreQwtSetSample.cpp
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtSetSample.cpp: In function ‘void* array_QwtSeriesStoreQwtSetSample(Py_ssize_t)’:
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtSetSample.cpp:363:55: error: invalid new-expression of abstract class type ‘QwtSeriesStore<QwtSetSample>’
     return new  ::QwtSeriesStoreQwtSetSample[sipNrElem];
                                                       ^
In file included from sip/qwt_series_store.sip:68:0:
/usr/include/qwt6/qwt_series_store.h:57:7: note:   because the following virtual functions are pure within ‘QwtSeriesStore<QwtSetSample>’:
 class QwtSeriesStore: public virtual QwtAbstractSeriesStore
       ^~~~~~~~~~~~~~
/usr/include/qwt6/qwt_series_store.h:31:18: note:       virtual void QwtAbstractSeriesStore::dataChanged()
     virtual void dataChanged() = 0;
                  ^~~~~~~~~~~
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtSetSample.cpp: In function ‘void* copy_QwtSeriesStoreQwtSetSample(const void*, Py_ssize_t)’:
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtSetSample.cpp:370:120: error: invalid new-expression of abstract class type ‘QwtSeriesStore<QwtSetSample>’
     return new  ::QwtSeriesStoreQwtSetSample(reinterpret_cast<const  ::QwtSeriesStoreQwtSetSample *>(sipSrc)[sipSrcIdx]);
                                                                                                                        ^
make[1]: [Makefile:1475: sipQwtQwtSeriesStoreQwtSetSample.o] Error 1 (ignored)
g++ -c -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQWT_PYTHON_WRAPPER -DQWT_DLL -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -isystem /usr/include/qwt6 -isystem /usr/include/python2.7 -isystem /usr/include/python2.7 -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtSvg -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtCore -I. -isystem /usr/include/libdrm -I/usr/lib64/qt5/mkspecs/linux-g++ -o sipQwtQwtSeriesStoreQwtIntervalSample.o sipQwtQwtSeriesStoreQwtIntervalSample.cpp
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtIntervalSample.cpp: In function ‘void* array_QwtSeriesStoreQwtIntervalSample(Py_ssize_t)’:
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtIntervalSample.cpp:363:60: error: invalid new-expression of abstract class type ‘QwtSeriesStore<QwtIntervalSample>’
     return new  ::QwtSeriesStoreQwtIntervalSample[sipNrElem];
                                                            ^
In file included from sip/qwt_series_store.sip:28:0:
/usr/include/qwt6/qwt_series_store.h:57:7: note:   because the following virtual functions are pure within ‘QwtSeriesStore<QwtIntervalSample>’:
 class QwtSeriesStore: public virtual QwtAbstractSeriesStore
       ^~~~~~~~~~~~~~
/usr/include/qwt6/qwt_series_store.h:31:18: note:       virtual void QwtAbstractSeriesStore::dataChanged()
     virtual void dataChanged() = 0;
                  ^~~~~~~~~~~
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtIntervalSample.cpp: In function ‘void* copy_QwtSeriesStoreQwtIntervalSample(const void*, Py_ssize_t)’:
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQwtIntervalSample.cpp:370:130: error: invalid new-expression of abstract class type ‘QwtSeriesStore<QwtIntervalSample>’
     return new  ::QwtSeriesStoreQwtIntervalSample(reinterpret_cast<const  ::QwtSeriesStoreQwtIntervalSample *>(sipSrc)[sipSrcIdx]);
                                                                                                                                  ^
make[1]: [Makefile:1655: sipQwtQwtSeriesStoreQwtIntervalSample.o] Error 1 (ignored)
g++ -c -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQWT_PYTHON_WRAPPER -DQWT_DLL -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -isystem /usr/include/qwt6 -isystem /usr/include/python2.7 -isystem /usr/include/python2.7 -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtSvg -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtCore -I. -isystem /usr/include/libdrm -I/usr/lib64/qt5/mkspecs/linux-g++ -o sipQwtQwtSeriesStoreQPointF.o sipQwtQwtSeriesStoreQPointF.cpp
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQPointF.cpp: In function ‘void* array_QwtSeriesStoreQPointF(Py_ssize_t)’:
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQPointF.cpp:363:50: error: invalid new-expression of abstract class type ‘QwtSeriesStore<QPointF>’
     return new  ::QwtSeriesStoreQPointF[sipNrElem];
                                                  ^
In file included from sip/qwt_series_store.sip:48:0:
/usr/include/qwt6/qwt_series_store.h:57:7: note:   because the following virtual functions are pure within ‘QwtSeriesStore<QPointF>’:
 class QwtSeriesStore: public virtual QwtAbstractSeriesStore
       ^~~~~~~~~~~~~~
/usr/include/qwt6/qwt_series_store.h:31:18: note:       virtual void QwtAbstractSeriesStore::dataChanged()
     virtual void dataChanged() = 0;
                  ^~~~~~~~~~~
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQPointF.cpp: In function ‘void* copy_QwtSeriesStoreQPointF(const void*, Py_ssize_t)’:
/home/ekigwana/PyQt-Qwt/Qwt/sipQwtQwtSeriesStoreQPointF.cpp:370:110: error: invalid new-expression of abstract class type ‘QwtSeriesStore<QPointF>’
     return new  ::QwtSeriesStoreQPointF(reinterpret_cast<const  ::QwtSeriesStoreQPointF *>(sipSrc)[sipSrcIdx]);

zoomStack and setZoomStack calls are missing

Firstly, thank you for this awesome work for getting Qwt6 working with PyQt5!

I noticed that zoomStack and setZoomStack calls are missing. I can see the following in the respective sip file:

//const QStack<QRectF> &zoomStack() const; FIXME
//void setZoomStack( const QStack<QRectF> &, int zoomRectIndex = -1 ); FIXME

Are there any plans to get this included, or is there a known workaround?

Any help would be very much appreciated.

Error when installing from master branch

Hi Gudjon

When running the following QT_SELECT=qt5 python3 configure.py --qwt-incdir=/usr/include/qwt --qwt-libdir=/usr/lib --qwt-lib=qwt-qt5 on Ubuntu 20.04 with Qwt 6.1.4 or Gentoo with Qwt 6.1.5, I get the following error:

An internal error occured.  Please report all the output from the program,
including the following traceback, to gudjon@gudjon.org.
Traceback (most recent call last):
  File "configure.py", line 2067, in <module>
    _main(sys.argv, pkg_config)
  File "configure.py", line 1909, in _main
    pkg_config.check_package(target_config)
  File "configure.py", line 245, in check_module
    mod_version_numeric = int(mv[0])*10000 + int(mv[1])*100 + int(mv[2])
ValueError: invalid literal for int() with base 10: '0beta0'

If I remove 'beta' from the following, then everything compiles and works fine:

configure.py:    version = '2.0.0beta0'

Cheers,
Raz

QwtLog10ScaleEngine wraper needed

Hi

I have a huge code base that makes use of the last PyQwt wrapper that Gerard Vermeulen made for the old Python 4 / Qwt 4 stuff. I'm now faced with the task of porting the code base to Python 3 / qt 5 / Qwt 6 etc. One of the axis scale functions i need is QwtLog10ScaleEngine. It looks like you have not yet included that in your distribution and I'd be grateful if you could add it.

Thanks

Tony

Compile error

Installed version of qwt: current version (r2523), using Qt 4.8.4, sip 4.15.5

after 'python configure.py' and calling make I got:

./sipQwtQwtAlphaColorMap.cpp: In member function ‘QVector sipQwtAlphaColorMap::colorTable(const QwtInterval&) const’:
./sipQwtQwtAlphaColorMap.cpp:69:47: error: no matching function for call to ‘sipQwtAlphaColorMap::colorTable(const QwtInterval&) const’
return QwtAlphaColorMap::colorTable(a0);
^
./sipQwtQwtAlphaColorMap.cpp:69:47: note: candidate is:
In file included from qwt_color_map.sip:82:0:
/home/jkrueger/qwt/include/qwt_color_map.h:79:27: note: virtual QVector QwtColorMap::colorTable(int) const
virtual QVector colorTable( int numColors ) const;
^
/home/jkrueger/qwt/include/qwt_color_map.h:79:27: note: no known conversion for argument 1 from ‘const QwtInterval’ to ‘int’
make: *** [sipQwtQwtAlphaColorMap.o] Error 1

After having a look into the code and qwt code I found out that the Qwt call to the colorTable has an integer parameter now.

Accessing the QwtPlotCanvas of a QwtPlot via the canvas() getter returns a QFrame object

Hi, and thanks for this useful project.

We experience a problem to access the setFocusIndicator method of a QwtPlot's canvas.
The object returned from canvas() is a QFrame even though the underlying C++ object is a QwtPlotCanvas.

It seems that the sipConvertFromType method does not manage to convert a QObject to a QwtPlotCanvas one, but stops at the QFrame subclass (may be because this is the "border" between PyQt classes and PyQt-Qwt classes in the inheritance path ?).

here is a simple script to reproduce :

from PyQt5.Qwt import QwtPlot, QwtPlotCanvas

from PyQt5.QtWidgets import QApplication

class BasePlot(QwtPlot):

    def __init__(self, parent=None):
        super(BasePlot, self).__init__(parent)
        cv = self.canvas()
        cv.setFocusIndicator(QwtPlotCanvas.ItemFocusIndicator)


app = QApplication([])
myPlot = BasePlot()

an exception is thrown :

Traceback (most recent call last):
File "C:/Dvp/Projets/tmp/minqwt/test.py", line 14, in
myPlot = BasePlot()
File "C:/Dvp/Projets/tmp/minqwt/test.py", line 10, in init
cv.setFocusIndicator(QwtPlotCanvas.ItemFocusIndicator)
AttributeError: 'QFrame' object has no attribute 'setFocusIndicator'

If we create a QwtPlotCanvas like this, there is no problem, though :

from PyQt5.Qwt import QwtPlot, QwtPlotCanvas

from PyQt5.QtWidgets import QApplication

class BasePlot(QwtPlot):

    def __init__(self, parent=None):
        super(BasePlot, self).__init__(parent)
        cv = QwtPlotCanvas()
        cv.setFocusIndicator(QwtPlotCanvas.ItemFocusIndicator)
        self.setCanvas(cv)


app = QApplication([])
myPlot = BasePlot()

It may be more of a SIP question, but is there a way to tell SIP to try and convert the canvas QWidget to a QwtPlotCanvcas if needed ?

Best regards

QWT widgets will not import from Qt5 designer

On the Raspberry pi trying to import QWT widgets from a ".ui" designer file into a python 3 script results in an import error (for example);

Traceback (most recent call last):
File "/home/pi/Google Drive/PythonCode/Google_API/WidgetTest.py", line 10, in
Ui_MainWindow, QtBaseClass = uic.loadUiType(DesignerFile)
File "/usr/lib/python3/dist-packages/PyQt5/uic/init.py", line 201, in loadUiType
exec(code_string.getvalue(), ui_globals)
File "", line 67, in
ImportError: No module named 'qwt_analog_clock'

Notes: Widgets can be generated in the python script but not imported through .ui
Pi distribution is Raspberian "Stretch"
Python version is 3.5.3
QT Designer version = 5.7.1
PyQt5 version is 5.7+dfsg-5
Sip Version is 4.18.1+dfsg-2

Python Script;

#!/usr/bin/env python3
import sys
from PyQt5 import Qwt
from PyQt5.QtWidgets import *
from PyQt5 import uic
DesignerFile = "QWTwidgetTest.ui"
app = QApplication(sys.argv)
Ui_MainWindow, QtBaseClass = uic.loadUiType(DesignerFile)
ui = Ui_MainWindow()
window = QMainWindow()
ui.setupUi(window)
window.show()
sys.exit(app.exec_())

image

Performance of QwtPlotCurve.setSamples

Hi again,

this is not a bug but a performance improvement proposition.

I often need for my applications to display data changing over time, like in this simple example :

#!/usr/bin/python

import sys
from PyQt5 import Qwt
import numpy as np
from PyQt5.QtCore import Qt,  QSize, QTimer
from PyQt5.QtGui import QBrush, QPen
from PyQt5.QtWidgets import QApplication

import time
import numpy as np

NPOINTS = 500000
x = np.linspace(0., 4*np.pi, NPOINTS)
NB_FRAMES_FOR_MEAN_FPS = 10

class TestApp(QApplication):

	def __init__(self, argv):
		super(QApplication, self).__init__(argv)
	
		self.last_phase = 0
		self.last_time = time.time();
		self.count = 0;
	
	def updateDataToDraw(self):
		self.last_phase = (self.last_phase + np.pi / 16) % (2 * np.pi)
		
		y=np.sin(x+self.last_phase)
		curve.setSamples(x,y)
		self.count=self.count+1
		if self.count%NB_FRAMES_FOR_MEAN_FPS == 0:
			current_time = time.time()
			print("FPS : " + str(NB_FRAMES_FOR_MEAN_FPS/(current_time - self.last_time)))
			self.last_time = current_time

a = TestApp(sys.argv)

plot=Qwt.QwtPlot()
plot.setAutoReplot()
curve = Qwt.QwtPlotCurve()

y=np.sin(x)
curve.setSamples(x,y)
curve.attach(plot)

plot.resize(600,400)
plot.replot()
plot.show()

timer = QTimer()
timer.timeout.connect(a.updateDataToDraw)
timer.start(1)

sys.exit(a.exec_())

This prints on my computer a number of displayed frames per second of ~9fps,which is quite less that the ~25fps I get writing the same example in C++.

This seems related to the QwtPlotCurve setSamples method wrapper, which takes as input two python iterables (variables x and y in the example), converts them to QVector<double> objects (which is a costly operation when we have a lot of points) and finally passes them to the real Qwt setSamples method.

One possible workaround would be to use a type which has a direct C++ <-> Python wrapper to pass the samples data and avoid this kind of performance hit : QPolygonF (which is just an explicit definition of the template type QVector<QPointF>).

So, using this code :

#!/usr/bin/python

import sys
from PyQt5 import Qwt
import numpy as np
from PyQt5.QtCore import Qt,  QSize, QTimer
from PyQt5.QtGui import QBrush, QPen, QPolygonF
from PyQt5.QtWidgets import QApplication

import time
import numpy as np

NPOINTS = 500000
x = np.linspace(0., 4*np.pi, NPOINTS)
NB_FRAMES_FOR_MEAN_FPS = 10

class TestApp(QApplication):

	def __init__(self, argv):
		super(QApplication, self).__init__(argv)
	
		self.last_phase = 0
		self.last_time = time.time();
		self.count = 0;
	
	def updateDataToDraw(self):
		self.last_phase = (self.last_phase + np.pi / 16) % (2 * np.pi)
		
		y=np.sin(x+self.last_phase)
		
		size = len(x)
		polyline = QPolygonF(size)

		pointer = polyline.data()
		dtype, tinfo = np.float, np.finfo
		pointer.setsize(2 * size * tinfo(dtype).dtype.itemsize)
		memory = np.frombuffer(pointer, dtype)
		memory[:(size - 1) * 2 + 1:2] = x
		memory[1:(size - 1) * 2 + 2:2] = y
		
		curve.setSamples(polyline)
		
		self.count=self.count+1
		if self.count%NB_FRAMES_FOR_MEAN_FPS == 0:
			current_time = time.time()
			print("FPS : " + str(NB_FRAMES_FOR_MEAN_FPS/(current_time - self.last_time)))
			self.last_time = current_time

a = TestApp(sys.argv)

plot=Qwt.QwtPlot()
plot.setAutoReplot()
curve = Qwt.QwtPlotCurve()

y=np.sin(x)
curve.setSamples(x,y)
curve.attach(plot)

plot.resize(600,400)
plot.replot()
plot.show()

timer = QTimer()
timer.timeout.connect(a.updateDataToDraw)
timer.start(1)

sys.exit(a.exec_())

and changing the sip file qwt_plot_curve.sip from this:

//#ifndef QWT_NO_COMPAT
    void setRawSamples( const double *xData, const double *yData, int size );
    void setSamples( const double *xData, const double *yData, int size );
    void setSamples( const QVector<double> &xData, const QVector<double> &yData );
    void setSamples( const QVector<QPointF> & );
    void setSamples( QwtSeriesDataQPointF * );

to this :

//#ifndef QWT_NO_COMPAT
    void setRawSamples( const double *xData, const double *yData, int size );
    void setSamples( const double *xData, const double *yData, int size );
    void setSamples( const QVector<double> &xData, const QVector<double> &yData );
    void setSamples( const QPolygonF & );
    void setSamples( const QVector<QPointF> & );
    void setSamples( QwtSeriesDataQPointF * );

we get a great performance increase of the example above (from ~9fps to ~21fps in my computer, much closer to the performance of the C++ only solution).

Note that the added line must not be added after the void setSamples( const QVector<QPointF> & ); line, so that the sip wrapper tests if the input is a QPolygonF before testing if it is a QVector<QPointF>, in which case we have even lower performance (the sip part still iterates over the QPolygonF input to create a QVector<QPointF>, and the python code that builds the QPolygonF takes additional time (compared to the first initial example) for nothing.

Do you think this little change to qwt_plot_curve.sip could be merged ? I know we would take a lot of benefits from this for our projects.

Thanks again (again),

best regards,
Olivier

Error: No module named qwt_*

Hello,
I have installed the repository correctly, under Ubuntu 20.04 and with Qt5. But I still having the same error:

ModuleNotFoundError: No module named 'qwt_thermo'

And the same for any qwt module.

How can I check if everything is correct?

Thank you.

Kinds regards

Ubuntu 18.04 installing problems

Hello GauiStori,

I'm trying to compile your package, but I'm having some problems from the beginning, hope you can help me with them.

All the PyQt packages are correctly installed, but when I try to remove the qwt-qt5 name extension, it says that the sip-build order is not found.

If I try to install sip manually ($sudo apt install sip-dev), it says that it is correctly installed.

Then, trying to do the next instruction, I had the same problem show in #20 , but it finishes with the next error:

Error: Unable to create the C++ code.

Please, could you guide me to install correctly your repo?

Thank you in advance.
Jorge

complize error

Configuring Qwt 6.1.2...
Qwt 6.1.3 is being used.
The Qwt .sip files will be installed in /usr/share/sip/PyQt5.
Qwt will be installed in /usr/lib/python3/dist-packages/PyQt5.
PyQt 5.15.0 is being used.
Qt 5.15.0 is being used.
sip 5.3.0 is being used.
The sip executable is /home/allen/.local/bin/sip5.
Qwt is being built with 'protected' redefined as 'public'.
The PEP 484 stubs will be installed in /usr/lib/python3/dist-packages/PyQt5.
Generating the C++ source for the Qwt module...
Error: Unable to create the C++ code.

Compile error

Traceback (most recent call last):
File "/Users/roy/Downloads/PyQt-Qwt-1.02.02/mk_distinfo.py", line 112, in
fn_f = open(fn, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: '/Users/roy/opt/anaconda3/qwt/api/python/Qwt.api'
make: *** [install_distinfo] Error 1

python configure.py Error: Unable to create the C++ code.

Hi,
Thank you for your work. Really appreciate that.

I want to use Qwt with PyQT5 on windows. Following your steps I met an error when running python configure.py. Just as the image below show, I added logs to watch parameters, seems that it didn't install Qwt API file.

I don't know if "self.api_dir: C:/Qt/Qt5.9.6/5.9.6/msvc2015_64\qwt" matters on my situation. But I tried to set it to path such as "C:\Qt\Qt5.9.6\5.9.6\msvc2015_64\qwt" and had no luck.

Would you please give me some advice if I missed anything. Many thanks.

image

pip installable wheels

this is more a question than an issue: I coudn't find your project on pypi.

Do you plan to add it, to avoid the need to rebuild the sources for the users?

Runtime error - undefined symbol: _ZTI14QwtAnalogClock

Related to post by @ekigwana in #3 (comment)

OS: Arch Linux 5.10.16-arch1-1 x86_64 GNU/Linux
PyQt-Qwt version: 1.02.02

Compile method:

sip-build --verbose --qwt-incdir=/usr/include/qwt --qwt-libdir=/usr/lib

I am getting the following runtime error when trying to execute any of the Qt 5 examples provided:

$ python animation.py 
Traceback (most recent call last):
  File "/home/user/chroot/pkgbuilds/pyqt-qwt/src/PyQt-Qwt-1.02.02/qt5examples/animation.py", line 6, in <module>
    from PyQt5 import Qwt
ImportError: /usr/lib/python3.9/site-packages/PyQt5/Qwt.cpython-39-x86_64-linux-gnu.so: undefined symbol: _ZTI14QwtAnalogClock

Listing out the symbols (dynamic), I can see it, though:

$ nm -D /usr/lib/python3.9/site-packages/PyQt5/Qwt.cpython-39-x86_64-linux-gnu.so | grep _ZTI14QwtAnalogClock
                 U _ZTI14QwtAnalogClock

Is there something I'm missing when compiling? I tried building PyQt-Qwt using Qwt with the patched headers but got the same runtime error subsequently.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.