QGIS API Documentation 3.41.0-Master (cea29feecf2)
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 <QDialog>
21#include "qgis_sip.h"
22
23#include "qgssymbol.h"
25#include "ui_qgsextentbufferdialogbase.h"
26#include "qgis_gui.h"
27
28class QgsVectorLayer;
29
37class GUI_EXPORT QgsExtentBufferWidget : public QgsPanelWidget, public QgsExpressionContextGenerator, private Ui::QgsExtentBufferDialogBase
38{
39 Q_OBJECT
40 public:
44 QgsExtentBufferWidget( QgsSymbol *symbol, QgsVectorLayer *layer, QWidget *parent SIP_TRANSFERTHIS = nullptr );
45
51 double extentBuffer() const;
52
58 QgsProperty dataDefinedProperty() const;
59
65 void setContext( const QgsSymbolWidgetContext &context );
66
71 QgsSymbolWidgetContext context() const;
72
77 Qgis::RenderUnit sizeUnit() const;
78
79 private:
80 QgsSymbol *mSymbol = nullptr;
81 QgsVectorLayer *mLayer = nullptr;
83
85
91 void registerDataDefinedButton( QgsPropertyOverrideButton *button, QgsSymbol::Property key );
92};
93
100class GUI_EXPORT QgsExtentBufferDialog : public QDialog
101{
102 Q_OBJECT
103 public:
105 QgsExtentBufferDialog( QgsSymbol *symbol, QgsVectorLayer *layer, QWidget *parent SIP_TRANSFERTHIS = nullptr );
106
110 double extentBuffer() const;
111
115 Qgis::RenderUnit sizeUnit() const;
116
124 QgsProperty dataDefinedProperty() const;
125
133 QgsExtentBufferWidget *widget() const;
134
139 void setContext( const QgsSymbolWidgetContext &context );
140
141 private:
142 QgsExtentBufferWidget *mWidget;
143
144 private slots:
145
146 void showHelp();
147};
148
149#endif // QGSEXTENTBUFFERDIALOG_H
RenderUnit
Rendering size units.
Definition qgis.h:4892
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...
A dialog which allows the user to modify the extent buffer of a symbol.
A widget which allows the user to modify the rendering order of extent buffers.
Base class for any widget that can be shown as a 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 data sets.
#define SIP_TRANSFERTHIS
Definition qgis_sip.h:53