• 5588阅读
  • 4回复

Qwt编译后的程序打不开 [复制链接]

上一主题 下一主题
离线tfangxin
 
只看楼主 倒序阅读 楼主  发表于: 2011-03-24
刚刚开始学习qwt编译了几行代码 发现程序中使用qwt的类 编译成功后生成的exe打不开 请教是什么原因
int main(int argc, char **argv)
{
    QApplication a(argc, argv);

    QwtPlot plot;
    plot.setAxisScale(QwtPlot::xBottom, 0.0, 10.0);
    plot.setAxisScale(QwtPlot::yLeft, -1.0, 1.0);

    QwtPlotCurve *curve = new QwtPlotCurve("y = sin(x)");
    curve->setData(SinusData());
    curve->attach(&plot);

    plot.show();
    return a.exec();
}

又程序中只要有qwt的类 应用程序就无法打开 如下。将QwtSlider行注释就可以打开
QLabel *label = new QLabel(tr("label"), this);
QPushButton *btn = new QPushButton(tr("click"), this);
QwtSlider *slider = new QwtSlider( this,  Qt::Horizontal, QwtSlider::TopScale, QwtSlider::BgTrough);

QVBoxLayout *layout = new QVBoxLayout;
layout->addWidget(label);
layout->addWidget(btn);
setLayout(layout);
离线wxj120bw

只看该作者 1楼 发表于: 2011-03-24
想知道打不开 提示什么错误
离线tfangxin
只看该作者 2楼 发表于: 2011-03-25
没有什么错误 成功编译的 就是编译后的exe打不开
离线wxj120bw

只看该作者 3楼 发表于: 2011-03-25
就想知道打不开程序提示什么错误,该弹个对话框吧
离线ahn168
只看该作者 4楼 发表于: 2011-05-16
我移植的时候也碰到这个问题,一碰到跟qwt相关的程序就打不开,任何错误提示都没有。。。在PC上编译x86版的就很正常,哎。。。
快速回复
限100 字节
 
上一个 下一个