QGIS API Documentation 3.30.0-'s-Hertogenbosch (f186b8efe0)
|
The QgsPointCloudAttributeComboBox is a combo box which displays the list of attributes of a given point cloud layer. More...
#include <qgspointcloudattributecombobox.h>
Public Slots | |
void | setAttribute (const QString &name) |
Sets the currently selected attribute by name. More... | |
void | setLayer (QgsMapLayer *layer) |
Sets the layer for which fields are listed in the combobox. More... | |
Signals | |
void | attributeChanged (const QString &name) |
Emitted when the currently selected attribute changes. More... | |
Public Member Functions | |
QgsPointCloudAttributeComboBox (QWidget *parent=nullptr) | |
QgsPointCloudAttributeComboBox creates a combo box to display the fields of a layer. More... | |
bool | allowEmptyAttributeName () const |
Returns true if the combo box allows the empty field ("not set") choice. More... | |
QgsPointCloudAttributeCollection | attributes () const |
Returns the attributes currently shown in the combobox. More... | |
QString | currentAttribute () const |
Returns the currently selected attribute. More... | |
QgsPointCloudAttributeProxyModel::Filters | filters () const |
Returns the current filters used for filtering available attributes. More... | |
QgsPointCloudLayer * | layer () const |
Returns the layer currently associated with the combobox. More... | |
void | setAllowEmptyAttributeName (bool allowEmpty) |
Sets whether an optional empty attribute ("not set") option is shown in the combo box. More... | |
void | setAttributes (const QgsPointCloudAttributeCollection &attributes) |
Manually sets the attributes to use for the combo box. More... | |
void | setFilters (QgsPointCloudAttributeProxyModel::Filters filters) |
Sets filters to allow filtering available attributes according to the attribute properties. More... | |
Properties | |
bool | allowEmptyAttributeName |
QgsPointCloudAttributeProxyModel::Filters | filters |
The QgsPointCloudAttributeComboBox is a combo box which displays the list of attributes of a given point cloud layer.
It might be combined with a QgsMapLayerComboBox to automatically update attributes according to a chosen layer.
Definition at line 35 of file qgspointcloudattributecombobox.h.
|
explicit |
QgsPointCloudAttributeComboBox creates a combo box to display the fields of a layer.
The layer can be either manually given or dynamically set by connecting the signal QgsMapLayerComboBox::layerChanged to the slot setLayer.
Definition at line 21 of file qgspointcloudattributecombobox.cpp.
bool QgsPointCloudAttributeComboBox::allowEmptyAttributeName | ( | ) | const |
Returns true
if the combo box allows the empty field ("not set") choice.
Definition at line 41 of file qgspointcloudattributecombobox.cpp.
|
signal |
Emitted when the currently selected attribute changes.
QgsPointCloudAttributeCollection QgsPointCloudAttributeComboBox::attributes | ( | ) | const |
Returns the attributes currently shown in the combobox.
This will either be attributes from the associated layer() or the attributes manually set by a call to setAttributes().
Definition at line 62 of file qgspointcloudattributecombobox.cpp.
QString QgsPointCloudAttributeComboBox::currentAttribute | ( | ) | const |
Returns the currently selected attribute.
Definition at line 92 of file qgspointcloudattributecombobox.cpp.
|
inline |
Returns the current filters used for filtering available attributes.
Definition at line 59 of file qgspointcloudattributecombobox.h.
QgsPointCloudLayer * QgsPointCloudAttributeComboBox::layer | ( | ) | const |
Returns the layer currently associated with the combobox.
Definition at line 52 of file qgspointcloudattributecombobox.cpp.
void QgsPointCloudAttributeComboBox::setAllowEmptyAttributeName | ( | bool | allowEmpty | ) |
Sets whether an optional empty attribute ("not set") option is shown in the combo box.
Definition at line 36 of file qgspointcloudattributecombobox.cpp.
|
slot |
Sets the currently selected attribute by name.
Definition at line 67 of file qgspointcloudattributecombobox.cpp.
void QgsPointCloudAttributeComboBox::setAttributes | ( | const QgsPointCloudAttributeCollection & | attributes | ) |
Manually sets the attributes to use for the combo box.
This method should only be used when the combo box ISN'T associated with a layer() and needs to show the fields from an arbitrary attribute collection instead. Calling setAttributes() will automatically clear any existing layer().
Definition at line 57 of file qgspointcloudattributecombobox.cpp.
void QgsPointCloudAttributeComboBox::setFilters | ( | QgsPointCloudAttributeProxyModel::Filters | filters | ) |
Sets filters to allow filtering available attributes according to the attribute properties.
Definition at line 31 of file qgspointcloudattributecombobox.cpp.
|
slot |
Sets the layer for which fields are listed in the combobox.
If no layer is set or a non-point cloud layer is set then the combobox will be empty.
Definition at line 46 of file qgspointcloudattributecombobox.cpp.
|
readwrite |
Definition at line 35 of file qgspointcloudattributecombobox.h.
|
readwrite |
Definition at line 35 of file qgspointcloudattributecombobox.h.