Answer the question
In order to leave comments, you need to log in
Working with Qwt, why does the application crash?
I have an application using Qwt that terminates unexpectedly. Business happens under ArchLinux.
Here is an example code:
// plot.h
#include <QWidget>
#include <qwt/qwt_plot.h>
class Plot : public QWidget {
Q_OBJECT
public:
Plot(QWidget *parent = 0);;
private:
QwtPlot *pPlot;
};
//plot.cpp
#include "plot.h"
Plot::Plot(QWidget *parent) : QWidget(parent) {
pPlot = new QwtPlot(this);
}
//main
#include "widgetview.h"
#include <QApplication>
#include "plot.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
Plot plot;
return a.exec();
}
INCLUDEPATH += /usr/include/qwt
LIBS += -lqwt
Answer the question
In order to leave comments, you need to log in
If we fall before entering main, then this means that most likely so did not catch up at startup. I didn’t work in ArchLinux, so I don’t know what could interfere with it. everything worked like clockwork in Ghent.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question