Hi.
I try to export QwtPlot to png file. I use this function
void XTrendViewer::makeExport( const QString& fileName )
{
pixmap.fill();
painter.drawPicture( 0,0, picture );
painter.end();
pixmap.save( fileName );
}
void XTrendViewer::makeExport( const QString& fileName )
{
QPicture picture;
QwtPlot::print( picture );
QPixmap pixmap( 800, 600 );
pixmap.fill();
QPainter painter( &pixmap );
painter.drawPicture( 0,0, picture );
painter.end();
pixmap.save( fileName );
}
To copy to clipboard, switch view to plain text mode
But I am getting file with white space without image. How to export/save qwtPlot into png, jpg and etc.
Bookmarks