Source

Target

Commits (5)
Showing with 77 additions and 290 deletions
...@@ -140,19 +140,23 @@ QT_CHARTS_BEGIN_NAMESPACE ...@@ -140,19 +140,23 @@ QT_CHARTS_BEGIN_NAMESPACE
/*! /*!
\property QValueAxis::tickAnchor \property QValueAxis::tickAnchor
\since 5.12
\brief The base value where the dynamically placed tick marks and labels are started from. \brief The base value where the dynamically placed tick marks and labels are started from.
*/ */
/*! /*!
\qmlproperty real ValueAxis::tickAnchor \qmlproperty real ValueAxis::tickAnchor
\since QtCharts 2.3
The base value where the dynamically placed tick marks and labels are started from. The base value where the dynamically placed tick marks and labels are started from.
*/ */
/*! /*!
\property QValueAxis::tickInterval \property QValueAxis::tickInterval
\since 5.12
\brief The interval between dynamically placed tick marks and labels. \brief The interval between dynamically placed tick marks and labels.
*/ */
/*! /*!
\qmlproperty real ValueAxis::tickInterval \qmlproperty real ValueAxis::tickInterval
\since QtCharts 2.3
The interval between dynamically placed tick marks and labels. The interval between dynamically placed tick marks and labels.
*/ */
...@@ -167,10 +171,12 @@ QT_CHARTS_BEGIN_NAMESPACE ...@@ -167,10 +171,12 @@ QT_CHARTS_BEGIN_NAMESPACE
*/ */
/*! /*!
\property QValueAxis::tickType \property QValueAxis::tickType
\since 5.12
\brief The positioning method of tick and labels. \brief The positioning method of tick and labels.
*/ */
/*! /*!
\qmlproperty enumeration ValueAxis::tickType \qmlproperty enumeration ValueAxis::tickType
\since QtCharts 2.3
The positioning method of tick and labels. The positioning method of tick and labels.
......
...@@ -406,7 +406,9 @@ void LineChartItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *opt ...@@ -406,7 +406,9 @@ void LineChartItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *opt
painter->drawPath(m_linePath); painter->drawPath(m_linePath);
} else { } else {
painter->setBrush(QBrush(Qt::NoBrush)); painter->setBrush(QBrush(Qt::NoBrush));
if (m_linePen.style() != Qt::SolidLine || alwaysUsePath) { if (m_linePen.style() != Qt::SolidLine
|| painter->renderHints().testFlag(QPainter::Antialiasing)
|| alwaysUsePath) {
// If pen style is not solid line, always fall back to path painting // If pen style is not solid line, always fall back to path painting
// to ensure proper continuity of the pattern // to ensure proper continuity of the pattern
painter->drawPath(m_linePath); painter->drawPath(m_linePath);
......
...@@ -130,7 +130,7 @@ void QChartView::setRubberBand(const RubberBands &rubberBand) ...@@ -130,7 +130,7 @@ void QChartView::setRubberBand(const RubberBands &rubberBand)
if (!d_ptr->m_rubberBandFlags) { if (!d_ptr->m_rubberBandFlags) {
delete d_ptr->m_rubberBand; delete d_ptr->m_rubberBand;
d_ptr->m_rubberBand = 0; d_ptr->m_rubberBand = nullptr;
return; return;
} }
...@@ -277,7 +277,7 @@ QChartViewPrivate::QChartViewPrivate(QChartView *q, QChart *chart) ...@@ -277,7 +277,7 @@ QChartViewPrivate::QChartViewPrivate(QChartView *q, QChart *chart)
m_scene(new QGraphicsScene(q)), m_scene(new QGraphicsScene(q)),
m_chart(chart), m_chart(chart),
#ifndef QT_NO_RUBBERBAND #ifndef QT_NO_RUBBERBAND
m_rubberBand(0), m_rubberBand(nullptr),
#endif #endif
m_rubberBandFlags(QChartView::NoRubberBand) m_rubberBandFlags(QChartView::NoRubberBand)
{ {
...@@ -331,7 +331,8 @@ void QChartViewPrivate::resize() ...@@ -331,7 +331,8 @@ void QChartViewPrivate::resize()
} }
m_chart->resize(chartSize); m_chart->resize(chartSize);
q_ptr->setMinimumSize(m_chart->minimumSize().toSize()); q_ptr->setMinimumSize(m_chart->minimumSize().toSize().expandedTo(q_ptr->minimumSize()));
q_ptr->setMaximumSize(q_ptr->maximumSize().boundedTo(m_chart->maximumSize().toSize()));
q_ptr->setSceneRect(m_chart->geometry()); q_ptr->setSceneRect(m_chart->geometry());
} }
......
...@@ -56,6 +56,9 @@ contains(QT_CONFIG, opengl) { ...@@ -56,6 +56,9 @@ contains(QT_CONFIG, opengl) {
HEADERS += $$PRIVATE_HEADERS HEADERS += $$PRIVATE_HEADERS
INCLUDEPATH += $$PWD INCLUDEPATH += $$PWD
IMPORT_VERSION = 2.3
QMAKE_QMLPLUGINDUMP_FLAGS = -qapp
load(qml_plugin) load(qml_plugin)
win32 { win32 {
......
...@@ -4,280 +4,10 @@ import QtQuick.tooling 1.2 ...@@ -4,280 +4,10 @@ import QtQuick.tooling 1.2
// It is used for QML tooling purposes only. // It is used for QML tooling purposes only.
// //
// This file was auto-generated by: // This file was auto-generated by:
// 'qmlplugindump -nonrelocatable QtCharts 2.0' // 'qmlplugindump -nonrelocatable -qapp QtCharts 2.3'
Module { Module {
dependencies: [] dependencies: ["QtQuick 2.12"]
Component {
name: "QAbstractItemModel"
prototype: "QObject"
exports: [
"QtCharts/AbstractItemModel 1.0",
"QtCharts/AbstractItemModel 2.0"
]
isCreatable: false
exportMetaObjectRevisions: [0, 0]
Enum {
name: "LayoutChangeHint"
values: {
"NoLayoutChangeHint": 0,
"VerticalSortHint": 1,
"HorizontalSortHint": 2
}
}
Signal {
name: "dataChanged"
Parameter { name: "topLeft"; type: "QModelIndex" }
Parameter { name: "bottomRight"; type: "QModelIndex" }
Parameter { name: "roles"; type: "QVector<int>" }
}
Signal {
name: "dataChanged"
Parameter { name: "topLeft"; type: "QModelIndex" }
Parameter { name: "bottomRight"; type: "QModelIndex" }
}
Signal {
name: "headerDataChanged"
Parameter { name: "orientation"; type: "Qt::Orientation" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "layoutChanged"
Parameter { name: "parents"; type: "QList<QPersistentModelIndex>" }
Parameter { name: "hint"; type: "QAbstractItemModel::LayoutChangeHint" }
}
Signal {
name: "layoutChanged"
Parameter { name: "parents"; type: "QList<QPersistentModelIndex>" }
}
Signal { name: "layoutChanged" }
Signal {
name: "layoutAboutToBeChanged"
Parameter { name: "parents"; type: "QList<QPersistentModelIndex>" }
Parameter { name: "hint"; type: "QAbstractItemModel::LayoutChangeHint" }
}
Signal {
name: "layoutAboutToBeChanged"
Parameter { name: "parents"; type: "QList<QPersistentModelIndex>" }
}
Signal { name: "layoutAboutToBeChanged" }
Signal {
name: "rowsAboutToBeInserted"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "rowsInserted"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "rowsAboutToBeRemoved"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "rowsRemoved"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "columnsAboutToBeInserted"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "columnsInserted"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "columnsAboutToBeRemoved"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal {
name: "columnsRemoved"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "first"; type: "int" }
Parameter { name: "last"; type: "int" }
}
Signal { name: "modelAboutToBeReset" }
Signal { name: "modelReset" }
Signal {
name: "rowsAboutToBeMoved"
Parameter { name: "sourceParent"; type: "QModelIndex" }
Parameter { name: "sourceStart"; type: "int" }
Parameter { name: "sourceEnd"; type: "int" }
Parameter { name: "destinationParent"; type: "QModelIndex" }
Parameter { name: "destinationRow"; type: "int" }
}
Signal {
name: "rowsMoved"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "start"; type: "int" }
Parameter { name: "end"; type: "int" }
Parameter { name: "destination"; type: "QModelIndex" }
Parameter { name: "row"; type: "int" }
}
Signal {
name: "columnsAboutToBeMoved"
Parameter { name: "sourceParent"; type: "QModelIndex" }
Parameter { name: "sourceStart"; type: "int" }
Parameter { name: "sourceEnd"; type: "int" }
Parameter { name: "destinationParent"; type: "QModelIndex" }
Parameter { name: "destinationColumn"; type: "int" }
}
Signal {
name: "columnsMoved"
Parameter { name: "parent"; type: "QModelIndex" }
Parameter { name: "start"; type: "int" }
Parameter { name: "end"; type: "int" }
Parameter { name: "destination"; type: "QModelIndex" }
Parameter { name: "column"; type: "int" }
}
Method { name: "submit"; type: "bool" }
Method { name: "revert" }
Method {
name: "hasIndex"
type: "bool"
Parameter { name: "row"; type: "int" }
Parameter { name: "column"; type: "int" }
Parameter { name: "parent"; type: "QModelIndex" }
}
Method {
name: "hasIndex"
type: "bool"
Parameter { name: "row"; type: "int" }
Parameter { name: "column"; type: "int" }
}
Method {
name: "index"
type: "QModelIndex"
Parameter { name: "row"; type: "int" }
Parameter { name: "column"; type: "int" }
Parameter { name: "parent"; type: "QModelIndex" }
}
Method {
name: "index"
type: "QModelIndex"
Parameter { name: "row"; type: "int" }
Parameter { name: "column"; type: "int" }
}
Method {
name: "parent"
type: "QModelIndex"
Parameter { name: "child"; type: "QModelIndex" }
}
Method {
name: "sibling"
type: "QModelIndex"
Parameter { name: "row"; type: "int" }
Parameter { name: "column"; type: "int" }
Parameter { name: "idx"; type: "QModelIndex" }
}
Method {
name: "rowCount"
type: "int"
Parameter { name: "parent"; type: "QModelIndex" }
}
Method { name: "rowCount"; type: "int" }
Method {
name: "columnCount"
type: "int"
Parameter { name: "parent"; type: "QModelIndex" }
}
Method { name: "columnCount"; type: "int" }
Method {
name: "hasChildren"
type: "bool"
Parameter { name: "parent"; type: "QModelIndex" }
}
Method { name: "hasChildren"; type: "bool" }
Method {
name: "data"
type: "QVariant"
Parameter { name: "index"; type: "QModelIndex" }
Parameter { name: "role"; type: "int" }
}
Method {
name: "data"
type: "QVariant"
Parameter { name: "index"; type: "QModelIndex" }
}
Method {
name: "setData"
type: "bool"
Parameter { name: "index"; type: "QModelIndex" }
Parameter { name: "value"; type: "QVariant" }
Parameter { name: "role"; type: "int" }
}
Method {
name: "setData"
type: "bool"
Parameter { name: "index"; type: "QModelIndex" }
Parameter { name: "value"; type: "QVariant" }
}
Method {
name: "headerData"
type: "QVariant"
Parameter { name: "section"; type: "int" }
Parameter { name: "orientation"; type: "Qt::Orientation" }
Parameter { name: "role"; type: "int" }
}
Method {
name: "headerData"
type: "QVariant"
Parameter { name: "section"; type: "int" }
Parameter { name: "orientation"; type: "Qt::Orientation" }
}
Method {
name: "fetchMore"
Parameter { name: "parent"; type: "QModelIndex" }
}
Method {
name: "canFetchMore"
type: "bool"
Parameter { name: "parent"; type: "QModelIndex" }
}
Method {
name: "flags"
type: "Qt::ItemFlags"
Parameter { name: "index"; type: "QModelIndex" }
}
Method {
name: "match"
type: "QModelIndexList"
Parameter { name: "start"; type: "QModelIndex" }
Parameter { name: "role"; type: "int" }
Parameter { name: "value"; type: "QVariant" }
Parameter { name: "hits"; type: "int" }
Parameter { name: "flags"; type: "Qt::MatchFlags" }
}
Method {
name: "match"
type: "QModelIndexList"
Parameter { name: "start"; type: "QModelIndex" }
Parameter { name: "role"; type: "int" }
Parameter { name: "value"; type: "QVariant" }
Parameter { name: "hits"; type: "int" }
}
Method {
name: "match"
type: "QModelIndexList"
Parameter { name: "start"; type: "QModelIndex" }
Parameter { name: "role"; type: "int" }
Parameter { name: "value"; type: "QVariant" }
}
}
Component { Component {
name: "QGraphicsObject" name: "QGraphicsObject"
defaultProperty: "children" defaultProperty: "children"
...@@ -919,14 +649,14 @@ Module { ...@@ -919,14 +649,14 @@ Module {
"SeriesTypeBar": 2, "SeriesTypeBar": 2,
"SeriesTypeStackedBar": 3, "SeriesTypeStackedBar": 3,
"SeriesTypePercentBar": 4, "SeriesTypePercentBar": 4,
"SeriesTypeBoxPlot": 5, "SeriesTypePie": 5,
"SeriesTypeCandlestick": 6, "SeriesTypeScatter": 6,
"SeriesTypePie": 7, "SeriesTypeSpline": 7,
"SeriesTypeScatter": 8, "SeriesTypeHorizontalBar": 8,
"SeriesTypeSpline": 9, "SeriesTypeHorizontalStackedBar": 9,
"SeriesTypeHorizontalBar": 10, "SeriesTypeHorizontalPercentBar": 10,
"SeriesTypeHorizontalStackedBar": 11, "SeriesTypeBoxPlot": 11,
"SeriesTypeHorizontalPercentBar": 12 "SeriesTypeCandlestick": 12
} }
} }
Property { name: "theme"; type: "Theme" } Property { name: "theme"; type: "Theme" }
...@@ -948,7 +678,7 @@ Module { ...@@ -948,7 +678,7 @@ Module {
isReadonly: true isReadonly: true
isPointer: true isPointer: true
} }
Property { name: "plotArea"; revision: 1; type: "QRectF"; isReadonly: true } Property { name: "plotArea"; revision: 1; type: "QRectF" }
Property { name: "plotAreaColor"; revision: 3; type: "QColor" } Property { name: "plotAreaColor"; revision: 3; type: "QColor" }
Property { name: "axes"; revision: 2; type: "QAbstractAxis"; isList: true; isReadonly: true } Property { name: "axes"; revision: 2; type: "QAbstractAxis"; isList: true; isReadonly: true }
Property { name: "localizeNumbers"; revision: 4; type: "bool" } Property { name: "localizeNumbers"; revision: 4; type: "bool" }
...@@ -1959,6 +1689,11 @@ Module { ...@@ -1959,6 +1689,11 @@ Module {
Property { name: "x"; type: "double" } Property { name: "x"; type: "double" }
Property { name: "y"; type: "double" } Property { name: "y"; type: "double" }
} }
Component {
name: "QtCharts::LegendScroller"
defaultProperty: "children"
prototype: "QtCharts::QLegend"
}
Component { Component {
name: "QtCharts::QAbstractAxis" name: "QtCharts::QAbstractAxis"
prototype: "QObject" prototype: "QObject"
...@@ -2121,6 +1856,7 @@ Module { ...@@ -2121,6 +1856,7 @@ Module {
Property { name: "labelsFormat"; type: "string" } Property { name: "labelsFormat"; type: "string" }
Property { name: "labelsPosition"; type: "LabelsPosition" } Property { name: "labelsPosition"; type: "LabelsPosition" }
Property { name: "labelsAngle"; type: "double" } Property { name: "labelsAngle"; type: "double" }
Property { name: "labelsPrecision"; type: "int" }
Signal { Signal {
name: "clicked" name: "clicked"
Parameter { name: "index"; type: "int" } Parameter { name: "index"; type: "int" }
...@@ -2159,6 +1895,10 @@ Module { ...@@ -2159,6 +1895,10 @@ Module {
name: "labelsAngleChanged" name: "labelsAngleChanged"
Parameter { name: "angle"; type: "double" } Parameter { name: "angle"; type: "double" }
} }
Signal {
name: "labelsPrecisionChanged"
Parameter { name: "precision"; type: "int" }
}
Signal { Signal {
name: "barsetsAdded" name: "barsetsAdded"
Parameter { name: "sets"; type: "QList<QBarSet*>" } Parameter { name: "sets"; type: "QList<QBarSet*>" }
...@@ -2652,6 +2392,15 @@ Module { ...@@ -2652,6 +2392,15 @@ Module {
exports: ["QtCharts/Legend 1.0", "QtCharts/Legend 2.0"] exports: ["QtCharts/Legend 1.0", "QtCharts/Legend 2.0"]
isCreatable: false isCreatable: false
exportMetaObjectRevisions: [0, 0] exportMetaObjectRevisions: [0, 0]
Enum {
name: "MarkerShape"
values: {
"MarkerShapeDefault": 0,
"MarkerShapeRectangle": 1,
"MarkerShapeCircle": 2,
"MarkerShapeFromSeries": 3
}
}
Property { name: "alignment"; type: "Qt::Alignment" } Property { name: "alignment"; type: "Qt::Alignment" }
Property { name: "backgroundVisible"; type: "bool" } Property { name: "backgroundVisible"; type: "bool" }
Property { name: "color"; type: "QColor" } Property { name: "color"; type: "QColor" }
...@@ -2660,6 +2409,7 @@ Module { ...@@ -2660,6 +2409,7 @@ Module {
Property { name: "labelColor"; type: "QColor" } Property { name: "labelColor"; type: "QColor" }
Property { name: "reverseMarkers"; type: "bool" } Property { name: "reverseMarkers"; type: "bool" }
Property { name: "showToolTips"; type: "bool" } Property { name: "showToolTips"; type: "bool" }
Property { name: "markerShape"; type: "MarkerShape" }
Signal { Signal {
name: "backgroundVisibleChanged" name: "backgroundVisibleChanged"
Parameter { name: "visible"; type: "bool" } Parameter { name: "visible"; type: "bool" }
...@@ -2688,6 +2438,10 @@ Module { ...@@ -2688,6 +2438,10 @@ Module {
name: "showToolTipsChanged" name: "showToolTipsChanged"
Parameter { name: "showToolTips"; type: "bool" } Parameter { name: "showToolTips"; type: "bool" }
} }
Signal {
name: "markerShapeChanged"
Parameter { name: "shape"; type: "MarkerShape" }
}
} }
Component { name: "QtCharts::QLineSeries"; prototype: "QtCharts::QXYSeries" } Component { name: "QtCharts::QLineSeries"; prototype: "QtCharts::QXYSeries" }
Component { Component {
...@@ -2699,6 +2453,8 @@ Module { ...@@ -2699,6 +2453,8 @@ Module {
Property { name: "max"; type: "double" } Property { name: "max"; type: "double" }
Property { name: "labelFormat"; type: "string" } Property { name: "labelFormat"; type: "string" }
Property { name: "base"; type: "double" } Property { name: "base"; type: "double" }
Property { name: "tickCount"; type: "int"; isReadonly: true }
Property { name: "minorTickCount"; type: "int" }
Signal { Signal {
name: "minChanged" name: "minChanged"
Parameter { name: "min"; type: "double" } Parameter { name: "min"; type: "double" }
...@@ -2720,6 +2476,14 @@ Module { ...@@ -2720,6 +2476,14 @@ Module {
name: "baseChanged" name: "baseChanged"
Parameter { name: "base"; type: "double" } Parameter { name: "base"; type: "double" }
} }
Signal {
name: "tickCountChanged"
Parameter { name: "tickCount"; type: "int" }
}
Signal {
name: "minorTickCountChanged"
Parameter { name: "minorTickCount"; type: "int" }
}
} }
Component { name: "QtCharts::QPercentBarSeries"; prototype: "QtCharts::QAbstractBarSeries" } Component { name: "QtCharts::QPercentBarSeries"; prototype: "QtCharts::QAbstractBarSeries" }
Component { Component {
...@@ -2935,17 +2699,25 @@ Module { ...@@ -2935,17 +2699,25 @@ Module {
exports: [ exports: [
"QtCharts/ValueAxis 1.1", "QtCharts/ValueAxis 1.1",
"QtCharts/ValueAxis 2.0", "QtCharts/ValueAxis 2.0",
"QtCharts/ValueAxis 2.3",
"QtCharts/ValuesAxis 1.0" "QtCharts/ValuesAxis 1.0"
] ]
exportMetaObjectRevisions: [0, 0, 0] exportMetaObjectRevisions: [0, 0, 1, 0]
Enum {
name: "TickType"
values: {
"TicksDynamic": 0,
"TicksFixed": 1
}
}
Property { name: "tickCount"; type: "int" } Property { name: "tickCount"; type: "int" }
Property { name: "min"; type: "double" } Property { name: "min"; type: "double" }
Property { name: "max"; type: "double" } Property { name: "max"; type: "double" }
Property { name: "labelFormat"; type: "string" } Property { name: "labelFormat"; type: "string" }
Property { name: "minorTickCount"; type: "int" } Property { name: "minorTickCount"; type: "int" }
Property { name: "tickInterval"; type: "double" } Property { name: "tickAnchor"; revision: 1; type: "double" }
Property { name: "tickAnchor"; type: "double" } Property { name: "tickInterval"; revision: 1; type: "double" }
Property { name: "tickType"; type: "TickType" } Property { name: "tickType"; revision: 1; type: "TickType" }
Signal { Signal {
name: "minChanged" name: "minChanged"
Parameter { name: "min"; type: "double" } Parameter { name: "min"; type: "double" }
...@@ -2973,15 +2745,18 @@ Module { ...@@ -2973,15 +2745,18 @@ Module {
} }
Signal { Signal {
name: "tickIntervalChanged" name: "tickIntervalChanged"
revision: 1
Parameter { name: "interval"; type: "double" } Parameter { name: "interval"; type: "double" }
} }
Signal { Signal {
name: "tickAnchorChanged" name: "tickAnchorChanged"
revision: 1
Parameter { name: "anchor"; type: "double" } Parameter { name: "anchor"; type: "double" }
} }
Signal { Signal {
name: "tickTypeChanged" name: "tickTypeChanged"
Parameter { name: "type"; type: "TickType" } revision: 1
Parameter { name: "type"; type: "QValueAxis::TickType" }
} }
Method { name: "applyNiceNumbers" } Method { name: "applyNiceNumbers" }
} }
......