QGIS API Documentation 3.41.0-Master (af5edcb665c)
Loading...
Searching...
No Matches
qgsrasterlabelsettingswidget.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsrasterlabelsettingswidget.h
3 -------------------------
4 begin : December 2024
5 copyright : (C) 2024 by Nyall Dawson
6 email : nyall dot dawson at gmail dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15#ifndef QGSRASTERLABELSETTINGSWIDGET_H
16#define QGSRASTERLABELSETTINGSWIDGET_H
17
18#include "qgis_gui.h"
19#include "qgslabelinggui.h"
20
21class QgsRasterLayer;
25
26// We don't want to expose this in the public API
27#define SIP_NO_FILE
28
36class GUI_EXPORT QgsRasterLabelSettingsWidget : public QgsLabelingGui
37{
38 Q_OBJECT
39 public:
43 QgsRasterLabelSettingsWidget( QgsRasterLayer *layer, QgsMapCanvas *mapCanvas, QWidget *parent = nullptr );
45
49 void setLabeling( QgsAbstractRasterLayerLabeling *labeling );
50
54 void updateLabeling( QgsAbstractRasterLayerLabeling *labeling );
55
56 void setLayer( QgsMapLayer *layer ) final;
57
58 private slots:
59 void changeNumberFormat();
60
61 private:
62 QgsRasterBandComboBox *mBandCombo = nullptr;
63 std::unique_ptr<QgsNumericFormat> mNumberFormat;
64 int mBlockChangesSignal = 0;
65
66 QgsSpinBox *mResampleOverSpin = nullptr;
67 QComboBox *mResampleMethodComboBox = nullptr;
68};
69
70#endif // QGSRASTERLABELSETTINGSWIDGET_H
Abstract base class for labeling settings for raster layers.
Map canvas is a class for displaying all GIS data types on a canvas.
Base class for all map layer types.
Definition qgsmaplayer.h:76
A numeric formatter allows for formatting a numeric value for display, using a variety of different f...
A combobox widget which displays the bands present in a raster layer.
A widget for customizing settings for raster layer labeling.
~QgsRasterLabelSettingsWidget() override
Represents a raster layer.
The QgsSpinBox is a spin box with a clear button that will set the value to the defined clear value.
Definition qgsspinbox.h:43