Class: QgsCurveEditorWidget

A widget for manipulating QgsCurveTransform curves.

Class Hierarchy

Inheritance diagram of qgis.gui.QgsCurveEditorWidget

Base classes

QWidget

QObject

QPaintDevice

class qgis.gui.QgsCurveEditorWidget[source]

Bases: QWidget

__init__(parent: QWidget | None = None, curve: QgsCurveTransform = QgsCurveTransform())

Constructor for QgsCurveEditorWidget.

Parameters:
signal changed[source]

pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL

types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.

curve(self) QgsCurveTransform[source]

Returns a curve representing the current curve from the widget.

See also

setCurve()

Return type:

QgsCurveTransform

maxHistogramValueRange(self) float[source]

Returns the maximum expected value for the range of values shown in the histogram.

Return type:

float

minHistogramValueRange(self) float[source]

Returns the minimum expected value for the range of values shown in the histogram.

Return type:

float

setCurve(self, curve: QgsCurveTransform)[source]

Sets the curve to show in the widget.

See also

curve()

Parameters:

curve (QgsCurveTransform)

setHistogramSource(self, layer: QgsVectorLayer | None, expression: str | None)[source]

Sets a layer and expression source for values to show in a histogram behind the curve. The histogram is generated in a background thread to keep the widget responsive.

Parameters:
setMaxHistogramValueRange(self, maxValueRange: float)[source]

Sets the maximum expected value for the range of values shown in the histogram.

Parameters:

maxValueRange (float)

setMinHistogramValueRange(self, minValueRange: float)[source]

Sets the minimum expected value for the range of values shown in the histogram.

Parameters:

minValueRange (float)