2017-05-09 10:03:47 +10:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/gui/raster/qgsrasterbandcombobox.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class QgsRasterBandComboBox : QComboBox
|
|
|
|
{
|
|
|
|
%Docstring
|
|
|
|
A combobox widget which displays the bands present in a raster layer.
|
|
|
|
.. versionadded:: 3.0
|
|
|
|
%End
|
|
|
|
|
|
|
|
%TypeHeaderCode
|
|
|
|
#include "qgsrasterbandcombobox.h"
|
|
|
|
%End
|
|
|
|
public:
|
|
|
|
|
|
|
|
QgsRasterBandComboBox( QWidget *parent /TransferThis/ = 0 );
|
|
|
|
%Docstring
|
|
|
|
Constructor for QgsRasterBandComboBox.
|
|
|
|
%End
|
|
|
|
|
|
|
|
QgsRasterLayer *layer() const;
|
|
|
|
%Docstring
|
|
|
|
Returns the layer currently associated with the combobox.
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setLayer()`
|
2017-05-09 10:03:47 +10:00
|
|
|
:rtype: QgsRasterLayer
|
|
|
|
%End
|
|
|
|
|
|
|
|
int currentBand() const;
|
|
|
|
%Docstring
|
|
|
|
Returns the current band number selected in the combobox, or -1
|
|
|
|
if no band is selected.
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setBand()`
|
2017-05-09 10:03:47 +10:00
|
|
|
:rtype: int
|
|
|
|
%End
|
|
|
|
|
2017-05-09 10:48:08 +10:00
|
|
|
bool isShowingNotSetOption() const;
|
|
|
|
%Docstring
|
|
|
|
Returns true if the combo box is showing the "not set" option.
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setShowNotSetOption()`
|
2017-05-09 10:48:08 +10:00
|
|
|
:rtype: bool
|
|
|
|
%End
|
|
|
|
|
|
|
|
void setShowNotSetOption( bool show, const QString &string = QString() );
|
|
|
|
%Docstring
|
|
|
|
Sets whether the combo box should show the "not set" option.
|
|
|
|
Optionally the built in "not set" text can be overridden by specifying
|
|
|
|
a ``string``.
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setShowNotSetOption()`
|
2017-05-09 10:48:08 +10:00
|
|
|
%End
|
|
|
|
|
2017-05-09 10:03:47 +10:00
|
|
|
public slots:
|
|
|
|
|
|
|
|
void setLayer( QgsMapLayer *layer );
|
|
|
|
%Docstring
|
|
|
|
Sets the raster ``layer`` for which the bands are listed in the combobox. If no layer is set
|
|
|
|
or a non-raster layer is set then the combobox will be empty.
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`layer()`
|
2017-05-09 10:03:47 +10:00
|
|
|
%End
|
|
|
|
|
|
|
|
void setBand( int band );
|
|
|
|
%Docstring
|
|
|
|
Sets the current ``band`` number selected in the combobox.
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`band()`
|
2017-05-09 10:03:47 +10:00
|
|
|
%End
|
|
|
|
|
|
|
|
signals:
|
|
|
|
|
|
|
|
void bandChanged( int band );
|
|
|
|
%Docstring
|
|
|
|
This signal is emitted when the currently selected band changes.
|
|
|
|
%End
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/gui/raster/qgsrasterbandcombobox.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|