Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix build with qwt 6.2, deprecation warning #3047

Merged
merged 6 commits into from
Jul 22, 2021

Conversation

scpeters
Copy link
Member

This is a quick fix for #3046, which will prevent compilation failures with qwt 6.2, which may be merged into homebrew-core soon.

This also fixes a deprecation warning by using Qt::MiddleButton instead of Qt::MidButton, which has been apparently commented as deprecated since Qt 4.7.0 ( qt/qtbase@16e546e ), so the recommended API should be usable on all our supported platforms.

scpeters added 2 commits July 20, 2021 04:12
Compilation is broken with qwt 6.2 without this fix.

Signed-off-by: Steven Peters <scpeters@openrobotics.org>
Signed-off-by: Steven Peters <scpeters@openrobotics.org>
@traversaro
Copy link
Collaborator

To validate the PR, I spawned a build with this patch against qwt 6.2.0 in conda-forge/gazebo-feedstock#87, let's see how it goes.

@traversaro
Copy link
Collaborator

traversaro commented Jul 20, 2021

Apparently even with this patches the compilation fails against qwt 6.2 :

2021-07-20T12:29:59.1345425Z FAILED: gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o 
2021-07-20T12:29:59.1355437Z $BUILD_PREFIX/bin/x86_64-conda-linux-gnu-c++  -DBOOST_ALL_NO_LIB -DBOOST_DATE_TIME_DYN_LINK -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_IOSTREAMS_DYN_LINK -DBOOST_PROGRAM_OPTIONS_DYN_LINK -DBOOST_REGEX_DYN_LINK -DBOOST_SYSTEM_DYN_LINK -DBOOST_TEST_DYN_LINK -DBOOST_THREAD_DYN_LINK -DBUILDING_DLL -DBUILDING_DLL_GZ_GUI -DHAVE_OPENGL -DHAVE_STRING_H -DIGN_PROFILER_ENABLE=0 -DLIBBULLET_VERSION=3.17 -DLIBBULLET_VERSION_GT_282 -DQGVCORE_LIB -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQWT_DLL -DWITH_CGRAPH -Dgazebo_gui_EXPORTS -Igazebo/gui/gazebo_gui_autogen/include -I../test/gtest/include -I../ -I. -I../deps -I../gazebo/gui/qgv -I../gazebo/gui/qgv/private -I$PREFIX/include/libusb-1.0 -I$PREFIX/include/graphviz -isystem $PREFIX/include/ignition/msgs5 -isystem $PREFIX/include/ignition/math6 -isystem $PREFIX/include/ignition/transport8 -isystem $PREFIX/include/ignition/common3 -isystem $PREFIX/include/ignition/fuel_tools4 -isystem $PREFIX/include/OGRE/RTShaderSystem -isystem $PREFIX/include/OGRE -isystem $PREFIX/include/OGRE/Terrain -isystem $PREFIX/include/OGRE/Paging -isystem $PREFIX/include/OGRE/Overlay -isystem $PREFIX/include/sdformat-9.3 -isystem $PREFIX/include/qt -isystem $PREFIX/include/qt/QtCore -isystem $PREFIX/./mkspecs/linux-g++ -isystem $PREFIX/include/uuid -isystem $PREFIX/include/sdformat-9.3/sdf/.. -isystem $PREFIX/include/ignition/cmake2 -isystem $PREFIX/include/qt/QtWidgets -isystem $PREFIX/include/qt/QtGui -fvisibility-inlines-hidden -std=c++17 -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -isystem $PREFIX/include -fdebug-prefix-map=$SRC_DIR=/usr/local/src/conda/gazebo-11.7.0 -fdebug-prefix-map=$PREFIX=/usr/local/src/conda-prefix       -Wall -Wextra -Wno-long-long -Wno-unused-value -Wfloat-equal -Wshadow -Wswitch-default -Wmissing-include-dirs -pedantic -fvisibility=hidden -fvisibility-inlines-hidden   -s -O3 -DNDEBUG -mssse3 -msse3 -mfpmath=sse -msse -msse2  -fPIC   -fPIC -I$PREFIX/include/uuid -fPIC -MD -MT gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o -MF gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o.d -o gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o -c ../gazebo/gui/plot/PlotCurve.cc
2021-07-20T12:29:59.1363506Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'virtual QRectF gazebo::gui::CurveData::boundingRect() const':
2021-07-20T12:29:59.1368487Z ../gazebo/gui/plot/PlotCurve.cc:58:27: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1372829Z    58 |                 if (this->d_boundingRect.width() < 0.0)
2021-07-20T12:29:59.1376823Z       |                           ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1380665Z       |                           boundingRect
2021-07-20T12:29:59.1385216Z ../gazebo/gui/plot/PlotCurve.cc:59:25: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1398818Z    59 |                   this->d_boundingRect = qwtBoundingRect(*this);
2021-07-20T12:29:59.1399373Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1399749Z       |                         boundingRect
2021-07-20T12:29:59.1400769Z ../gazebo/gui/plot/PlotCurve.cc:65:52: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1401533Z    65 |                 double absHeight = std::fabs(this->d_boundingRect.height());
2021-07-20T12:29:59.1401997Z       |                                                    ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1402435Z       |                                                    boundingRect
2021-07-20T12:29:59.1403172Z ../gazebo/gui/plot/PlotCurve.cc:69:38: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1403857Z    69 |                   double mid = this->d_boundingRect.top() +
2021-07-20T12:29:59.1404273Z       |                                      ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1404649Z       |                                      boundingRect
2021-07-20T12:29:59.1405374Z ../gazebo/gui/plot/PlotCurve.cc:71:25: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1406118Z    71 |                   this->d_boundingRect.setTop(mid - halfMinHeight);
2021-07-20T12:29:59.1406514Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1406876Z       |                         boundingRect
2021-07-20T12:29:59.1407570Z ../gazebo/gui/plot/PlotCurve.cc:72:25: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1408282Z    72 |                   this->d_boundingRect.setBottom(mid + halfMinHeight);
2021-07-20T12:29:59.1408694Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1409033Z       |                         boundingRect
2021-07-20T12:29:59.1409733Z ../gazebo/gui/plot/PlotCurve.cc:75:30: error: 'const class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1410405Z    75 |                 return this->d_boundingRect;
2021-07-20T12:29:59.1410785Z       |                              ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1411318Z       |                              boundingRect
2021-07-20T12:29:59.1411959Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'void gazebo::gui::CurveData::Add(const QPointF&)':
2021-07-20T12:29:59.1412792Z ../gazebo/gui/plot/PlotCurve.cc:82:23: error: 'class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1413567Z    82 |                 this->d_samples += _point;
2021-07-20T12:29:59.1413939Z       |                       ^~~~~~~~~
2021-07-20T12:29:59.1414294Z       |                       m_samples
2021-07-20T12:29:59.1414970Z ../gazebo/gui/plot/PlotCurve.cc:84:27: error: 'class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1415668Z    84 |                 if (this->d_samples.size() > maxSampleSize)
2021-07-20T12:29:59.1416068Z       |                           ^~~~~~~~~
2021-07-20T12:29:59.1416434Z       |                           m_samples
2021-07-20T12:29:59.1417128Z ../gazebo/gui/plot/PlotCurve.cc:88:25: error: 'class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1417821Z    88 |                   this->d_samples.remove(0, windowSize);
2021-07-20T12:29:59.1418232Z       |                         ^~~~~~~~~
2021-07-20T12:29:59.1418569Z       |                         m_samples
2021-07-20T12:29:59.1419264Z ../gazebo/gui/plot/PlotCurve.cc:91:27: error: 'class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1419934Z    91 |                 if (this->d_samples.size() == 1)
2021-07-20T12:29:59.1420320Z       |                           ^~~~~~~~~
2021-07-20T12:29:59.1420680Z       |                           m_samples
2021-07-20T12:29:59.1421378Z ../gazebo/gui/plot/PlotCurve.cc:94:25: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1422158Z    94 |                   this->d_boundingRect.setTopLeft(_point);
2021-07-20T12:29:59.1422573Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1422927Z       |                         boundingRect
2021-07-20T12:29:59.1423631Z ../gazebo/gui/plot/PlotCurve.cc:95:25: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1424330Z    95 |                   this->d_boundingRect.setBottomRight(_point);
2021-07-20T12:29:59.1424748Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1425103Z       |                         boundingRect
2021-07-20T12:29:59.1425822Z ../gazebo/gui/plot/PlotCurve.cc:100:40: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1426533Z   100 |                 if (_point.x() < this->d_boundingRect.left())
2021-07-20T12:29:59.1426951Z       |                                        ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1427355Z       |                                        boundingRect
2021-07-20T12:29:59.1428072Z ../gazebo/gui/plot/PlotCurve.cc:101:25: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1428775Z   101 |                   this->d_boundingRect.setLeft(_point.x());
2021-07-20T12:29:59.1429206Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1429561Z       |                         boundingRect
2021-07-20T12:29:59.1430278Z ../gazebo/gui/plot/PlotCurve.cc:102:45: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1431000Z   102 |                 else if (_point.x() > this->d_boundingRect.right())
2021-07-20T12:29:59.1431439Z       |                                             ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1431849Z       |                                             boundingRect
2021-07-20T12:29:59.1432577Z ../gazebo/gui/plot/PlotCurve.cc:103:25: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1433283Z   103 |                   this->d_boundingRect.setRight(_point.x());
2021-07-20T12:29:59.1433697Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1434121Z       |                         boundingRect
2021-07-20T12:29:59.1434838Z ../gazebo/gui/plot/PlotCurve.cc:104:40: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1435531Z   104 |                 if (_point.y() < this->d_boundingRect.top())
2021-07-20T12:29:59.1435963Z       |                                        ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1436345Z       |                                        boundingRect
2021-07-20T12:29:59.1437079Z ../gazebo/gui/plot/PlotCurve.cc:105:25: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1437784Z   105 |                   this->d_boundingRect.setTop(_point.y());
2021-07-20T12:29:59.1438180Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1438547Z       |                         boundingRect
2021-07-20T12:29:59.1439249Z ../gazebo/gui/plot/PlotCurve.cc:106:45: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1440146Z   106 |                 else if (_point.y() > this->d_boundingRect.bottom())
2021-07-20T12:29:59.1440648Z       |                                             ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1441049Z       |                                             boundingRect
2021-07-20T12:29:59.1441795Z ../gazebo/gui/plot/PlotCurve.cc:107:25: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1442502Z   107 |                   this->d_boundingRect.setBottom(_point.y());
2021-07-20T12:29:59.1442986Z       |                         ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1443346Z       |                         boundingRect
2021-07-20T12:29:59.1443959Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'void gazebo::gui::CurveData::Clear()':
2021-07-20T12:29:59.1444763Z ../gazebo/gui/plot/PlotCurve.cc:113:23: error: 'class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1445423Z   113 |                 this->d_samples.clear();
2021-07-20T12:29:59.1445790Z       |                       ^~~~~~~~~
2021-07-20T12:29:59.1446145Z       |                       m_samples
2021-07-20T12:29:59.1446820Z ../gazebo/gui/plot/PlotCurve.cc:114:23: error: 'class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1447481Z   114 |                 this->d_samples.squeeze();
2021-07-20T12:29:59.1447855Z       |                       ^~~~~~~~~
2021-07-20T12:29:59.1448206Z       |                       m_samples
2021-07-20T12:29:59.1448912Z ../gazebo/gui/plot/PlotCurve.cc:115:23: error: 'class gazebo::gui::CurveData' has no member named 'd_boundingRect'; did you mean 'boundingRect'?
2021-07-20T12:29:59.1449623Z   115 |                 this->d_boundingRect = QRectF(0.0, 0.0, -1.0, -1.0);
2021-07-20T12:29:59.1450049Z       |                       ^~~~~~~~~~~~~~
2021-07-20T12:29:59.1450397Z       |                       boundingRect
2021-07-20T12:29:59.1451059Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'QVector<QPointF> gazebo::gui::CurveData::Samples() const':
2021-07-20T12:29:59.1452004Z ../gazebo/gui/plot/PlotCurve.cc:122:30: error: 'const class gazebo::gui::CurveData' has no member named 'd_samples'; did you mean 'm_samples'?
2021-07-20T12:29:59.1452653Z   122 |                 return this->d_samples;
2021-07-20T12:29:59.1453034Z       |                              ^~~~~~~~~
2021-07-20T12:29:59.1453372Z       |                              m_samples

@traversaro
Copy link
Collaborator

traversaro commented Jul 20, 2021

@scpeters
Copy link
Member Author

scpeters added 3 commits July 20, 2021 11:45
In qwt 6.2, they have renamed all member variables from d_* to m_*,
so create a helper function to minimize the ifdefs we will need
to support both versions.

Signed-off-by: Steven Peters <scpeters@openrobotics.org>
Some member variables in qwt_series_data were renamed in 6.2.0

Signed-off-by: Steven Peters <scpeters@openrobotics.org>
@scpeters
Copy link
Member Author

It seems that d_boundingRect (https://github.com/mbdevpl/qwt/blob/15640a66de6631e39643cf255b06c9c35185b901/qwt/src/qwt_series_data.h#L95) was renamed in cachedBoundingRect, see https://qwt.sourceforge.io/class_qwt_series_data.html#aa9950de8549a4daf29dede52736f5292 and https://sourceforge.net/p/qwt/git/ci/develop/tree/src/qwt_series_data.h . Probably we can have an ifdef on QWT_VERSION or QWT_VERSION_STR , see https://sourceforge.net/p/qwt/git/ci/develop/tree/src/qwt_global.h . Similarly for d_samples and m_samples .

looks like the renaming occurred in https://sourceforge.net/p/qwt/git/ci/52a7bf84059ac9fe7601e12a525673790bb80e94/

I've added some helper functions and ifdefs in 8fe222e and b1f100c

@traversaro
Copy link
Collaborator

It seems that d_boundingRect (https://github.com/mbdevpl/qwt/blob/15640a66de6631e39643cf255b06c9c35185b901/qwt/src/qwt_series_data.h#L95) was renamed in cachedBoundingRect, see https://qwt.sourceforge.io/class_qwt_series_data.html#aa9950de8549a4daf29dede52736f5292 and https://sourceforge.net/p/qwt/git/ci/develop/tree/src/qwt_series_data.h . Probably we can have an ifdef on QWT_VERSION or QWT_VERSION_STR , see https://sourceforge.net/p/qwt/git/ci/develop/tree/src/qwt_global.h . Similarly for d_samples and m_samples .

looks like the renaming occurred in https://sourceforge.net/p/qwt/git/ci/52a7bf84059ac9fe7601e12a525673790bb80e94/

I've added some helper functions and ifdefs in 8fe222e and b1f100c

I updated the patch in conda-forge PR with the latest modification: conda-forge/gazebo-feedstock@a26e8c3 .

@traversaro
Copy link
Collaborator

With the latest patch, the build is still failing:

2021-07-21T15:52:08.6692515Z [860/1194] Building CXX object gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o
2021-07-21T15:52:08.6700759Z FAILED: gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o 
2021-07-21T15:52:08.6714759Z $BUILD_PREFIX/bin/x86_64-conda-linux-gnu-c++  -DBOOST_ALL_NO_LIB -DBOOST_DATE_TIME_DYN_LINK -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_IOSTREAMS_DYN_LINK -DBOOST_PROGRAM_OPTIONS_DYN_LINK -DBOOST_REGEX_DYN_LINK -DBOOST_SYSTEM_DYN_LINK -DBOOST_TEST_DYN_LINK -DBOOST_THREAD_DYN_LINK -DBUILDING_DLL -DBUILDING_DLL_GZ_GUI -DHAVE_OPENGL -DHAVE_STRING_H -DIGN_PROFILER_ENABLE=0 -DLIBBULLET_VERSION=3.17 -DLIBBULLET_VERSION_GT_282 -DQGVCORE_LIB -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQWT_DLL -DWITH_CGRAPH -Dgazebo_gui_EXPORTS -Igazebo/gui/gazebo_gui_autogen/include -I../test/gtest/include -I../ -I. -I../deps -I../gazebo/gui/qgv -I../gazebo/gui/qgv/private -I$PREFIX/include/libusb-1.0 -I$PREFIX/include/graphviz -isystem $PREFIX/include/ignition/msgs5 -isystem $PREFIX/include/ignition/math6 -isystem $PREFIX/include/ignition/transport8 -isystem $PREFIX/include/ignition/common3 -isystem $PREFIX/include/ignition/fuel_tools4 -isystem $PREFIX/include/OGRE/RTShaderSystem -isystem $PREFIX/include/OGRE -isystem $PREFIX/include/OGRE/Terrain -isystem $PREFIX/include/OGRE/Paging -isystem $PREFIX/include/OGRE/Overlay -isystem $PREFIX/include/sdformat-9.3 -isystem $PREFIX/include/qt -isystem $PREFIX/include/qt/QtCore -isystem $PREFIX/./mkspecs/linux-g++ -isystem $PREFIX/include/uuid -isystem $PREFIX/include/sdformat-9.3/sdf/.. -isystem $PREFIX/include/ignition/cmake2 -isystem $PREFIX/include/qt/QtWidgets -isystem $PREFIX/include/qt/QtGui -fvisibility-inlines-hidden -std=c++17 -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -isystem $PREFIX/include -fdebug-prefix-map=$SRC_DIR=/usr/local/src/conda/gazebo-11.7.0 -fdebug-prefix-map=$PREFIX=/usr/local/src/conda-prefix       -Wall -Wextra -Wno-long-long -Wno-unused-value -Wfloat-equal -Wshadow -Wswitch-default -Wmissing-include-dirs -pedantic -fvisibility=hidden -fvisibility-inlines-hidden   -s -O3 -DNDEBUG -mssse3 -msse3 -mfpmath=sse -msse -msse2  -fPIC   -fPIC -I$PREFIX/include/uuid -fPIC -MD -MT gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o -MF gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o.d -o gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/PlotCurve.cc.o -c ../gazebo/gui/plot/PlotCurve.cc
2021-07-21T15:52:08.6727570Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'const QRectF& gazebo::gui::CurveData::BoundingRect() const':
2021-07-21T15:52:08.6740894Z ../gazebo/gui/plot/PlotCurve.cc:64:31: error: 'const class gazebo::gui::CurveData' has no member named 'm_boundingRect'; did you mean 'boundingRect'?
2021-07-21T15:52:08.6742060Z    64 |                  return this->m_boundingRect;
2021-07-21T15:52:08.6742788Z       |                               ^~~~~~~~~~~~~~
2021-07-21T15:52:08.6743270Z       |                               boundingRect
2021-07-21T15:52:08.6744113Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'QRectF& gazebo::gui::CurveData::BoundingRect()':
2021-07-21T15:52:08.6745176Z ../gazebo/gui/plot/PlotCurve.cc:73:31: error: 'class gazebo::gui::CurveData' has no member named 'm_boundingRect'; did you mean 'boundingRect'?
2021-07-21T15:52:08.6746089Z    73 |                  return this->m_boundingRect;
2021-07-21T15:52:08.6746637Z       |                               ^~~~~~~~~~~~~~
2021-07-21T15:52:08.6747138Z       |                               boundingRect
2021-07-21T15:52:08.6747997Z ../gazebo/gui/plot/PlotCurve.cc: In member function 'virtual QRectF gazebo::gui::CurveData::boundingRect() const':
2021-07-21T15:52:08.6749108Z ../gazebo/gui/plot/PlotCurve.cc:105:25: error: 'const class gazebo::gui::CurveData' has no member named 'm_boundingRect'; did you mean 'boundingRect'?
2021-07-21T15:52:08.6750039Z   105 |                   this->m_boundingRect = qwtBoundingRect(*this);
2021-07-21T15:52:08.6750607Z       |                         ^~~~~~~~~~~~~~
2021-07-21T15:52:08.6751055Z       |                         boundingRect
2021-07-21T15:52:08.6751961Z ../gazebo/gui/plot/PlotCurve.cc:123:25: error: 'const class gazebo::gui::CurveData' has no member named 'm_boundingRect'; did you mean 'boundingRect'?
2021-07-21T15:52:08.6753110Z   123 |                   this->m_boundingRect.setTop(mid - halfMinHeight);
2021-07-21T15:52:08.6753665Z       |                         ^~~~~~~~~~~~~~
2021-07-21T15:52:08.6754137Z       |                         boundingRect
2021-07-21T15:52:08.6755020Z ../gazebo/gui/plot/PlotCurve.cc:124:25: error: 'const class gazebo::gui::CurveData' has no member named 'm_boundingRect'; did you mean 'boundingRect'?
2021-07-21T15:52:08.6756774Z   124 |                   this->m_boundingRect.setBottom(mid + halfMinHeight);
2021-07-21T15:52:08.6757379Z       |                         ^~~~~~~~~~~~~~
2021-07-21T15:52:08.6757861Z       |                         boundingRect
2021-07-21T15:52:21.4387772Z [861/1194] Building CXX object gazebo/gui/CMakeFiles/gazebo_gui.dir/plot/Palette.cc.o

it seems that d_boundingRect was initially renamed in m_boundingRect but then in something else.

@scpeters
Copy link
Member Author

it seems that d_boundingRect was initially renamed in m_boundingRect but then in something else.

yes, you mentioned that it is now cachedBoundingRect in your first comment, but I lost sight of that. I'll update it shortly

Signed-off-by: Steven Peters <scpeters@openrobotics.org>
@scpeters
Copy link
Member Author

it seems that d_boundingRect was initially renamed in m_boundingRect but then in something else.

yes, you mentioned that it is now cachedBoundingRect in your first comment, but I lost sight of that. I'll update it shortly

updated in 284cb02

@traversaro
Copy link
Collaborator

it seems that d_boundingRect was initially renamed in m_boundingRect but then in something else.

yes, you mentioned that it is now cachedBoundingRect in your first comment, but I lost sight of that. I'll update it shortly

updated in 284cb02

Cool, I tried it in conda-forge/gazebo-feedstock@3bde7c7 and it seems to work fine.

Copy link
Contributor

@WilliamLewww WilliamLewww left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Compiling works for me now in 6.2!

@scpeters scpeters changed the title Fix missing qwt include, deprecation warning Fix build with qwt 6.2, deprecation warning Jul 21, 2021
@scpeters scpeters merged commit 2fc9018 into gazebosim:gazebo11 Jul 22, 2021
@scpeters scpeters deleted the qwt_missing_include branch July 22, 2021 00:25
scpeters added a commit to scpeters/gazebo that referenced this pull request Aug 7, 2021
* IncrementalPlot.cc: include qwt_scale_map.h
* Use Qt::MiddleButton to fix deprecation warning
* PlotCurve: add private helper for renamed members

In qwt 6.2, they have renamed all member variables,
so create helper functions to minimize the ifdefs we will need
to support both versions.

* PlotCurve: add ifdefs to support qwt 6.2.0

Signed-off-by: Steven Peters <scpeters@openrobotics.org>
scpeters added a commit that referenced this pull request Aug 11, 2021
* IncrementalPlot.cc: include qwt_scale_map.h
* Use Qt::MiddleButton to fix deprecation warning
* PlotCurve: add private helper for renamed members

In qwt 6.2, they have renamed all member variables,
so create helper functions to minimize the ifdefs we will need
to support both versions.

* PlotCurve: add ifdefs to support qwt 6.2.0

Signed-off-by: Steven Peters <scpeters@openrobotics.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants