XYSeries QML Type

A base type for line, spline, and scatter series. 更多...

import 语句: import QtCharts 2.15
实例化: QXYSeries
继承:

AbstractSeries

继承者:

LineSeries , ScatterSeries ,和 SplineSeries

特性

信号

方法

详细描述

特性文档编制

axisAngular : AbstractAxis

The angular axis used for the series, drawn around the polar chart view.

另请参阅 axisX .

axisRadial : AbstractAxis

The radial axis used for the series, drawn inside the polar chart view.

另请参阅 axisY .

axisX : AbstractAxis

The x-axis used for the series. If you leave both axisX and axisXTop undefined, a value axis is created for the series.

另请参阅 axisXTop and ValueAxis .

axisXTop : AbstractAxis

The x-axis used for the series, drawn on top of the chart view.

注意: You can only provide either axisX or axisXTop, not both.

另请参阅 axisX .

axisY : AbstractAxis

The y-axis used for the series. If you leave both axisY and axisYRight undefined, a value axis is created for the series.

另请参阅 axisYRight and ValueAxis .

axisYRight : AbstractAxis

The y-axis used for the series, drawn to the right on the chart view.

注意: You can only provide either axisY or axisYRight, not both.

另请参阅 axisY .

color : color

The color of the series. This is the line (pen) color in case of LineSeries or SplineSeries and the fill (brush) color in case of ScatterSeries or AreaSeries .

pointLabelsClipping : bool

The clipping for data point labels. This property is true by default. The labels on the edge of the plot area are cut when clipping is enabled.

另请参阅 pointLabelsVisible .

pointLabelsColor : font

The color used for data point labels. By default, the color is the color of the brush defined in theme for labels.

另请参阅 pointLabelsFormat .

pointLabelsFont : font

The font used for data point labels.

另请参阅 pointLabelsFormat .

pointLabelsFormat : string

The format used for showing labels with data points.

另请参阅 pointLabelsVisible , pointLabelsFont ,和 pointLabelsColor .

pointLabelsVisible : bool

The visibility of data point labels. This property is false 在默认情况下。

另请参阅 pointLabelsFormat and pointLabelsClipping .

pointsVisible : bool

Whether the data points are visible and should be drawn.

信号文档编制

clicked ( point point )

This signal is emitted when the user triggers a mouse event by clicking the point point in the chart. For example:

LineSeries {
    XYPoint { x: 0; y: 0 }
    XYPoint { x: 1.1; y: 2.1 }
    onClicked: console.log("onClicked: " + point.x + ", " + point.y);
}
					

The corresponding signal handler is onClicked() .

注意: 相应处理程序是 onClicked .

另请参阅 pressed() , released() ,和 doubleClicked() .

doubleClicked ( point point )

This signal is emitted when the user double-clicks the data point point in the chart. The point is the point where the first press was triggered. For example:

LineSeries {
    XYPoint { x: 0; y: 0 }
    XYPoint { x: 1.1; y: 2.1 }
    onDoubleClicked: console.log("onDoubleClicked: " + point.x + ", " + point.y);
}
					

The corresponding signal handler is onDoubleClicked() .

注意: 相应处理程序是 onDoubleClicked .

另请参阅 pressed() , released() ,和 clicked() .

hovered ( point point , bool state )

This signal is emitted when a mouse is hovered over the point point in the chart. When the mouse moves over the point, state turns true , and when the mouse moves away again, it turns false .

The corresponding signal handler is onHovered() .

注意: 相应处理程序是 onHovered .

pointAdded ( int index )

This signal is emitted when a point is added at the position specified by index .

The corresponding signal handler is onPointAdded() .

注意: 相应处理程序是 onPointAdded .

pointRemoved ( int index )

This signal is emitted when a point is removed from the position specified by index .

The corresponding signal handler is onPointRemoved() .

注意: 相应处理程序是 onPointRemoved .

pointReplaced ( int index )

This signal is emitted when a point is replaced at the position specified by index .

The corresponding signal handler is onPointReplaced() .

注意: 相应处理程序是 onPointReplaced .

pointsRemoved ( int index , int count )

This signal is emitted when the number of points specified by count is removed starting at the position specified by index .

The corresponding signal handler is onPointRemoved() .

注意: 相应处理程序是 onPointsRemoved .

pointsReplaced ()

This signal is emitted when all points are replaced with other points.

The corresponding signal handler is onPointsReplaced() .

注意: 相应处理程序是 onPointsReplaced .

pressed ( point point )

This signal is emitted when the user presses the data point point in the chart and holds down the mouse button. For example:

LineSeries {
    XYPoint { x: 0; y: 0 }
    XYPoint { x: 1.1; y: 2.1 }
    onPressed: console.log("onPressed: " + point.x + ", " + point.y);
}
					

The corresponding signal handler is onPressed() .

注意: 相应处理程序是 onPressed .

另请参阅 clicked() , released() ,和 doubleClicked() .

released ( point point )

This signal is emitted when the user releases the mouse press on the data point specified by point 。例如:

LineSeries {
    XYPoint { x: 0; y: 0 }
    XYPoint { x: 1.1; y: 2.1 }
    onReleased: console.log("onReleased: " + point.x + ", " + point.y);
}
					

The corresponding signal handler is onReleased() .

注意: 相应处理程序是 onReleased .

另请参阅 pressed() , clicked() ,和 doubleClicked() .

方法文档编制

append ( real x , real y )

Appends a point with the coordinates x and y 到系列。

QPointF at ( int index )

Returns the point at the position specified by index . Returns (0, 0) if the index is not valid.

insert ( int index , real x , real y )

Inserts a point with the coordinates x and y to the position specified by index in the series. If the index is 0 or less than 0, the point is prepended to the list of points. If the index is equal to or greater than than the number of points in the series, the point is appended to the list of points.

remove ( int index )

Removes the point at the position specified by index from the series.

remove ( real x , real y )

Removes the point with the coordinates x and y from the series. Does nothing if the point does not exist.

removePoints ( int index , int count )

Removes the number of points specified by count from the series starting at the position specified by index .

replace ( real oldX , real oldY , real newX , real newY )

Replaces the point with the coordinates oldX and oldY with the point with the coordinates newX and newY . Does nothing if the old point does not exist.