Elmer and qwt 6.1

Discussion about building and installing Elmer
Post Reply
jeromeB
Posts: 5
Joined: 16 Sep 2013, 13:36
Antispam: Yes

Elmer and qwt 6.1

Post by jeromeB »

It seems that current version of elmer was written for qwt 6.0. But on my system I have qwt 6.1 and there are some minor change in the API so here is the patch if anyone needs to compile it as well with the newer qwt version:

Code: Select all

--- convergenceview.h.orig      2013-09-13 20:10:09.539590093 +0100
+++ convergenceview.h   2013-09-16 11:08:27.189942680 +0100
@@ -112,7 +112,7 @@
   QwtPlot *plot;
   QwtPlotGrid *grid;
   QwtLegend *legend;
-  QwtLog10ScaleEngine *scaleEngine;
+  QwtLogScaleEngine *scaleEngine;

   QHash<QString, Curve*> curveList;
   QPen *pen;
--- convergenceview.cpp.orig       2013-09-13 20:10:09.539590093 +0100
+++ convergenceview.cpp 2013-09-16 11:16:34.029939632 +0100
@@ -108,8 +108,8 @@
   // grid
   grid = new QwtPlotGrid;
   grid->enableXMin(true);
-  grid->setMajPen(QPen(Qt::black, 0, Qt::DotLine));
-  grid->setMinPen(QPen(Qt::gray, 0 , Qt::DotLine));
+  grid->setMajorPen(QPen(Qt::black, 0, Qt::DotLine));
+  grid->setMinorPen(QPen(Qt::gray, 0 , Qt::DotLine));
   grid->attach(plot);

   // axis
@@ -121,7 +121,7 @@
   plot->setAxisMaxMinor(QwtPlot::yLeft, 10);

   // scale engine
-  scaleEngine = new QwtLog10ScaleEngine;
+  scaleEngine = new QwtLogScaleEngine(10);
   plot->setAxisScaleEngine(QwtPlot::yLeft, scaleEngine);

   // default pen
mrceresa
Posts: 18
Joined: 11 Jan 2013, 21:18
Antispam: Yes

Re: Elmer and qwt 6.1

Post by mrceresa »

Thanks Jerome, that solved my problem building Elmer on Fedora 20.

Best,

Mario
Post Reply