QGIS API Documentation
4.3.0-Master (16eddb2670e)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
gui
raster
qgsrasterlabelingwidget.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsrasterlabelingwidget.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 QGSRASTERLABELINGWIDGET_H
16
#define QGSRASTERLABELINGWIDGET_H
17
18
// We don't want to expose this in the public API
19
20
#include "ui_qgsrasterlabelingwidgetbase.h"
21
22
#include "qgis_gui.h"
23
#include "
qgsmaplayerconfigwidget.h
"
24
#include "
qgsrasterlabeling.h
"
25
26
#include <QWidget>
27
28
#define SIP_NO_FILE
29
30
class
QgsLabelingGui;
31
class
QgsMapCanvas
;
32
class
QgsRasterLayer
;
33
class
QgsMapLayer
;
34
class
QgsMessageBar
;
35
42
class
GUI_EXPORT
QgsRasterLabelingWidget
:
public
QgsMapLayerConfigWidget
,
private
Ui::QgsRasterLabelingWidgetBase
43
{
44
Q_OBJECT
45
public
:
47
QgsRasterLabelingWidget
(
QgsRasterLayer
*
layer
,
QgsMapCanvas
*canvas, QWidget *parent =
nullptr
,
QgsMessageBar
*messageBar =
nullptr
);
48
49
void
setDockMode
(
bool
dockMode
)
override
;
50
51
public
slots:
53
void
setLayer
(
QgsMapLayer
*
layer
);
54
58
void
writeSettingsToLayer
();
59
61
void
apply
()
override
;
62
64
void
adaptToLayer
();
65
66
signals:
68
void
auxiliaryFieldCreated
();
69
70
private
slots:
71
void
labelModeChanged(
int
index );
72
void
showLabelingEngineRulesPrivate();
73
void
showEngineConfigDialogPrivate();
74
75
private
:
76
QgsRasterLayer
*mLayer =
nullptr
;
77
QgsMapCanvas
*mCanvas =
nullptr
;
78
QgsMessageBar
*mMessageBar =
nullptr
;
79
80
QWidget *mWidget =
nullptr
;
81
};
82
83
#endif
// QGSRASTERLABELINGWIDGET_H
QgsMapCanvas
Map canvas is a class for displaying all GIS data types on a canvas.
Definition
qgsmapcanvas.h:96
QgsMapLayerConfigWidget::QgsMapLayerConfigWidget
QgsMapLayerConfigWidget(QgsMapLayer *layer, QgsMapCanvas *canvas, QWidget *parent=nullptr)
A panel widget that can be shown in the map style dock.
Definition
qgsmaplayerconfigwidget.cpp:40
QgsMapLayerConfigWidget::apply
virtual void apply()=0
Called when changes to the layer need to be made.
QgsMapLayerConfigWidget::layer
QgsMapLayer * layer()
Returns the layer the widget is associated with.
Definition
qgsmaplayerconfigwidget.cpp:46
QgsMapLayer
Base class for all map layer types.
Definition
qgsmaplayer.h:83
QgsMessageBar
A bar for displaying non-blocking messages to the user.
Definition
qgsmessagebar.h:61
QgsPanelWidget::dockMode
bool dockMode() const
Returns the dock mode state.
Definition
qgspanelwidget.h:94
QgsPanelWidget::setDockMode
virtual void setDockMode(bool dockMode)
Set the widget in dock mode which tells the widget to emit panel widgets and not open dialogs.
Definition
qgspanelwidget.cpp:74
QgsRasterLabelingWidget::QgsRasterLabelingWidget
QgsRasterLabelingWidget(QgsRasterLayer *layer, QgsMapCanvas *canvas, QWidget *parent=nullptr, QgsMessageBar *messageBar=nullptr)
constructor
Definition
qgsrasterlabelingwidget.cpp:30
QgsRasterLabelingWidget::auxiliaryFieldCreated
void auxiliaryFieldCreated()
Emitted when an auxiliary field is created.
QgsRasterLabelingWidget::setLayer
void setLayer(QgsMapLayer *layer)
Sets the layer to configure.
Definition
qgsrasterlabelingwidget.cpp:62
QgsRasterLabelingWidget::writeSettingsToLayer
void writeSettingsToLayer()
Saves the labeling configuration to the destination layer.
Definition
qgsrasterlabelingwidget.cpp:107
QgsRasterLabelingWidget::adaptToLayer
void adaptToLayer()
Reload the settings shown in the dialog from the current layer.
Definition
qgsrasterlabelingwidget.cpp:80
QgsRasterLayer
Represents a raster layer.
Definition
qgsrasterlayer.h:82
qgsmaplayerconfigwidget.h
qgsrasterlabeling.h
Generated on
for QGIS API Documentation by
1.17.0