LineSeries QML Type
Visualizza i dati tramite grafici a linee. Altro...
| Import Statement: | import QtCharts 2.12 |
| In C++: | QLineSeries |
| Inherits: | |
| Status: | Deprecated |
Questo tipo è deprecato. Si sconsiglia vivamente di utilizzarlo nel nuovo codice.
Proprietà
Descrizione dettagliata
Un grafico a linee viene utilizzato per rappresentare le informazioni come una serie di punti dati collegati da linee rette.
Il seguente esempio QML mostra come creare un semplice grafico a linee:
ChartView {
title: "Line Chart"
anchors.fill: parent
antialiasing: true
LineSeries {
name: "Line"
XYPoint { x: 0; y: 0 }
XYPoint { x: 1.1; y: 2.1 }
XYPoint { x: 1.9; y: 3.3 }
XYPoint { x: 2.1; y: 2.1 }
XYPoint { x: 2.9; y: 4.9 }
XYPoint { x: 3.4; y: 3.0 }
XYPoint { x: 4.1; y: 3.3 }
}
}
Documentazione delle proprietà
capStyle : Qt::PenCapStyle
Controlla lo stile delle estremità della linea. Impostare su uno dei seguenti valori: Qt.FlatCap, Qt.SquareCap o Qt.RoundCap. Per impostazione predefinita, lo stile delle estremità è Qt.SquareCap.
Vedi anche Qt::PenCapStyle.
count : int
Il numero di valori della serie.
style : Qt::PenStyle
Controlla lo stile della linea. Impostare su uno dei seguenti valori: Qt.NoPen, Qt.SolidLine, Qt.DashLine, Qt.DotLine, Qt.DashDotLine o Qt.DashDotDotLine. L'uso di Qt.CustomDashLine non è supportato nell'API QML. Per impostazione predefinita, lo stile è Qt.SolidLine.
Vedi anche Qt::PenStyle.
width : real
La larghezza della linea. Per impostazione predefinita, la larghezza è 2,0.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.