PySide6.QtGraphs.QLineSeries

class QLineSeries

The QLineSeries class presents data in line graphs.

Details

A line graph is used to show information as a series of data points connected by straight lines or steps.

Inheritance diagram of PySide6.QtGraphs.QLineSeries

Synopsis

Properties

Methods

Signals

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

class LineStyle

Represents the line style of the series.

Constant

Description

QLineSeries.LineStyle.LineStyle.Straight

The points are connected by a straight line.

QLineSeries.LineStyle.LineStyle.StepLeft

The points are connected by steps where each step height is the value from the left.

QLineSeries.LineStyle.LineStyle.StepRight

The points are connected by steps where each step height is the value from the right.

QLineSeries.LineStyle.LineStyle.StepCenter

The points are connected by steps which change in the middle between two values.

Added in version 6.11.

class StrokeStyle

Represents the stroke style of the series. The default value is StrokeStyle.SolidLine.

Constant

Description

QLineSeries.StrokeStyle.StrokeStyle.SolidLine

A plain line.

QLineSeries.StrokeStyle.StrokeStyle.DashLine

Dashes separated by a few pixels.

Added in version 6.11.

Note

Properties can be used directly when from __feature__ import true_property is used or via accessor functions otherwise.

property capStyleᅟ: Qt.PenCapStyle

This property holds the cap style used for line endings..

The default value is Qt.SquareCap.

Access functions:
property dashOffsetᅟ: float

This property holds the dash offset when strokeStyle is set to DashLine ..

Access functions:
property dashPatternᅟ: list of qreal

This property holds the dash pattern when strokeStyle is set to DashLine ..

Access functions:
property joinStyleᅟ: Qt.PenJoinStyle

This property holds the join style used for line endings..

The default value is Qt.BevelJoin.

Access functions:
property lineStyleᅟ: QLineSeries.LineStyle

This property holds the line style used for lines rendering..

The default value is Straight .

Access functions:
property strokeStyleᅟ: QLineSeries.StrokeStyle

This property holds the stroke style of the series..

The default value is SolidLine .

Access functions:
property widthᅟ: float

This property holds the width of the line in the series..

This property holds the pen width used to draw the series line.

Access functions:
__init__([parent=None])
Parameters:

parentQObject

capStyle()
Return type:

PenCapStyle

See also

setCapStyle()

Getter of property capStyleᅟ .

capStyleChanged()

Notification signal of property capStyleᅟ .

dashOffset()
Return type:

float

See also

setDashOffset()

Getter of property dashOffsetᅟ .

dashOffsetChanged(newDashOffset)
Parameters:

newDashOffset – float

Notification signal of property dashOffsetᅟ .

dashPattern()
Return type:

.list of qreal

See also

setDashPattern()

Getter of property dashPatternᅟ .

dashPatternChanged(newDashPattern)
Parameters:

newDashPattern – .list of qreal

Notification signal of property dashPatternᅟ .

dataPointCoordinatesAt(x, y)
Parameters:
  • x – float

  • y – float

Return type:

QPointF

Returns x and y rendercoordinates converted into data point coordinates.

joinStyle()
Return type:

PenJoinStyle

See also

setJoinStyle()

Getter of property joinStyleᅟ .

joinStyleChanged(newJoinStyle)
Parameters:

newJoinStylePenJoinStyle

Notification signal of property joinStyleᅟ .

lineStyle()
Return type:

LineStyle

See also

setLineStyle()

Getter of property lineStyleᅟ .

lineStyleChanged(newLineStyle)
Parameters:

newLineStyleLineStyle

Notification signal of property lineStyleᅟ .

setCapStyle(newCapStyle)
Parameters:

newCapStylePenCapStyle

See also

capStyle()

Setter of property capStyleᅟ .

setDashOffset(newDashOffset)
Parameters:

newDashOffset – float

See also

dashOffset()

Setter of property dashOffsetᅟ .

setDashPattern(pattern)
Parameters:

pattern – .list of qreal

See also

dashPattern()

Setter of property dashPatternᅟ .

setJoinStyle(newJoinStyle)
Parameters:

newJoinStylePenJoinStyle

See also

joinStyle()

Setter of property joinStyleᅟ .

setLineStyle(newLineStyle)
Parameters:

newLineStyleLineStyle

See also

lineStyle()

Setter of property lineStyleᅟ .

setStrokeStyle(newStrokeStyle)
Parameters:

newStrokeStyleStrokeStyle

See also

strokeStyle()

Setter of property strokeStyleᅟ .

setWidth(newWidth)
Parameters:

newWidth – float

See also

width()

Setter of property widthᅟ .

strokeStyle()
Return type:

StrokeStyle

See also

setStrokeStyle()

Getter of property strokeStyleᅟ .

strokeStyleChanged(newStrokeStyle)
Parameters:

newStrokeStyleStrokeStyle

Notification signal of property strokeStyleᅟ .

width()
Return type:

float

See also

setWidth()

Getter of property widthᅟ .

widthChanged()

Notification signal of property widthᅟ .