|
QGIS API Documentation
2.8.2-Wien
|
A button for defining data source field mappings or expressions. More...
#include <qgsdatadefinedbutton.h>
Public Types | |
| enum | DataType { String = 1, Int = 2, Double = 4, AnyType = String | Int | Double } |
Public Slots | |
| void | checkCheckedWidgets (bool check) |
| Set siblings' checked property when data definition or expression is active. | |
| void | disableEnabledWidgets (bool disable) |
| Set siblings' enabled property when data definition or expression is set/unset. | |
| void | setActive (bool active) |
| Set whether the current data definition or expression is to be used. | |
Signals | |
| void | dataDefinedActivated (bool active) |
| Emitted when active state changed. | |
| void | dataDefinedChanged (const QString &definition) |
| Emitted when data definition or expression is changed. | |
Public Member Functions | |
| QgsDataDefinedButton (QWidget *parent=0, const QgsVectorLayer *vl=0, const QgsDataDefined *datadefined=0, DataTypes datatypes=AnyType, QString description="") | |
| Construct a new data defined button. | |
| ~QgsDataDefinedButton () | |
| void | clearCheckedWidgets () |
| Clears list of checkable sibling widgets. | |
| void | clearEnabledWidgets () |
| Clears list of sibling widgets. | |
| QString | currentDefinition () const |
| The current definition. | |
| QMap< QString, QString > | definedProperty () const |
| QString | fullDescription () const |
| The full definition description and current definition (internally generated on a contextual basis) | |
| QString | getExpression () const |
| The current defined expression. | |
| QString | getField () const |
| The current defined field. | |
| void | init (const QgsVectorLayer *vl, const QgsDataDefined *datadefined=0, DataTypes datatypes=AnyType, QString description=QString("")) |
| Initialize a newly constructed data defined button (useful if button already included from form layout) | |
| bool | isActive () |
| Whether the current data definition or expression is to be used. | |
| void | registerCheckedWidget (QWidget *wdgt) |
| Register a sibling widget that get checked when data definition or expression is active. | |
| void | registerCheckedWidgets (QList< QWidget * > wdgts) |
| Register list of sibling widgets that get checked when data definition or expression is active. | |
| QList< QWidget * > | registeredCheckedWidgets () |
| Return widget siblings that get checked when data definition or expression is active. | |
| QList< QWidget * > | registeredEnabledWidgets () |
| Return widget siblings that get disabled/enabled when data definition or expression is set/unset. | |
| void | registerEnabledWidget (QWidget *wdgt) |
| Register a sibling widget that gets disabled/enabled when data definition or expression is set/unset. | |
| void | registerEnabledWidgets (QList< QWidget * > wdgts) |
| Register list of sibling widgets that get disabled/enabled when data definition or expression is set/unset. | |
| void | setUsageInfo (const QString &info) |
| Set the usage information about this data definition. | |
| QString | usageInfo () const |
| The usage information about this data definition. | |
| bool | useExpression () |
| Whether the current expression is to be used instead of field mapping. | |
| const DataTypes & | validDataTypes () const |
| The valid data types that will work for the definition (QVariant-coercible to expected type) Compared against the variant type of the QgsField from data source and expression result. | |
Static Public Member Functions | |
| static QString | anyStringDesc () |
| static QString | blendModesDesc () |
| static QString | boolDesc () |
| static QString | capStyleDesc () |
| static QString | colorAlphaDesc () |
| static QString | colorNoAlphaDesc () |
| static QString | customDashDesc () |
| static QString | double0to1Desc () |
| static QString | double180RotDesc () |
| static QString | doubleDesc () |
| static QString | doublePosDesc () |
| static QString | doubleXYDesc () |
| static QString | filePathDesc () |
| static QString | fillStyleDesc () |
| static QString | gradientCoordModeDesc () |
| static QString | gradientSpreadDesc () |
| static QString | gradientTypeDesc () |
| static QString | horizontalAnchorDesc () |
| static QString | intDesc () |
| static QString | intPosDesc () |
| static QString | intPosOneDesc () |
| static QString | intTranspDesc () |
| static QString | lineStyleDesc () |
| static QString | markerStyleDesc () |
| static QString | paperOrientationDesc () |
| static QString | paperSizeDesc () |
| static QString | penJoinStyleDesc () |
| static QString | svgPathDesc () |
| static QString | textHorzAlignDesc () |
| static QString | textVertAlignDesc () |
| static QString | trString () |
| Common descriptions for expected input values. | |
| static QString | unitsMmMuDesc () |
| static QString | unitsMmMuPercentDesc () |
| static QString | verticalAnchorDesc () |
Protected Member Functions | |
| void | mouseReleaseEvent (QMouseEvent *event) override |
| void | setExpression (QString exp) |
| Set the current defined expression. | |
| void | setField (QString field) |
| Set the current defined field. | |
| void | setUseExpression (bool use) |
| Set whether the current expression is to be used instead of field mapping. | |
Properties | |
| QString | usageInfo |
A button for defining data source field mappings or expressions.
Definition at line 33 of file qgsdatadefinedbutton.h.
Definition at line 39 of file qgsdatadefinedbutton.h.
| QgsDataDefinedButton::QgsDataDefinedButton | ( | QWidget * | parent = 0, |
| const QgsVectorLayer * | vl = 0, |
||
| const QgsDataDefined * | datadefined = 0, |
||
| DataTypes | datatypes = AnyType, |
||
| QString | description = "" |
||
| ) |
Construct a new data defined button.
| parent | The parent QWidget |
| vl | Pointer to the associated vector layer |
| datadefined | Data defined property |
| datatypes | The expected data types to be compared against the variant type of the QgsField from data source and expression result |
| description | The description of expected input data |
Definition at line 38 of file qgsdatadefinedbutton.cpp.
| QgsDataDefinedButton::~QgsDataDefinedButton | ( | ) |
Definition at line 95 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 613 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 698 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 608 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 761 of file qgsdatadefinedbutton.cpp.
|
slot |
Set siblings' checked property when data definition or expression is active.
Definition at line 579 of file qgsdatadefinedbutton.cpp.
|
inline |
Clears list of checkable sibling widgets.
Definition at line 168 of file qgsdatadefinedbutton.h.
|
inline |
Clears list of sibling widgets.
Definition at line 146 of file qgsdatadefinedbutton.h.
|
static |
Definition at line 678 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 673 of file qgsdatadefinedbutton.cpp.
|
inline |
The current definition.
Definition at line 103 of file qgsdatadefinedbutton.h.
|
static |
Definition at line 778 of file qgsdatadefinedbutton.cpp.
|
signal |
Emitted when active state changed.
| active | Whether the definition is active |
|
signal |
Emitted when data definition or expression is changed.
| definition | The current definition or expression (empty string if inactive) |
|
inline |
Definition at line 77 of file qgsdatadefinedbutton.h.
|
slot |
Set siblings' enabled property when data definition or expression is set/unset.
Definition at line 544 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 643 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 653 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 633 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 638 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 648 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 712 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 766 of file qgsdatadefinedbutton.cpp.
|
inline |
The full definition description and current definition (internally generated on a contextual basis)
Definition at line 114 of file qgsdatadefinedbutton.h.
|
inline |
The current defined expression.
Definition at line 92 of file qgsdatadefinedbutton.h.
|
inline |
The current defined field.
Definition at line 97 of file qgsdatadefinedbutton.h.
|
static |
Definition at line 746 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 751 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 741 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 731 of file qgsdatadefinedbutton.cpp.
| void QgsDataDefinedButton::init | ( | const QgsVectorLayer * | vl, |
| const QgsDataDefined * | datadefined = 0, |
||
| DataTypes | datatypes = AnyType, |
||
| QString | description = QString( "" ) |
||
| ) |
Initialize a newly constructed data defined button (useful if button already included from form layout)
| vl | Pointer to the associated vector layer |
| datadefined | Data defined property |
| datatypes | The expected data types to be compared against the variant type of the QgsField from data source and expression result |
| description | The description of expected input data |
Definition at line 101 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 618 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 623 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 628 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 658 of file qgsdatadefinedbutton.cpp.
|
inline |
Whether the current data definition or expression is to be used.
Definition at line 82 of file qgsdatadefinedbutton.h.
|
static |
Definition at line 756 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 773 of file qgsdatadefinedbutton.cpp.
|
overrideprotected |
Definition at line 195 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 726 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 717 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 693 of file qgsdatadefinedbutton.cpp.
| void QgsDataDefinedButton::registerCheckedWidget | ( | QWidget * | wdgt | ) |
Register a sibling widget that get checked when data definition or expression is active.
Definition at line 560 of file qgsdatadefinedbutton.cpp.
| void QgsDataDefinedButton::registerCheckedWidgets | ( | QList< QWidget * > | wdgts | ) |
Register list of sibling widgets that get checked when data definition or expression is active.
Definition at line 552 of file qgsdatadefinedbutton.cpp.
| QList< QWidget * > QgsDataDefinedButton::registeredCheckedWidgets | ( | ) |
Return widget siblings that get checked when data definition or expression is active.
Definition at line 569 of file qgsdatadefinedbutton.cpp.
| QList< QWidget * > QgsDataDefinedButton::registeredEnabledWidgets | ( | ) |
Return widget siblings that get disabled/enabled when data definition or expression is set/unset.
Definition at line 534 of file qgsdatadefinedbutton.cpp.
| void QgsDataDefinedButton::registerEnabledWidget | ( | QWidget * | wdgt | ) |
Register a sibling widget that gets disabled/enabled when data definition or expression is set/unset.
Definition at line 525 of file qgsdatadefinedbutton.cpp.
| void QgsDataDefinedButton::registerEnabledWidgets | ( | QList< QWidget * > | wdgts | ) |
Register list of sibling widgets that get disabled/enabled when data definition or expression is set/unset.
Definition at line 517 of file qgsdatadefinedbutton.cpp.
|
slot |
Set whether the current data definition or expression is to be used.
Definition at line 508 of file qgsdatadefinedbutton.cpp.
|
inlineprotected |
Set the current defined expression.
Definition at line 248 of file qgsdatadefinedbutton.h.
|
inlineprotected |
Set the current defined field.
Definition at line 253 of file qgsdatadefinedbutton.h.
|
inline |
Set the usage information about this data definition.
Definition at line 124 of file qgsdatadefinedbutton.h.
|
inlineprotected |
Set whether the current expression is to be used instead of field mapping.
Definition at line 243 of file qgsdatadefinedbutton.h.
|
static |
Definition at line 705 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 683 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 688 of file qgsdatadefinedbutton.cpp.
|
static |
Common descriptions for expected input values.
Definition at line 602 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 663 of file qgsdatadefinedbutton.cpp.
|
static |
Definition at line 668 of file qgsdatadefinedbutton.cpp.
|
inline |
The usage information about this data definition.
Definition at line 119 of file qgsdatadefinedbutton.h.
|
inline |
Whether the current expression is to be used instead of field mapping.
Definition at line 87 of file qgsdatadefinedbutton.h.
|
inline |
The valid data types that will work for the definition (QVariant-coercible to expected type) Compared against the variant type of the QgsField from data source and expression result.
Definition at line 109 of file qgsdatadefinedbutton.h.
|
static |
Definition at line 736 of file qgsdatadefinedbutton.cpp.
|
readwrite |
Definition at line 36 of file qgsdatadefinedbutton.h.
1.8.1.2