From 868d6dcdf4d262660c0bd98ce3a7ba8bf620231b Mon Sep 17 00:00:00 2001 From: jkriege2 Date: Tue, 23 Jan 2024 13:09:37 +0100 Subject: [PATCH] fixed several compile warnings --- .../barchart_functorfill.cpp | 2 +- .../libexampletools/jkqtpexampleapplication.h | 8 ++-- examples/multithreaded/multithreaded_thread.h | 2 +- examples/speed/speedtestplot.cpp | 6 ++- .../symbols_and_styles/symbols_and_styles.cpp | 2 +- examples/violinplot/violinplot.cpp | 2 +- lib/jkqtcommon/jkqtpbasicimagetools.cpp | 2 +- lib/jkqtcommon/jkqtpbasicimagetools.h | 16 +++---- lib/jkqtcommon/jkqtpcsstools.cpp | 4 +- lib/jkqtcommon/jkqtpdrawingtools.h | 16 +++---- lib/jkqtcommon/jkqtpexpected.h | 4 +- lib/jkqtcommon/jkqtpstringtools.cpp | 26 +---------- lib/jkqtcommon/jkqtpstringtools.h | 3 +- lib/jkqtmathtext/jkqtmathtext.cpp | 2 +- lib/jkqtmathtext/jkqtmathtexttools.cpp | 2 +- .../nodes/jkqtmathtextfracnode.cpp | 2 +- .../nodes/jkqtmathtextinstructionnode.cpp | 2 +- .../jkqtmathtextmodifyenvironmentnode.cpp | 44 +++++++++---------- .../nodes/jkqtmathtextsymbolnode.cpp | 2 +- .../nodes/jkqtmathtexttextnode.cpp | 2 +- .../nodes/jkqtmathtextwhitespacenode.cpp | 5 +-- .../parsers/jkqtmathtextlatexparser.cpp | 10 ++--- lib/jkqtplotter/graphs/jkqtpbarchartbase.cpp | 10 +++-- .../graphs/jkqtpevaluatedfunction.cpp | 8 ++-- lib/jkqtplotter/graphs/jkqtpimage.cpp | 6 +-- .../graphs/jkqtpsinglecolumnsymbols.cpp | 2 +- lib/jkqtplotter/graphs/jkqtpviolinplot.cpp | 6 +-- lib/jkqtplotter/gui/jkqtpcomboboxes.cpp | 2 +- lib/jkqtplotter/jkqtpbaseplotter.cpp | 6 +-- lib/jkqtplotter/jkqtpcoordinateaxes.cpp | 6 +-- lib/jkqtplotter/jkqtpgraphsbasestyle.cpp | 12 ++--- lib/jkqtplotter/jkqtpgraphsbasestyle.h | 7 ++- .../jkqtpgraphsbasestylingmixins.cpp | 2 +- lib/jkqtplotter/jkqtpkey.cpp | 4 +- lib/jkqtplotter/jkqtpkeystyle.cpp | 2 +- tests/jkqtcommmon/jkqtcommon_test.cpp | 8 ++-- .../jkqtplotter_doc_imagegenerator.cpp | 14 +++--- 37 files changed, 119 insertions(+), 140 deletions(-) diff --git a/examples/barchart_functorfill/barchart_functorfill.cpp b/examples/barchart_functorfill/barchart_functorfill.cpp index fcae1f5d19..31783d4b62 100644 --- a/examples/barchart_functorfill/barchart_functorfill.cpp +++ b/examples/barchart_functorfill/barchart_functorfill.cpp @@ -29,7 +29,7 @@ void doExample(JKQTPlotter& plot, const QString& title) graph->setValueColumn(columnV); // set TwoColor fill Mode graph->setFillMode(JKQTPBarGraphBase::FillMode::FunctorFilling); - graph->setFillBrushFunctor([](double key, double value) {return QBrush(QColor::fromHsvF(key/12.0, 1.0, 1.0)); }); + graph->setFillBrushFunctor([](double key, double /*value*/) {return QBrush(QColor::fromHsvF(key/12.0, 1.0, 1.0)); }); plot.addGraph(graph); // 4 autoscale the plot so the graph is contained diff --git a/examples/libexampletools/jkqtpexampleapplication.h b/examples/libexampletools/jkqtpexampleapplication.h index 2b46c2ccab..17da0f6d6d 100644 --- a/examples/libexampletools/jkqtpexampleapplication.h +++ b/examples/libexampletools/jkqtpexampleapplication.h @@ -42,13 +42,13 @@ protected: std::function plotf; JKQTPlotter* p; inline Data(const std::function& f_): - type(FunctorType), f(f_), p(nullptr), plotf() + type(FunctorType), f(f_), plotf(), p(nullptr) {} inline Data(JKQTPlotter* p_): - type(PlotterType), p(p_), f(), plotf() + type(PlotterType), f(), plotf(), p(p_) {} inline Data(std::function p_): - type(PlotterFunctorType), plotf(p_), f(), p(nullptr) + type(PlotterFunctorType), f(), plotf(p_), p(nullptr) {} }; @@ -56,5 +56,5 @@ protected: void readCmdLine(); QRect getBoundsWithoutColor(QImage qImage, const QColor &exclusionColor = Qt::white); - void saveWidget(QWidget* w, int iVisible);; + void saveWidget(QWidget* w, int iVisible); }; diff --git a/examples/multithreaded/multithreaded_thread.h b/examples/multithreaded/multithreaded_thread.h index 2c35cbe9ac..dda3ae7526 100644 --- a/examples/multithreaded/multithreaded_thread.h +++ b/examples/multithreaded/multithreaded_thread.h @@ -18,8 +18,8 @@ public: QThread(parent), m_plotindex(plotindex), m_runtimeNanoseconds(0), - m_filenamepart(filenamepart), m_filename(), + m_filenamepart(filenamepart), m_NUM_GRAPHS(NUM_GRAPHS), m_NUM_DATAPOINTS(NUM_DATAPOINTS), m_labeltemplate(labeltemplate) diff --git a/examples/speed/speedtestplot.cpp b/examples/speed/speedtestplot.cpp index 05a9b459ad..b7c6e0d477 100644 --- a/examples/speed/speedtestplot.cpp +++ b/examples/speed/speedtestplot.cpp @@ -9,8 +9,10 @@ #include "jkqtplotter/graphs/jkqtpscatter.h" #include "jkqtmath/jkqtpstatisticstools.h" +#define NUM_DATAPOINTS 500 + SpeedTestPlot::SpeedTestPlot(): - JKQTPlotter(), NDATA(500), dx(1.0/500.0*4.0*JKQTPSTATISTICS_PI), x0(0) + JKQTPlotter(), dx(1.0/static_cast(NUM_DATAPOINTS)*4.0*JKQTPSTATISTICS_PI), x0(0), NDATA(NUM_DATAPOINTS) { X.fill(0); @@ -127,7 +129,7 @@ SpeedTestPlot::SpeedTestPlot(): QAction* act=actGroup->addAction(QString::number(a)); act->setCheckable(true); act->setChecked(a==1.0); - connect(act, &QAction::toggled, std::bind([](bool enabled,JKQTPXYLineGraph* g, JKQTPXYLineGraph* g2,SpeedTestPlot* p, double a){ + connect(act, &QAction::toggled, std::bind([](bool /*enabled*/,JKQTPXYLineGraph* g, JKQTPXYLineGraph* g2,SpeedTestPlot* p, double a){ g->setNonvisibleLineCompressionAgressiveness(a); g2->setNonvisibleLineCompressionAgressiveness(a); if (!p->actAnimation->isChecked()) p->redrawPlot(); diff --git a/examples/symbols_and_styles/symbols_and_styles.cpp b/examples/symbols_and_styles/symbols_and_styles.cpp index aa9a0d8d0a..0f61c95407 100644 --- a/examples/symbols_and_styles/symbols_and_styles.cpp +++ b/examples/symbols_and_styles/symbols_and_styles.cpp @@ -52,7 +52,7 @@ int main(int argc, char* argv[]) JKQTPXYLineGraph* graph=new JKQTPXYLineGraph(&plot); // copy data into datastore and immediately set the yColumn - graph->setXColumn((symbolID<=JKQTPMaxSymbolID/2)?columnX1:columnX2); + graph->setXColumn((symbolID<=static_cast(JKQTPMaxSymbolID)/2)?columnX1:columnX2); graph->setYColumn(ds->addCopiedColumn(Y, "y"+QString::number(symbolID))); // set symbol + pen style and color diff --git a/examples/violinplot/violinplot.cpp b/examples/violinplot/violinplot.cpp index 906d8145d0..0a2ab83767 100644 --- a/examples/violinplot/violinplot.cpp +++ b/examples/violinplot/violinplot.cpp @@ -177,7 +177,7 @@ int main(int argc, char* argv[]) JKQTPlotter* plot1=showPlot("1: JKQTPViolinplotHorizontalElement"); //plot1->resize(500,450); plot1->getPlotter()->setKeyPosition(JKQTPKeyInsideTopLeft); - JKQTPlotter* plot2=showPlot("2: JKQTPViolinplotVerticalElement"); + /*JKQTPlotter* plot2=*/showPlot("2: JKQTPViolinplotVerticalElement"); return app.exec(); diff --git a/lib/jkqtcommon/jkqtpbasicimagetools.cpp b/lib/jkqtcommon/jkqtpbasicimagetools.cpp index a19d1e3d4e..763cc0648f 100644 --- a/lib/jkqtcommon/jkqtpbasicimagetools.cpp +++ b/lib/jkqtcommon/jkqtpbasicimagetools.cpp @@ -201,7 +201,7 @@ QMap JKQTPImageTools::getDefaultLUTs() { { const auto fR= [](float v) -> float { return ((v < 0.5) ? 128.0*sin(JKQTPSTATISTICS_PI*(2.0*v-0.5))+128.0 : 255.0)/255.0; }; const auto fG= [](float v) -> float { return ((v < 0.5) ? 512.0*v+128.0 : 512.0-512.0*v)/255.0; }; - const auto fB= [](float v) -> float { return 0.0; }; + const auto fB= [](float ) -> float { return 0.0; }; const auto& normLUT=lutstore[JKQTPMathImageTRAFFICLIGHT]=JKQTPImageTools::LUTData(JKQTPBuildColorPaletteLUT(fR, fG, fB), "Trafficlight", QObject::tr("Trafficlight")); lutstore[JKQTPMathImageINVERTED_TRAFFICLIGHT]=JKQTPImageTools::LUTData(jkqtp_reversed(normLUT.lut), "invtrafficlight", QObject::tr("inv. Trafficlight")); diff --git a/lib/jkqtcommon/jkqtpbasicimagetools.h b/lib/jkqtcommon/jkqtpbasicimagetools.h index 49c1c8df6c..9352b2d79a 100644 --- a/lib/jkqtcommon/jkqtpbasicimagetools.h +++ b/lib/jkqtcommon/jkqtpbasicimagetools.h @@ -1178,35 +1178,35 @@ public: inline JKQTPPaletteList(): ListType() {}; #if QT_VERSION >= QT_VERSION_CHECK(6,0,0) inline JKQTPPaletteList(qsizetype size): ListType(size) {}; - inline JKQTPPaletteList(qsizetype size, parameter_type value): ListType(size, value) {}; + inline JKQTPPaletteList(qsizetype size, parameter_type value): ListType(size, value) {} #endif template - inline JKQTPPaletteList(std::initializer_list> args): ListType(args) {}; + inline JKQTPPaletteList(std::initializer_list> args): ListType(args) {} inline JKQTPPaletteList(std::initializer_list args): ListType() { for(const auto& v: args) { push_back(v); } - }; + } inline JKQTPPaletteList(std::initializer_list args): ListType() { for(const auto& v: args) { push_back(v); } - }; + } inline JKQTPPaletteList(std::initializer_list> args): ListType() { for(const auto& v: args) { push_back(v.first, v.second); } - }; + } template = true> - inline JKQTPPaletteList(InputIterator first, InputIterator last): ListType(first, last) {}; - inline JKQTPPaletteList(ListType &&other):ListType(std::forward(other)) {}; - inline JKQTPPaletteList(const ListType &other):ListType(other) {}; + inline JKQTPPaletteList(InputIterator first, InputIterator last): ListType(first, last) {} + inline JKQTPPaletteList(ListType &&other):ListType(std::forward(other)) {} + inline JKQTPPaletteList(const ListType &other):ListType(other) {} using ListType::push_back; inline void push_back(QRgb rgb) { diff --git a/lib/jkqtcommon/jkqtpcsstools.cpp b/lib/jkqtcommon/jkqtpcsstools.cpp index 8e684b9a73..855906b8ec 100644 --- a/lib/jkqtcommon/jkqtpcsstools.cpp +++ b/lib/jkqtcommon/jkqtpcsstools.cpp @@ -374,13 +374,13 @@ JKQTPCSSParser::Token::Token(TokenType type): } JKQTPCSSParser::Token::Token(double num, const QString &unit_): - NumberValue(num), StringValue(unit_), type(NUMBER) + type(NUMBER), StringValue(unit_), NumberValue(num) { } JKQTPCSSParser::Token::Token(const QString &str, TokenType type_): - StringValue(str), type(type_), NumberValue(0.0) + type(type_), StringValue(str), NumberValue(0.0) { if (type_==NUMBER) NumberValue=str.toDouble(); if (type_==HEXSTRING) NumberValue=str.toInt(nullptr,16); diff --git a/lib/jkqtcommon/jkqtpdrawingtools.h b/lib/jkqtcommon/jkqtpdrawingtools.h index 83c84eb521..d87ae32f26 100644 --- a/lib/jkqtcommon/jkqtpdrawingtools.h +++ b/lib/jkqtcommon/jkqtpdrawingtools.h @@ -81,32 +81,32 @@ typedef std::function JKQTPCustomGraphSymbolFunctor; struct JKQTPlotterDrawingTools { /** \brief a special placeholder that can be used to indicate that a color should be replaced by the "current color" in a certain context * - * \see JKQTPReplaceCurrentColor() + * \see JKQTPReplaceCurrentColor() , JKQTFillStyleSummmary */ static JKQTCOMMON_LIB_EXPORT const QColor CurrentColorPlaceholder; /** \brief a special placeholder that can be used to indicate that a color should be replaced by the "current color", but with 10% transparency in a certain context * - * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... + * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... , JKQTFillStyleSummmary */ static JKQTCOMMON_LIB_EXPORT const QColor CurrentColorPlaceholder_Trans10; /** \brief a special placeholder that can be used to indicate that a color should be replaced by the "current color", but with 25% transparency in a certain context * - * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, ... + * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, ... , JKQTFillStyleSummmary */ static JKQTCOMMON_LIB_EXPORT const QColor CurrentColorPlaceholder_Trans25; /** \brief a special placeholder that can be used to indicate that a color should be replaced by the "current color", but with 50% transparency in a certain context * - * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... + * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... , JKQTFillStyleSummmary */ static JKQTCOMMON_LIB_EXPORT const QColor CurrentColorPlaceholder_Trans50; /** \brief a special placeholder that can be used to indicate that a color should be replaced by the "current color", but with 75% transparency in a certain context * - * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... + * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... , JKQTFillStyleSummmary */ static JKQTCOMMON_LIB_EXPORT const QColor CurrentColorPlaceholder_Trans75; /** \brief a special placeholder that can be used to indicate that a color should be replaced by the "current color", but with 90% transparency in a certain context * - * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... + * \see JKQTPReplaceCurrentColor(), JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... , JKQTFillStyleSummmary */ static JKQTCOMMON_LIB_EXPORT const QColor CurrentColorPlaceholder_Trans90; /** \brief smallest linewidth any line in JKQTPlotter/JKQTBasePlotter may have @@ -126,13 +126,13 @@ struct JKQTPlotterDrawingTools { /*! \brief check whether \a col equals JKQTPlotterDrawingTools::CurrentColorPlaceholder (or one of its variants) and then replace it by \a currentColor \ingroup jkqtptools_drawing - \see JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... + \see JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... , JKQTFillStyleSummmary */ JKQTCOMMON_LIB_EXPORT void JKQTPReplaceCurrentColor(QColor& col, const QColor& currentColor); /*! \brief check whether any color in \a grad equals JKQTPlotterDrawingTools::CurrentColorPlaceholder (or one of its variants) and then replace it by \a currentColor \ingroup jkqtptools_drawing - \see JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... + \see JKQTPlotterDrawingTools::CurrentColorPlaceholder, JKQTPlotterDrawingTools::CurrentColorPlaceholder_Trans10, ... , JKQTFillStyleSummmary */ JKQTCOMMON_LIB_EXPORT void JKQTPReplaceCurrentColor(QGradient& grad, const QColor& currentColor); diff --git a/lib/jkqtcommon/jkqtpexpected.h b/lib/jkqtcommon/jkqtpexpected.h index 67c3a0198d..ad84f18226 100644 --- a/lib/jkqtcommon/jkqtpexpected.h +++ b/lib/jkqtcommon/jkqtpexpected.h @@ -72,12 +72,12 @@ struct JKQTPExpected { if (!m_hasValue) return m_error; throw std::runtime_error("error not available"); } - const bool has_value() const { return m_hasValue; } + bool has_value() const { return m_hasValue; } operator bool() const { return m_hasValue; } private: const bool m_hasValue; - const E m_error; const T m_value; + const E m_error; }; diff --git a/lib/jkqtcommon/jkqtpstringtools.cpp b/lib/jkqtcommon/jkqtpstringtools.cpp index 618a815d36..2a7678a152 100644 --- a/lib/jkqtcommon/jkqtpstringtools.cpp +++ b/lib/jkqtcommon/jkqtpstringtools.cpp @@ -374,7 +374,7 @@ Qt::BrushStyle jkqtp_String2QBrushStyle(const QString& style) { } -Qt::BrushStyle jkqtp_String2QBrushStyleExt(const QString &style, QColor *color, QGradient *gradient, QPixmap *image, double* rotationAngleDeg) +Qt::BrushStyle jkqtp_String2QBrushStyleExt(const QString &style, QGradient *gradient, QPixmap *image) { const QString s=style.toLower().trimmed().simplified(); QStringList caps; @@ -685,30 +685,6 @@ QColor jkqtp_String2QColor(QString color) if (nameFound) return col; } - // declare som helper functors - static auto valUnitToInt=[](const QString& v, const QString& unit="", int intMax=255) { - if (v.isEmpty()) return -1; - if (unit=="%") { - return qBound(0, QLocale::c().toDouble(v)/100.0*intMax, intMax); - } else if (unit=="deg") { - int vv=qBound(0, QLocale::c().toDouble(v), intMax);; - if (vv<0) vv=vv+static_cast(qCeil(static_cast(-vv)/360.0)*360.0); - return vv; - } - return qBound(0, QLocale::c().toDouble(v), intMax); - }; - static auto valUnitToAlphaInt=[](const QString& v, const QString& unit="", int intMax=255) { - if (v.isEmpty()) return -1; - if (unit=="%") { - return intMax-qBound(0, QLocale::c().toDouble(v)/100.0*intMax, intMax); - } else if (unit=="deg") { - int vv=qBound(0, QLocale::c().toDouble(v), intMax);; - if (vv<0) vv=vv+static_cast(qCeil(static_cast(-vv)/360.0)*360.0); - return vv; - } - return qBound(0, QLocale::c().toDouble(v), intMax); - }; - // now we check for diverse special syntaxes // P: "color,NN%" NN=TRANSPARENCY in percent // AP: "color,aNN\%" NN=ALPHA in percent diff --git a/lib/jkqtcommon/jkqtpstringtools.h b/lib/jkqtcommon/jkqtpstringtools.h index 180ded6ce1..9ce11f9b94 100644 --- a/lib/jkqtcommon/jkqtpstringtools.h +++ b/lib/jkqtcommon/jkqtpstringtools.h @@ -56,14 +56,13 @@ JKQTCOMMON_LIB_EXPORT Qt::BrushStyle jkqtp_String2QBrushStyle(const QString& sty * \ingroup jkqtptools_string * * \param style the string to be parsed - * \param[out] color output parameter for a parsed color * \param[out] gradient output parameter for a parsed gradient * \param[out] image output parameter for a parsed image * \param[out] rotationAngleDeg output parameter for a parsed rotation angle of the pattern in degrees, where the direction equals the direction of a clock hand, i.e. 0=12o'clock, 180=6o'clock, ... * * \see jkqtp_String2QBrushStyle() */ -JKQTCOMMON_LIB_EXPORT Qt::BrushStyle jkqtp_String2QBrushStyleExt(const QString& style, QColor* color=nullptr, QGradient* gradient=nullptr, QPixmap* image=nullptr, double *rotationAngleDeg=nullptr); +JKQTCOMMON_LIB_EXPORT Qt::BrushStyle jkqtp_String2QBrushStyleExt(const QString& style, QGradient* gradient=nullptr, QPixmap* image=nullptr); /** \brief converts a Unicode codepoint into a UTF8-sequence diff --git a/lib/jkqtmathtext/jkqtmathtext.cpp b/lib/jkqtmathtext/jkqtmathtext.cpp index 704b8b0d77..b1910d7ef7 100644 --- a/lib/jkqtmathtext/jkqtmathtext.cpp +++ b/lib/jkqtmathtext/jkqtmathtext.cpp @@ -1316,7 +1316,7 @@ void JKQTMathText::draw(QPainter& painter, unsigned int flags, QRectF rect, bool else if ((flags & Qt::AlignVCenter) != 0) y=y+(rect.height()-size.overallHeight)/2.0; // finally draw - const double xend=getNodeTree()->draw(painter, x, y, ev); + /*const double xend=*/getNodeTree()->draw(painter, x, y, ev); } } diff --git a/lib/jkqtmathtext/jkqtmathtexttools.cpp b/lib/jkqtmathtext/jkqtmathtexttools.cpp index 0bc9afef63..fa2bcd89c6 100644 --- a/lib/jkqtmathtext/jkqtmathtexttools.cpp +++ b/lib/jkqtmathtext/jkqtmathtexttools.cpp @@ -118,7 +118,7 @@ void JKQTMathTextFontSpecifier::setFallbackSymbolsFontName(const QString &name) m_fallbackSymbolFont=name; } -QString JKQTMathTextFontSpecifier::transformFontName(const QString &fontName, bool mathmode) +QString JKQTMathTextFontSpecifier::transformFontName(const QString &fontName, bool /*mathmode*/) { const QString fnt=fontName.trimmed().toLower(); QFont testFnt; diff --git a/lib/jkqtmathtext/nodes/jkqtmathtextfracnode.cpp b/lib/jkqtmathtext/nodes/jkqtmathtextfracnode.cpp index 62ac4a531d..b617a0f8ab 100644 --- a/lib/jkqtmathtext/nodes/jkqtmathtextfracnode.cpp +++ b/lib/jkqtmathtext/nodes/jkqtmathtextfracnode.cpp @@ -193,7 +193,7 @@ JKQTMathTextNodeSize JKQTMathTextFracNode::getSizeInternal(QPainter& painter, JK const double top_ascent=line_ascent; const double newascent=size1.overallHeight+top_ascent; const double newdescent=qMax(size2.overallHeight-size2.baselineHeight, qheight-xheight); - const double deltaWidth=xwidth*((fracmode==JKQTMathTextFracNode::MTFMstfrac)?0.8:0.7); + //const double deltaWidth=xwidth*((fracmode==JKQTMathTextFracNode::MTFMstfrac)?0.8:0.7); size.width=size1.width+size2.width+xwidth*0.666; size.strikeoutPos=line_ascent; diff --git a/lib/jkqtmathtext/nodes/jkqtmathtextinstructionnode.cpp b/lib/jkqtmathtext/nodes/jkqtmathtextinstructionnode.cpp index 57faf0d984..52b6d650cf 100644 --- a/lib/jkqtmathtext/nodes/jkqtmathtextinstructionnode.cpp +++ b/lib/jkqtmathtext/nodes/jkqtmathtextinstructionnode.cpp @@ -90,7 +90,7 @@ double JKQTMathTextSimpleInstructionNode::draw(QPainter &painter, double x, doub return x+bb.width(); } -bool JKQTMathTextSimpleInstructionNode::toHtml(QString &html, JKQTMathTextEnvironment currentEv, JKQTMathTextEnvironment defaultEv) const +bool JKQTMathTextSimpleInstructionNode::toHtml(QString &html, JKQTMathTextEnvironment /*currentEv*/, JKQTMathTextEnvironment /*defaultEv*/) const { const QString txt=executeInstruction(); html+=txt; diff --git a/lib/jkqtmathtext/nodes/jkqtmathtextmodifyenvironmentnode.cpp b/lib/jkqtmathtext/nodes/jkqtmathtextmodifyenvironmentnode.cpp index 474923c30c..3cf51e4b55 100644 --- a/lib/jkqtmathtext/nodes/jkqtmathtextmodifyenvironmentnode.cpp +++ b/lib/jkqtmathtext/nodes/jkqtmathtextmodifyenvironmentnode.cpp @@ -543,7 +543,7 @@ const QHash line; - size_t colCount=0; + qsizetype colCount=0; //std::cout<<"found \\begin{matrix}\n"; while (first || currentToken==MTTampersand || currentToken==MTTinstructionNewline) { while (getToken()==MTTwhitespace) ; // eat whitespace @@ -908,10 +908,10 @@ JKQTMathTextNode* JKQTMathTextLatexParser::parseLatexString(bool get, JKQTMathTe line.append(it); } if (currentToken==MTTinstructionNewline || line.size()>0) { - colCount=qMax(colCount, static_cast(line.size())); - if (line.size()==0 || (line.size()>1 && line.size()==colCount)) { + colCount=qMax(colCount, static_cast(line.size())); + if (line.size()==0 || (line.size()>1 && static_cast(line.size())==colCount)) { items.append(line); - } else if (line.size()>1 && line.size()!=colCount) { + } else if (line.size()>1 && static_cast(line.size())!=colCount) { addToErrorList(tr("error @ ch. %1: wrong number of entries widthin '\\begin{%2}...\\end{%2}'").arg(currentTokenID).arg(envname)); } } @@ -974,7 +974,7 @@ JKQTMathTextNode* JKQTMathTextLatexParser::parseLatexString(bool get, JKQTMathTe return simplifyJKQTMathTextNode(nl); } -JKQTMathTextVerticalListNode *JKQTMathTextLatexParser::parseMultilineLatexString(bool get, const QString &quitOnEnvironmentEnd, JKQTMathTextHorizontalAlignment _alignment, double _linespacingFactor, JKQTMathTextLineSpacingMode spacingMode_, JKQTMathTextVerticalOrientation _verticalOrientation) +JKQTMathTextVerticalListNode *JKQTMathTextLatexParser::parseMultilineLatexString(bool /*get*/, const QString &quitOnEnvironmentEnd, JKQTMathTextHorizontalAlignment _alignment, double _linespacingFactor, JKQTMathTextLineSpacingMode spacingMode_, JKQTMathTextVerticalOrientation _verticalOrientation) { JKQTMathTextVerticalListNode* vlist = new JKQTMathTextVerticalListNode(parentMathText, _alignment, _linespacingFactor, spacingMode_, _verticalOrientation ); bool first=true; diff --git a/lib/jkqtplotter/graphs/jkqtpbarchartbase.cpp b/lib/jkqtplotter/graphs/jkqtpbarchartbase.cpp index 373e537551..a1b65deaa7 100644 --- a/lib/jkqtplotter/graphs/jkqtpbarchartbase.cpp +++ b/lib/jkqtplotter/graphs/jkqtpbarchartbase.cpp @@ -36,12 +36,14 @@ JKQTPBarGraphBase::JKQTPBarGraphBase(JKQTBasePlotter* parent): JKQTPXYBaselineGraph(parent), - width(0.9), shift(0), + width(0.9), + shift(0), + rectRadiusAtValue(0), + rectRadiusAtBaseline(0), + m_drawBaseline(parent->getCurrentPlotterStyle().graphsStyle.barchartStyle.drawBaseline), m_fillMode(FillMode::SingleFilling), - m_useCustomDrawFunctor(false), m_lineColorDerivationModeForSpecialFill(parent->getCurrentPlotterStyle().graphsStyle.barchartStyle.graphColorDerivationMode), - rectRadiusAtBaseline(0),rectRadiusAtValue(0), - m_drawBaseline(parent->getCurrentPlotterStyle().graphsStyle.barchartStyle.drawBaseline) + m_useCustomDrawFunctor(false) { initFillStyle(parent, parentPlotStyle, JKQTPPlotStyleType::Barchart); initLineStyle(parent, parentPlotStyle, JKQTPPlotStyleType::Barchart); diff --git a/lib/jkqtplotter/graphs/jkqtpevaluatedfunction.cpp b/lib/jkqtplotter/graphs/jkqtpevaluatedfunction.cpp index 16d891aacb..bcf623cbbd 100644 --- a/lib/jkqtplotter/graphs/jkqtpevaluatedfunction.cpp +++ b/lib/jkqtplotter/graphs/jkqtpevaluatedfunction.cpp @@ -732,12 +732,12 @@ std::function JKQTPXFunctionLineGraph::buildErrorFunctorSpec() return spec; } -bool JKQTPXFunctionLineGraph::getXMinMax(double &minx, double &maxx, double &smallestGreaterZero) +bool JKQTPXFunctionLineGraph::getXMinMax(double &/*minx*/, double &/*maxx*/, double &/*smallestGreaterZero*/) { return false; } -bool JKQTPXFunctionLineGraph::getYMinMax(double &miny, double &maxy, double &smallestGreaterZero) +bool JKQTPXFunctionLineGraph::getYMinMax(double &/*miny*/, double &/*maxy*/, double &/*smallestGreaterZero*/) { return false; } @@ -841,12 +841,12 @@ std::function JKQTPYFunctionLineGraph::buildErrorFunctorSpec() return spec; } -bool JKQTPYFunctionLineGraph::getXMinMax(double &miny, double &maxy, double &smallestGreaterZero) +bool JKQTPYFunctionLineGraph::getXMinMax(double &/*miny*/, double &/*maxy*/, double &/*smallestGreaterZero*/) { return false; } -bool JKQTPYFunctionLineGraph::getYMinMax(double &miny, double &maxy, double &smallestGreaterZero) +bool JKQTPYFunctionLineGraph::getYMinMax(double &/*miny*/, double &/*maxy*/, double &/*smallestGreaterZero*/) { return false; } diff --git a/lib/jkqtplotter/graphs/jkqtpimage.cpp b/lib/jkqtplotter/graphs/jkqtpimage.cpp index 48439782a4..2e8c2fb628 100644 --- a/lib/jkqtplotter/graphs/jkqtpimage.cpp +++ b/lib/jkqtplotter/graphs/jkqtpimage.cpp @@ -723,10 +723,10 @@ void JKQTPMathImage::initJKQTPMathImage() { JKQTPMathImage::JKQTPMathImage(double x, double y, double width, double height, JKQTPMathImageDataType datatype, const void* data, int Nx, int Ny, JKQTPMathImageColorPalette palette, JKQTBasePlotter* parent): JKQTPMathImageBase(x, y, width, height, datatype, data, Nx, Ny, parent), JKQTPColorPaletteWithModifierStyleAndToolsMixin(parent), - actCopyImage(nullptr), actSaveImage(nullptr), - actCopyPalette(nullptr), - actSavePalette(nullptr) + actCopyImage(nullptr), + actSavePalette(nullptr), + actCopyPalette(nullptr) { initJKQTPMathImage(); this->palette=palette; diff --git a/lib/jkqtplotter/graphs/jkqtpsinglecolumnsymbols.cpp b/lib/jkqtplotter/graphs/jkqtpsinglecolumnsymbols.cpp index d120775752..52577349e1 100644 --- a/lib/jkqtplotter/graphs/jkqtpsinglecolumnsymbols.cpp +++ b/lib/jkqtplotter/graphs/jkqtpsinglecolumnsymbols.cpp @@ -36,7 +36,7 @@ JKQTPSingleColumnSymbolsGraph::JKQTPSingleColumnSymbolsGraph(JKQTBasePlotter *parent): - JKQTPSingleColumnGraph(parent), seedValue(123456), positionScatterStyle(NoScatter), position(0), width(1) + JKQTPSingleColumnGraph(parent), position(0), width(1), positionScatterStyle(NoScatter), seedValue(123456) { parentPlotStyle=-1; diff --git a/lib/jkqtplotter/graphs/jkqtpviolinplot.cpp b/lib/jkqtplotter/graphs/jkqtpviolinplot.cpp index cca531ba66..e47c3103fe 100644 --- a/lib/jkqtplotter/graphs/jkqtpviolinplot.cpp +++ b/lib/jkqtplotter/graphs/jkqtpviolinplot.cpp @@ -40,11 +40,11 @@ JKQTPViolinplotElementBase::JKQTPViolinplotElementBase(JKQTBasePlotter* parent): pos(JKQTP_NAN), median(JKQTP_NAN), mean(JKQTP_NAN), + drawMean(false), + drawMedian(false), + drawMinMax(false), min(JKQTP_NAN), max(JKQTP_NAN), - drawMean(false), - drawMinMax(false), - drawMedian(false), violinPositionColumn(-1), violinFrequencyColumn(-1) { diff --git a/lib/jkqtplotter/gui/jkqtpcomboboxes.cpp b/lib/jkqtplotter/gui/jkqtpcomboboxes.cpp index 40592e315d..629de7d048 100644 --- a/lib/jkqtplotter/gui/jkqtpcomboboxes.cpp +++ b/lib/jkqtplotter/gui/jkqtpcomboboxes.cpp @@ -78,7 +78,7 @@ JKQTPSymbolComboBox::JKQTPSymbolComboBox(QWidget *parent): { clear(); setEditable(false); - for (int i=0; i<=JKQTPMaxSymbolID; i++) { + for (int i=0; i<=static_cast(JKQTPMaxSymbolID); i++) { addSymbol(static_cast(i), JKQTPGraphSymbols2NameString(static_cast(i))); } setCurrentIndex(0); diff --git a/lib/jkqtplotter/jkqtpbaseplotter.cpp b/lib/jkqtplotter/jkqtpbaseplotter.cpp index 34f5d0dc8b..97977a5a06 100644 --- a/lib/jkqtplotter/jkqtpbaseplotter.cpp +++ b/lib/jkqtplotter/jkqtpbaseplotter.cpp @@ -644,9 +644,9 @@ QRectF JKQTBasePlotter::calcPlotMarginRect(PlotMarginUse use, PlotMarginSide sid if (internalPlotMargins.contains(use)) { const double marginSize=internalPlotMargins[use].getMargin(side); const double allTop=internalPlotMargins.calcTop(); - const double allBottom=internalPlotMargins.calcBottom(); + //const double allBottom=internalPlotMargins.calcBottom(); const double allLeft=internalPlotMargins.calcLeft(); - const double allRight=internalPlotMargins.calcRight(); + //const double allRight=internalPlotMargins.calcRight(); const double allHeight=internalPlotBorderTop+internalPlotHeight+internalPlotBorderBottom; const double allWidth=internalPlotBorderLeft+internalPlotWidth+internalPlotBorderRight; if (marginSize>0.0) { @@ -3632,7 +3632,7 @@ bool JKQTBasePlotter::saveImage(const QString& filename, bool displayPreview) { for (const auto& ext: jkqtpPaintDeviceAdapters.get()[i]->getFileExtension()) filterextensions.last()<filtersIndexFirstExporterPLugin); + //const bool isWithSpecialDeviceAdapter=(filterstrings.size()>filtersIndexFirstExporterPLugin); // add remaining QImageWriter exporters const int filtersIndexFirstQtWriter=filterstrings.size(); const QList writerformats=QImageWriter::supportedImageFormats(); diff --git a/lib/jkqtplotter/jkqtpcoordinateaxes.cpp b/lib/jkqtplotter/jkqtpcoordinateaxes.cpp index 1e6024b519..c43eec8280 100644 --- a/lib/jkqtplotter/jkqtpcoordinateaxes.cpp +++ b/lib/jkqtplotter/jkqtpcoordinateaxes.cpp @@ -1155,7 +1155,7 @@ void JKQTPCoordinateAxis::setColor(QColor c) setTickLabelColor(c); } -JKQTPCoordinateAxis::Axis0ElementsSizeDescription JKQTPCoordinateAxis::getSize0(JKQTPEnhancedPainter &painter) +JKQTPCoordinateAxis::Axis0ElementsSizeDescription JKQTPCoordinateAxis::getSize0(JKQTPEnhancedPainter &/*painter*/) { return JKQTPCoordinateAxis::Axis0ElementsSizeDescription(); } @@ -2136,7 +2136,7 @@ double JKQTPVerticalIndependentAxis::getParentOtheraxisOffset() const { } -double JKQTPVerticalIndependentAxis::parentOtherAxisX2P(double x) const +double JKQTPVerticalIndependentAxis::parentOtherAxisX2P(double /*x*/) const { return qQNaN(); } @@ -2933,7 +2933,7 @@ double JKQTPHorizontalIndependentAxis::getParentOtheraxisOffset() const { return otherAxisOffset; } -double JKQTPHorizontalIndependentAxis::parentOtherAxisX2P(double x) const +double JKQTPHorizontalIndependentAxis::parentOtherAxisX2P(double /*x*/) const { return qQNaN(); } diff --git a/lib/jkqtplotter/jkqtpgraphsbasestyle.cpp b/lib/jkqtplotter/jkqtpgraphsbasestyle.cpp index a846d660b5..a2b1439911 100644 --- a/lib/jkqtplotter/jkqtpgraphsbasestyle.cpp +++ b/lib/jkqtplotter/jkqtpgraphsbasestyle.cpp @@ -232,7 +232,7 @@ QVector JKQTGraphsBaseStyle::getDefaultGraphPenStyles() QVector JKQTGraphsBaseStyle::getDefaultGraphSymbols() { QVector syms; - for (int i=2; i<=JKQTPMaxSymbolID; i++) syms.push_back(static_cast(i)); + for (int i=2; i<=static_cast(JKQTPMaxSymbolID); i++) syms.push_back(static_cast(i)); return syms; } @@ -444,7 +444,7 @@ JKQTBarchartSpecificStyleProperties::JKQTBarchartSpecificStyleProperties(const J } -JKQTBarchartSpecificStyleProperties::JKQTBarchartSpecificStyleProperties(const JKQTBasePlotterStyle& parent, const JKQTGraphsSpecificStyleProperties &other): +JKQTBarchartSpecificStyleProperties::JKQTBarchartSpecificStyleProperties(const JKQTBasePlotterStyle& /*parent*/, const JKQTGraphsSpecificStyleProperties &other): JKQTGraphsSpecificStyleProperties(JKQTPPlotStyleType::Barchart, other), defaultRectRadiusAtValue(0), defaultRectRadiusAtBaseline(0), @@ -478,7 +478,7 @@ JKQTImpulseSpecificStyleProperties::JKQTImpulseSpecificStyleProperties(const JKQ } -JKQTImpulseSpecificStyleProperties::JKQTImpulseSpecificStyleProperties(const JKQTBasePlotterStyle& parent, const JKQTGraphsSpecificStyleProperties &other): +JKQTImpulseSpecificStyleProperties::JKQTImpulseSpecificStyleProperties(const JKQTBasePlotterStyle& /*parent*/, const JKQTGraphsSpecificStyleProperties &other): JKQTGraphsSpecificStyleProperties(JKQTPPlotStyleType::Impulses, other), drawBaseline(false) { @@ -500,8 +500,8 @@ void JKQTImpulseSpecificStyleProperties::saveSettings(QSettings &settings, const -JKQTFillStyleSummmary::JKQTFillStyleSummmary(Qt::BrushStyle style, const QGradient& grad, double rotAngleDeg): - brushStyle(style), gradient(grad), rotationAngleDeg(rotAngleDeg) +JKQTFillStyleSummmary::JKQTFillStyleSummmary(Qt::BrushStyle style, const QGradient& grad): + brushStyle(style), gradient(grad) { } @@ -524,7 +524,7 @@ QBrush JKQTFillStyleSummmary::brush(const QColor &color) const JKQTFillStyleSummmary JKQTFillStyleSummmary::fromString(const QString &style) { JKQTFillStyleSummmary res; - res.brushStyle=jkqtp_String2QBrushStyleExt(style, nullptr, &(res.gradient), &(res.texture), &(res.rotationAngleDeg)); + res.brushStyle=jkqtp_String2QBrushStyleExt(style, &(res.gradient), &(res.texture)); return res; } diff --git a/lib/jkqtplotter/jkqtpgraphsbasestyle.h b/lib/jkqtplotter/jkqtpgraphsbasestyle.h index 27a6a12b8b..317b5e40fc 100644 --- a/lib/jkqtplotter/jkqtpgraphsbasestyle.h +++ b/lib/jkqtplotter/jkqtpgraphsbasestyle.h @@ -49,13 +49,16 @@ class JKQTPLOTTER_LIB_EXPORT JKQTFillStyleSummmary { Q_GADGET #endif public: - JKQTFillStyleSummmary(Qt::BrushStyle style=Qt::SolidPattern, const QGradient& grad=QGradient(), double rotAngleDeg=0.0); + JKQTFillStyleSummmary(Qt::BrushStyle style=Qt::SolidPattern, const QGradient& grad=QGradient()); + /** \brief a brushStyle (e.g. pattern) to use for filling */ Qt::BrushStyle brushStyle; + /** \brief a QGradient to use for filling */ QGradient gradient; + /** \brief a texture to use for filling */ QPixmap texture; - double rotationAngleDeg; + /** \brief constructs a QBrush from the data in this object, possibly using \a color to replace JKQTPlotterDrawingTools::CurrentColorPlaceholder color stops and a color for a pattern defined via e.g. \c brushStyle=Qt::BDiagPattern */ QBrush brush(const QColor& color) const; /** \brief reads object contents from a string representation, e.g. as created by JKQTFillStyleSummmary::toCSSString() */ diff --git a/lib/jkqtplotter/jkqtpgraphsbasestylingmixins.cpp b/lib/jkqtplotter/jkqtpgraphsbasestylingmixins.cpp index f75e025c01..34d108566f 100644 --- a/lib/jkqtplotter/jkqtpgraphsbasestylingmixins.cpp +++ b/lib/jkqtplotter/jkqtpgraphsbasestylingmixins.cpp @@ -315,7 +315,7 @@ QString JKQTPGraphSymbolStyleMixin::getSymbolFontName() const double JKQTPGraphSymbolStyleMixin::getKeySymbolLineWidthPx(JKQTPEnhancedPainter& painter, const QRectF& keyRect, const JKQTBasePlotter *parent, double maxSymbolSizeFracton) const { - const double minSize=qMin(keyRect.width(), keyRect.height()); + //const double minSize=qMin(keyRect.width(), keyRect.height()); double symbolWidth=parent->pt2px(painter, this->getSymbolLineWidth()*parent->getLineWidthMultiplier()); double symbolSize=getKeySymbolSizePx(painter, keyRect, parent, maxSymbolSizeFracton); if (symbolWidth>0.3*symbolSize) symbolWidth=0.3*symbolSize; diff --git a/lib/jkqtplotter/jkqtpkey.cpp b/lib/jkqtplotter/jkqtpkey.cpp index 1378c83ee7..121ded9ac6 100644 --- a/lib/jkqtplotter/jkqtpkey.cpp +++ b/lib/jkqtplotter/jkqtpkey.cpp @@ -189,7 +189,7 @@ JKQTPBaseKey::KeySizeDescription JKQTPBaseKey::getSize(JKQTPEnhancedPainter &pai QFont kf(JKQTMathTextFontSpecifier::fromFontSpec(keyStyle().fontName).fontName(), keyStyle().fontSize); kf.setPointSizeF(keyStyle().fontSize*getParent()->getFontSizeMultiplier()); - const qreal Xwid=JKQTMathTextGetBoundingRect(kf,"X",painter.device()).width(); + //const qreal Xwid=JKQTMathTextGetBoundingRect(kf,"X",painter.device()).width(); // calculate layout of the "table" of samples and labels const KeyLayoutDescription layout=getKeyLayout(painter); @@ -235,7 +235,7 @@ void JKQTPBaseKey::modifySize(JKQTPEnhancedPainter &painter, KeySizeDescription const auto lay=getLayout(); if (lay==JKQTPKeyLayoutMultiColumn || lay==JKQTPKeyLayoutMultiRow) { - std::function fcmpSizeTooLarge=[](const QSizeF& requiredSize, const QSizeF& preliminaryPlotSize) { return true; }; + std::function fcmpSizeTooLarge=[](const QSizeF& /*requiredSize*/, const QSizeF& /*preliminaryPlotSize*/) { return true; }; bool increaseColumnCount=true; bool fillMaxMode=false; diff --git a/lib/jkqtplotter/jkqtpkeystyle.cpp b/lib/jkqtplotter/jkqtpkeystyle.cpp index 07c870e7a7..ab82113b9c 100644 --- a/lib/jkqtplotter/jkqtpkeystyle.cpp +++ b/lib/jkqtplotter/jkqtpkeystyle.cpp @@ -40,8 +40,8 @@ JKQTPKeyStyle::JKQTPKeyStyle(): xOffset(1), yOffset(1), xSeparation(0.85), - columnSeparation(0.75), ySeparation(0.35), + columnSeparation(0.75), position(JKQTPKeyInsideTopRight), layout(JKQTPKeyLayoutOneColumn) { diff --git a/tests/jkqtcommmon/jkqtcommon_test.cpp b/tests/jkqtcommmon/jkqtcommon_test.cpp index bda3827f9c..4b397d94b3 100644 --- a/tests/jkqtcommmon/jkqtcommon_test.cpp +++ b/tests/jkqtcommmon/jkqtcommon_test.cpp @@ -168,21 +168,19 @@ private slots: Qt::BrushStyle bs; QGradient n, g; QLinearGradient lg; - //QPixmap pix; - QColor col; - QVERIFY_THROWS_NO_EXCEPTION(bs=jkqtp_String2QBrushStyleExt("warmflame", &col, &n, nullptr)); + QVERIFY_THROWS_NO_EXCEPTION(bs=jkqtp_String2QBrushStyleExt("warmflame", &n, nullptr)); g = QGradient(QGradient::WarmFlame); g.setCoordinateMode(QGradient::ObjectBoundingMode); QCOMPARE_EQ(n, g); QCOMPARE_EQ(bs, Qt::LinearGradientPattern); - QVERIFY_THROWS_NO_EXCEPTION(bs=jkqtp_String2QBrushStyleExt("d1", &col, &n, nullptr)); + QVERIFY_THROWS_NO_EXCEPTION(bs=jkqtp_String2QBrushStyleExt("d1", &n, nullptr)); QCOMPARE_EQ(bs, Qt::Dense1Pattern); - QVERIFY_THROWS_NO_EXCEPTION(bs=jkqtp_String2QBrushStyleExt("linear-gradient(to left, red, blue)", &col, &n, nullptr)); + QVERIFY_THROWS_NO_EXCEPTION(bs=jkqtp_String2QBrushStyleExt("linear-gradient(to left, red, blue)", &n, nullptr)); lg = QLinearGradient(1,0.5,0,0.5); lg.setCoordinateMode(QGradient::ObjectBoundingMode); lg.setStops({QGradientStop(0, QColor("red")), QGradientStop(1, QColor("blue"))}); diff --git a/tools/jkqtplotter_doc_imagegenerator/jkqtplotter_doc_imagegenerator.cpp b/tools/jkqtplotter_doc_imagegenerator/jkqtplotter_doc_imagegenerator.cpp index 918a151c8b..fc0ea210de 100644 --- a/tools/jkqtplotter_doc_imagegenerator/jkqtplotter_doc_imagegenerator.cpp +++ b/tools/jkqtplotter_doc_imagegenerator/jkqtplotter_doc_imagegenerator.cpp @@ -148,7 +148,7 @@ void doListPalettes(const QDir& outputDir, QSize iconsize) { } -void doListErrorIndicators(const QDir& outputDir, int iconsize, QColor backgroundColor) { +void doListErrorIndicators(const QDir& outputDir, int /*iconsize*/, QColor /*backgroundColor*/) { JKQTBasePlotter plot(true); JKQTPDatastore* ds=plot.getDatastore(); size_t cx=ds->addCopiedColumn(QVector{-1.5,-0.5,0.5,1.5,2.5},"x"); @@ -211,7 +211,7 @@ void doListErrorIndicators(const QDir& outputDir, int iconsize, QColor backgroun } } -void doListAxisStyling(const QDir& outputDir, int iconsize, QColor backgroundColor) { +void doListAxisStyling(const QDir& outputDir, int iconsize, QColor /*backgroundColor*/) { JKQTBasePlotter plot(true); plot.setXY(0,1,0.9,110); @@ -409,7 +409,7 @@ void doListAxisStyling(const QDir& outputDir, int iconsize, QColor backgroundCol plot.grabPixelImage(QSize(plot.getWidth(),plot.getHeight()), false).copy(0,0,plot.getWidth(),plot.getHeight()).save(outputDir.absoluteFilePath("axis_unit_scaling_pi.png"), "png"); } -void doListAxisTickLabelAngles(const QDir& outputDir, int iconsize, QColor backgroundColor) { +void doListAxisTickLabelAngles(const QDir& outputDir, int iconsize, QColor /*backgroundColor*/) { JKQTBasePlotter plot(true); plot.setXY(0,1000,0,1000); @@ -439,7 +439,7 @@ void doListAxisTickLabelAngles(const QDir& outputDir, int iconsize, QColor backg } } -void doListLabelPosition(const QDir& outputDir, int iconsize, QColor backgroundColor) { +void doListLabelPosition(const QDir& outputDir, int iconsize, QColor /*backgroundColor*/) { JKQTBasePlotter plot(true); plot.setXY(0,100,0,100); @@ -526,7 +526,7 @@ void plotStyle(const QSettings& style, QSize examplePlotSize, const QString& exa -void doListStyles(const QDir& outputDir, const QStringList& doctomodify, int iconsize, QColor backgroundColor) { +void doListStyles(const QDir& outputDir, const QStringList& doctomodify, int iconsize, QColor /*backgroundColor*/) { QDir dir(":/JKQTPlotter/styles/", "*.ini"); QString doc; { @@ -622,7 +622,7 @@ inline QString JKQTPKeyPosition2CPPString(JKQTPKeyPosition pos) { } -void doListKeyPositions(const QDir& outputDir, int iconsize, QColor backgroundColor) { +void doListKeyPositions(const QDir& outputDir, int iconsize, QColor /*backgroundColor*/) { JKQTBasePlotter plot(true); plot.setWidgetSize(iconsize,iconsize); @@ -671,7 +671,7 @@ void doListKeyPositions(const QDir& outputDir, int iconsize, QColor backgroundCo } } -void doListKeyLayouts(const QDir& outputDir, int iconsize, QColor backgroundColor) { +void doListKeyLayouts(const QDir& outputDir, int iconsize, QColor /*backgroundColor*/) { JKQTBasePlotter plot(true); plot.setWidgetSize(iconsize*2.0,iconsize);