QGIS API Documentation 3.99.0-Master (2fe06baccd8)
Loading...
Searching...
No Matches
qgsextentbufferdialog.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsextentbufferdialog.h
3 ---------------------
4 begin : December 2024
5 copyright : (C) 2024 by Juho Ervasti
6 email : juho dot ervasti at gispo dot fi
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 QGSEXTENTBUFFERDIALOG_H
16#define QGSEXTENTBUFFERDIALOG_H
17
18#define SIP_NO_FILE
19
20#include "ui_qgsextentbufferdialogbase.h"
21
22#include "qgis_gui.h"
23#include "qgis_sip.h"
24#include "qgssymbol.h"
26
27#include <QDialog>
28
29class QgsVectorLayer;
30
38class GUI_EXPORT QgsExtentBufferWidget : public QgsPanelWidget, public QgsExpressionContextGenerator, private Ui::QgsExtentBufferDialogBase
39{
40 Q_OBJECT
41 public:
45 QgsExtentBufferWidget( QgsSymbol *symbol, QgsVectorLayer *layer, QWidget *parent SIP_TRANSFERTHIS = nullptr );
46
52 double extentBuffer() const;
53
60
67
73
79
80 private:
81 QgsSymbol *mSymbol = nullptr;
82 QgsVectorLayer *mLayer = nullptr;
84
86
92 void registerDataDefinedButton( QgsPropertyOverrideButton *button, QgsSymbol::Property key );
93};
94
101class GUI_EXPORT QgsExtentBufferDialog : public QDialog
102{
103 Q_OBJECT
104 public:
106 QgsExtentBufferDialog( QgsSymbol *symbol, QgsVectorLayer *layer, QWidget *parent SIP_TRANSFERTHIS = nullptr );
107
111 double extentBuffer() const;
112
117
126
135
140 void setContext( const QgsSymbolWidgetContext &context );
141
142 private:
143 QgsExtentBufferWidget *mWidget;
144
145 private slots:
146
147 void showHelp();
148};
149
150#endif // QGSEXTENTBUFFERDIALOG_H
RenderUnit
Rendering size units.
Definition qgis.h:5183
Abstract interface for generating an expression context.
virtual QgsExpressionContext createExpressionContext() const =0
This method needs to be reimplemented in all classes which implement this interface and return an exp...
Expression contexts are used to encapsulate the parameters around which a QgsExpression should be eva...
void setContext(const QgsSymbolWidgetContext &context)
Sets the context in which widget is shown, e.g., the associated map canvas and expression contexts.
QgsExtentBufferDialog(QgsSymbol *symbol, QgsVectorLayer *layer, QWidget *parent=nullptr)
Constructor for QgsExtentBufferDialog.
QgsProperty dataDefinedProperty() const
Returns the extent buffer value currently set in the widget.
QgsExtentBufferWidget * widget() const
Returns the data defined property currently set in the widget.
double extentBuffer() const
Returns the extent buffer value currently set in the widget.
Qgis::RenderUnit sizeUnit() const
Returns the extent buffer unit currently set in the widget.
A widget which allows the user to modify the rendering order of extent buffers.
void setContext(const QgsSymbolWidgetContext &context)
Sets the context in which widget is shown, e.g., the associated map canvas and expression contexts.
QgsSymbolWidgetContext context() const
Returns the context in which the widget is shown, e.g., the associated map canvas and expression cont...
double extentBuffer() const
Returns the extent buffer value currently set in the widget.
QgsProperty dataDefinedProperty() const
Returns the data defined property currently set in the widget.
QgsExtentBufferWidget(QgsSymbol *symbol, QgsVectorLayer *layer, QWidget *parent=nullptr)
Constructor for QgsExtentBufferWidget.
Qgis::RenderUnit sizeUnit() const
Returns the extent buffer unit currently set in the widget.
QgsPanelWidget(QWidget *parent=nullptr)
Base class for any widget that can be shown as an inline panel.
A button for controlling property overrides which may apply to a widget.
A store for object properties.
Contains settings which reflect the context in which a symbol (or renderer) widget is shown,...
Abstract base class for all rendered symbols.
Definition qgssymbol.h:231
Property
Data definable properties.
Definition qgssymbol.h:270
Represents a vector layer which manages a vector based dataset.
#define SIP_TRANSFERTHIS
Definition qgis_sip.h:53