Hi,
Can I use Qwt whit Microsoft compiler?
I use Qt 4.8.5 and Microsoft Visual C++ Compiler 10.0 (x86)
It requires "qwt.lib". But I don't know how to create "qwt.lib".
Thank you!
Hi,
Can I use Qwt whit Microsoft compiler?
I use Qt 4.8.5 and Microsoft Visual C++ Compiler 10.0 (x86)
It requires "qwt.lib". But I don't know how to create "qwt.lib".
Thank you!
yes of course you can.
I can send you by mail a complete description of the procedure, just drop me your email account name.
Alain
8Observer8 (5th August 2013)
Thank you!
8observer8@gmail.com
I try to run an example.
plot.pro
Qt Code:
SOURCES += \ main.cpp CONFIG += qwt QWT_LOCATION = c:/Qwt-6.1.0 INCLUDEPATH += $${QWT_LOCATION}/include LIBS = -L$${QWT_LOCATION}/lib \ -lqwtdTo copy to clipboard, switch view to plain text mode
main.cpp
Qt Code:
#include <QtGui\QApplication> #include <qwt_plot.h> int main(int argc, char* argv[]) { // this is a simple plot without any data! myPlot->setTitle("my first plot"); myPlot->show(); return app.exec(); }To copy to clipboard, switch view to plain text mode
Output:
What should be in qwtconfig.pri? "CONFIG += QwtDll" or "#CONFIG += QwtDll"? or no difference?QWidget: Must construct a QApplication before a QPaintDevice
D:\Documents\Qt\HelloPlot\build-HelloPlot-Microsoft_Visual_C-Debug\debug\HelloPlot.exe exited with code 1
I use:
- Visual Studio Command Prompt (2010)
- Qt4.8.5
- Qwt-6.1.0
- Compiler: Microsoft Visual C++ Compiler 10.0 (x86)
qwtconfig.pri is for building Qwt itself, not for building an application using Qwt.
Almost everything above shows that you didn't read: http://qwt.sourceforge.net/qwtinstall.html.
Uwe
I mean when I install Qwt Should I to comment out this line: CONFIG += QwtDll
Depends on if you want to build Qwt as a shared or as a static library. See http://en.wikipedia.org/wiki/Library_%28computing%29
Uwe
8Observer8 (5th August 2013)
Why my example doesn't work? I did everything according to the instructions.
Remove the lines 6-9 from your plot.pro ( expanding the include path and library list is done by CONFIG += qwt ! ) and recompile from scratch.
If your code doesn't compile because of not finding Qwt headers you didn't configure qmake properly and "CONFIG += qwt" didn't work, what could be the reason for problem above.
Uwe
8Observer8 (5th August 2013)
How to configure qmake properly?
8Observer8 (5th August 2013)
Bookmarks