Update GraphsView documentation

Update the GraphsTheme changes and axis locations.

Task-number: QTBUG-130649
Change-Id: I35c4abcc68b5fd17866f06059d1eff356601c6fd
Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
Reviewed-by: Kwanghyo Park <kwanghyo.park@qt.io>
(cherry picked from commit 28b42fcdd6)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
Kaj Grönholm 2024-10-29 10:52:32 +02:00 committed by Qt Cherry-pick Bot
parent 0165fbdfe2
commit 0b832fd03e
3 changed files with 18 additions and 16 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.4 KiB

After

Width:  |  Height:  |  Size: 14 KiB

View File

@ -168,23 +168,25 @@ import QtGraphs
GraphsView {
anchors.fill: parent
theme: GraphTheme {
colorTheme: GraphTheme.ColorThemeDark
gridMajorBarsColor: "#ccccff"
gridMinorBarsColor: "#eeeeff"
axisYMajorColor: "#ccccff"
axisYMinorColor: "#eeeeff"
theme: GraphsTheme {
colorScheme: GraphsTheme.ColorScheme.Dark
seriesColors: ["#E0D080", "#B0A060"]
borderColors: ["#807040", "#706030"]
grid.mainColor: "#ccccff"
grid.subColor: "#eeeeff"
axisY.mainColor: "#ccccff"
axisY.subColor: "#eeeeff"
}
axisX: BarCategoryAxis {
categories: ["2023", "2024", "2025"]
lineVisible: false
}
axisY: ValueAxis {
min: 0
max: 10
subTickCount: 4
}
BarSeries {
axisX: BarCategoryAxis {
categories: ["2023", "2024", "2025"]
lineVisible: false
}
axisY: ValueAxis {
min: 0
max: 10
minorTickCount: 4
}
BarSet {
values: [7, 6, 9]
}

View File

@ -799,7 +799,7 @@ void QGraphsView::clearSeriesFunc(QQmlListProperty<QObject> *list)
}
/*!
\qmlproperty GraphTheme GraphsView::theme
\qmlproperty GraphsTheme GraphsView::theme
The theme used by the graph. Determines coloring,
axis lines, fonts etc. If theme has not been set,
the default theme is used.