ScatterSeries QML Type
Der Typ „ScatterSeries“ stellt Daten in Streudiagrammen dar. Mehr...
| Import Statement: | import QtCharts 2.12 |
| In C++: | QScatterSeries |
| Inherits: | |
| Status: | Deprecated |
Dieser Typ ist veraltet. Wir raten dringend davon ab, ihn in neuem Code zu verwenden.
Eigenschaften
- borderColor : color
- borderWidth : real
- brush : brush
- brushFilename : string
- count : int
- markerShape : enumeration
- markerSize : real
Ausführliche Beschreibung
Die Streudaten werden im Diagramm als eine Ansammlung von Punkten dargestellt. Für jeden Punkt werden zwei Werte angegeben, die seine Position auf der horizontalen und der vertikalen Achse bestimmen.

Der folgende QML-Code zeigt, wie man ein Diagramm mit zwei einfachen Streudiagrammreihen erstellt:
ChartView {
title: "Scatter Chart"
anchors.fill: parent
antialiasing: true
ScatterSeries {
id: scatter1
name: "Scatter A"
XYPoint { x: 1.5; y: 1.5 }
XYPoint { x: 1.5; y: 1.6 }
XYPoint { x: 1.57; y: 1.55 }
XYPoint { x: 1.8; y: 1.8 }
XYPoint { x: 1.9; y: 1.6 }
XYPoint { x: 2.1; y: 1.3 }
XYPoint { x: 2.5; y: 2.1 }
}
ScatterSeries {
name: "Scatter B"
XYPoint { x: 2.0; y: 2.0 }
XYPoint { x: 2.0; y: 2.1 }
XYPoint { x: 2.07; y: 2.05 }
XYPoint { x: 2.2; y: 2.9 }
XYPoint { x: 2.4; y: 2.7 }
XYPoint { x: 2.67; y: 2.65 }
}
}Weitere Informationen finden Sie unter „Diagramme mit QML-Galerie“.
Dokumentation zu den Eigenschaften
borderColor : color
Die Farbe, die zum Zeichnen der Markierungsränder verwendet wird.
borderWidth : real
Die Breite der Rahmenlinie. Standardmäßig beträgt die Breite 2,0.
brush : brush
Der Pinsel, mit dem die Markierungen der Streureihe gezeichnet wurden.
brushFilename : string
Der Name der Datei, die als Pinsel für die Serie verwendet wird.
count : int
Die Anzahl der Datenpunkte in der Reihe.
markerShape : enumeration
Die Form, die beim Darstellen von Markierungselementen verwendet wird:
| Konstante | Beschreibung |
|---|---|
ScatterSeries.MarkerShapeCircle | Die Markierung ist ein Kreis. Dies ist der Standardwert. |
ScatterSeries.MarkerShapeRectangle | Die Markierung ist ein Rechteck. |
markerSize : real
Die Größe des Markers, der zum Darstellen der Punkte in der Reihe verwendet wird.
© 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.