QGIS API Documentation  3.10.0-A Coruña (6c816b4204)
Public Slots | Signals | Public Member Functions | Protected Member Functions | List of all members
QgsCurveEditorWidget Class Reference

A widget for manipulating QgsCurveTransform curves. More...

#include <qgscurveeditorwidget.h>

Inheritance diagram for QgsCurveEditorWidget:
Inheritance graph
[legend]

Public Slots

void setMaxHistogramValueRange (double maxValueRange)
 Sets the maximum expected value for the range of values shown in the histogram. More...
 
void setMinHistogramValueRange (double minValueRange)
 Sets the minimum expected value for the range of values shown in the histogram. More...
 

Signals

void changed ()
 Emitted when the widget curve changes. More...
 

Public Member Functions

 QgsCurveEditorWidget (QWidget *parent=nullptr, const QgsCurveTransform &curve=QgsCurveTransform())
 Constructor for QgsCurveEditorWidget. More...
 
 ~QgsCurveEditorWidget () override
 
QgsCurveTransform curve () const
 Returns a curve representing the current curve from the widget. More...
 
double maxHistogramValueRange () const
 Returns the maximum expected value for the range of values shown in the histogram. More...
 
double minHistogramValueRange () const
 Returns the minimum expected value for the range of values shown in the histogram. More...
 
void setCurve (const QgsCurveTransform &curve)
 Sets the curve to show in the widget. More...
 
void setHistogramSource (const QgsVectorLayer *layer, const QString &expression)
 Sets a layer and expression source for values to show in a histogram behind the curve. More...
 

Protected Member Functions

void keyPressEvent (QKeyEvent *event) override
 

Detailed Description

A widget for manipulating QgsCurveTransform curves.

Since
QGIS 3.0

Definition at line 143 of file qgscurveeditorwidget.h.

Constructor & Destructor Documentation

◆ QgsCurveEditorWidget()

QgsCurveEditorWidget::QgsCurveEditorWidget ( QWidget *  parent = nullptr,
const QgsCurveTransform curve = QgsCurveTransform() 
)

Constructor for QgsCurveEditorWidget.

Definition at line 41 of file qgscurveeditorwidget.cpp.

◆ ~QgsCurveEditorWidget()

QgsCurveEditorWidget::~QgsCurveEditorWidget ( )
override

Definition at line 88 of file qgscurveeditorwidget.cpp.

Member Function Documentation

◆ changed

void QgsCurveEditorWidget::changed ( )
signal

Emitted when the widget curve changes.

◆ curve()

QgsCurveTransform QgsCurveEditorWidget::curve ( ) const
inline

Returns a curve representing the current curve from the widget.

See also
setCurve()

Definition at line 160 of file qgscurveeditorwidget.h.

◆ keyPressEvent()

void QgsCurveEditorWidget::keyPressEvent ( QKeyEvent *  event)
overrideprotected

Definition at line 152 of file qgscurveeditorwidget.cpp.

◆ maxHistogramValueRange()

double QgsCurveEditorWidget::maxHistogramValueRange ( ) const
inline

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

See also
minHistogramValueRange()
setMaxHistogramValueRange()

Definition at line 189 of file qgscurveeditorwidget.h.

◆ minHistogramValueRange()

double QgsCurveEditorWidget::minHistogramValueRange ( ) const
inline

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

See also
maxHistogramValueRange()
setMinHistogramValueRange()

Definition at line 182 of file qgscurveeditorwidget.h.

◆ setCurve()

void QgsCurveEditorWidget::setCurve ( const QgsCurveTransform curve)

Sets the curve to show in the widget.

See also
curve()

Definition at line 98 of file qgscurveeditorwidget.cpp.

◆ setHistogramSource()

void QgsCurveEditorWidget::setHistogramSource ( const QgsVectorLayer layer,
const QString &  expression 
)

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.

See also
minHistogramValueRange()
maxHistogramValueRange()

Definition at line 105 of file qgscurveeditorwidget.cpp.

◆ setMaxHistogramValueRange

void QgsCurveEditorWidget::setMaxHistogramValueRange ( double  maxValueRange)
slot

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

See also
setMinHistogramValueRange()
maxHistogramValueRange()

Definition at line 146 of file qgscurveeditorwidget.cpp.

◆ setMinHistogramValueRange

void QgsCurveEditorWidget::setMinHistogramValueRange ( double  minValueRange)
slot

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

See also
setMaxHistogramValueRange()
minHistogramValueRange()

Definition at line 140 of file qgscurveeditorwidget.cpp.


The documentation for this class was generated from the following files: