There are two overloads for QStringList and QVector<QString> (#3977)

These are not required in Qt6, as QStringList is an QVector<QString>
This commit is contained in:
Andreas Buhr
2024-01-12 00:22:20 +01:00
committed by GitHub
parent 408709c1d6
commit 466bdf1939
2 changed files with 7 additions and 0 deletions

View File

@@ -151,6 +151,8 @@ GenericChart::addCurve(QString name, QVector<double> xseries, QVector<double> ys
return true;
}
#if QT_VERSION < 0x060000
// In Qt 6, QStringList is a QVector<QString>, so we don't need an additional overload
// helper for python - no aggregateby, no annotations
bool
GenericChart::addCurve(QString name, QVector<double> xseries, QVector<double> yseries, QStringList fseries, QString xname, QString yname,
@@ -163,6 +165,7 @@ GenericChart::addCurve(QString name, QVector<double> xseries, QVector<double> ys
opengl, legend, datalabels, fill, RideMetric::Average, QList<GenericAnnotationInfo>());
return true;
}
#endif
// configure axis, after curves added
bool

View File

@@ -319,10 +319,14 @@ class GenericChart : public QWidget {
int line, int symbol, int size, QString color, int opacity, bool opengl, bool legend, bool datalabels,
bool fill, RideMetric::MetricType mtype, QList<GenericAnnotationInfo>annotations);
#if QT_VERSION < 0x060000
// In Qt 6, QStringList is a QVector<QString>, so we don't need an additional overload
// helper for Python and R charts fseries is a stringlist
bool addCurve(QString name, QVector<double> xseries, QVector<double> yseries, QStringList fseries, QString xname, QString yname,
QStringList labels, QStringList colors,
int line, int symbol, int size, QString color, int opacity, bool opengl, bool legend, bool datalabels, bool fill);
#endif
// configure axis, after curves added
bool configureAxis(QString name, bool visible, int align, double min, double max,