QGIS API Documentation 3.41.0-Master (3c143d501a8)
Loading...
Searching...
No Matches
Public Slots | Signals | Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
QgsRendererPropertiesDialog Class Reference

#include <qgsrendererpropertiesdialog.h>

Inheritance diagram for QgsRendererPropertiesDialog:
Inheritance graph
[legend]

Public Slots

void apply ()
 Apply the changes from the dialog to the layer.
 
void onOK ()
 Apply and accept the changes for the dialog.
 
void openPanel (QgsPanelWidget *panel)
 Open a panel or dialog depending on dock mode setting If dock mode is true this method will emit the showPanel signal for connected slots to handle the open event.
 
void rendererChanged ()
 called when user changes renderer type
 

Signals

void layerVariablesChanged ()
 Emitted when expression context variables on the associated vector layers have been changed.
 
void showPanel (QgsPanelWidget *panel)
 Emit when you require a panel to be show in the interface.
 
void widgetChanged ()
 Emitted when something on the widget has changed.
 

Public Member Functions

 QgsRendererPropertiesDialog (QgsVectorLayer *layer, QgsStyle *style, bool embedded=false, QWidget *parent=nullptr)
 Constructor for QgsRendererPropertiesDialog.
 
 ~QgsRendererPropertiesDialog () override
 
void setContext (const QgsSymbolWidgetContext &context)
 Sets the context in which the dialog is shown, e.g., the associated map canvas and expression contexts.
 
void setDockMode (bool dockMode)
 Set the widget in dock mode which tells the widget to emit panel widgets and not open dialogs.
 
void setMapCanvas (QgsMapCanvas *canvas)
 Sets the map canvas associated with the dialog.
 

Protected Member Functions

void connectValueChanged (const QList< QWidget * > &widgets)
 Connect the value changed event for the set of widgets to widgetChanged signal.
 
void keyPressEvent (QKeyEvent *event) override
 

Protected Attributes

QgsRendererWidgetmActiveWidget = nullptr
 
QgsVectorLayermLayer = nullptr
 
QgsMapCanvasmMapCanvas = nullptr
 
QgsMessageBarmMessageBar = nullptr
 
QgsFeatureRequest::OrderBy mOrderBy
 
QgsPaintEffectmPaintEffect = nullptr
 
QgsStylemStyle = nullptr
 

Friends

class QgsAppScreenShots
 

Detailed Description

Definition at line 43 of file qgsrendererpropertiesdialog.h.

Constructor & Destructor Documentation

◆ QgsRendererPropertiesDialog()

QgsRendererPropertiesDialog::QgsRendererPropertiesDialog ( QgsVectorLayer layer,
QgsStyle style,
bool  embedded = false,
QWidget *  parent = nullptr 
)

Constructor for QgsRendererPropertiesDialog.

Parameters
layerassociated layer
stylestyle collection
embeddedset to true to indicate that the dialog will be embedded in another widget, rather than shown as a dialog by itself
parentparent widget

Definition at line 89 of file qgsrendererpropertiesdialog.cpp.

◆ ~QgsRendererPropertiesDialog()

QgsRendererPropertiesDialog::~QgsRendererPropertiesDialog ( )
override

Definition at line 189 of file qgsrendererpropertiesdialog.cpp.

Member Function Documentation

◆ apply

void QgsRendererPropertiesDialog::apply ( )
slot

Apply the changes from the dialog to the layer.

Definition at line 289 of file qgsrendererpropertiesdialog.cpp.

◆ connectValueChanged()

void QgsRendererPropertiesDialog::connectValueChanged ( const QList< QWidget * > &  widgets)
protected

Connect the value changed event for the set of widgets to widgetChanged signal.

Each widget is checked for type and the common type of signal is connected to widgetChanged.

Parameters
widgetsThe list of widgets to check.

Definition at line 141 of file qgsrendererpropertiesdialog.cpp.

◆ keyPressEvent()

void QgsRendererPropertiesDialog::keyPressEvent ( QKeyEvent *  event)
overrideprotected

Definition at line 426 of file qgsrendererpropertiesdialog.cpp.

◆ layerVariablesChanged

void QgsRendererPropertiesDialog::layerVariablesChanged ( )
signal

Emitted when expression context variables on the associated vector layers have been changed.

Will request the parent dialog to re-synchronize with the variables.

◆ onOK

void QgsRendererPropertiesDialog::onOK ( )
slot

Apply and accept the changes for the dialog.

Definition at line 317 of file qgsrendererpropertiesdialog.cpp.

◆ openPanel

void QgsRendererPropertiesDialog::openPanel ( QgsPanelWidget panel)
slot

Open a panel or dialog depending on dock mode setting If dock mode is true this method will emit the showPanel signal for connected slots to handle the open event.

If dock mode is false this method will open a dialog and block the user.

Parameters
panelThe panel widget to open.

Definition at line 323 of file qgsrendererpropertiesdialog.cpp.

◆ rendererChanged

void QgsRendererPropertiesDialog::rendererChanged ( )
slot

called when user changes renderer type

Definition at line 224 of file qgsrendererpropertiesdialog.cpp.

◆ setContext()

void QgsRendererPropertiesDialog::setContext ( const QgsSymbolWidgetContext context)

Sets the context in which the dialog is shown, e.g., the associated map canvas and expression contexts.

Since
QGIS 3.6

Definition at line 205 of file qgsrendererpropertiesdialog.cpp.

◆ setDockMode()

void QgsRendererPropertiesDialog::setDockMode ( bool  dockMode)

Set the widget in dock mode which tells the widget to emit panel widgets and not open dialogs.

Parameters
dockModetrue to enable dock mode.

Definition at line 215 of file qgsrendererpropertiesdialog.cpp.

◆ setMapCanvas()

void QgsRendererPropertiesDialog::setMapCanvas ( QgsMapCanvas canvas)

Sets the map canvas associated with the dialog.

This allows the widget to retrieve the current map scale and other properties from the canvas.

Parameters
canvasmap canvas

Definition at line 194 of file qgsrendererpropertiesdialog.cpp.

◆ showPanel

void QgsRendererPropertiesDialog::showPanel ( QgsPanelWidget panel)
signal

Emit when you require a panel to be show in the interface.

Parameters
panelThe panel widget to show.
Note
If you are connected to this signal you should also connect given panels showPanel signal as they can be nested.

◆ widgetChanged

void QgsRendererPropertiesDialog::widgetChanged ( )
signal

Emitted when something on the widget has changed.

All widgets will fire this event to notify of an internal change.

Friends And Related Symbol Documentation

◆ QgsAppScreenShots

friend class QgsAppScreenShots
friend

Definition at line 167 of file qgsrendererpropertiesdialog.h.

Member Data Documentation

◆ mActiveWidget

QgsRendererWidget* QgsRendererPropertiesDialog::mActiveWidget = nullptr
protected

Definition at line 152 of file qgsrendererpropertiesdialog.h.

◆ mLayer

QgsVectorLayer* QgsRendererPropertiesDialog::mLayer = nullptr
protected

Definition at line 149 of file qgsrendererpropertiesdialog.h.

◆ mMapCanvas

QgsMapCanvas* QgsRendererPropertiesDialog::mMapCanvas = nullptr
protected

Definition at line 156 of file qgsrendererpropertiesdialog.h.

◆ mMessageBar

QgsMessageBar* QgsRendererPropertiesDialog::mMessageBar = nullptr
protected

Definition at line 157 of file qgsrendererpropertiesdialog.h.

◆ mOrderBy

QgsFeatureRequest::OrderBy QgsRendererPropertiesDialog::mOrderBy
protected

Definition at line 159 of file qgsrendererpropertiesdialog.h.

◆ mPaintEffect

QgsPaintEffect* QgsRendererPropertiesDialog::mPaintEffect = nullptr
protected

Definition at line 154 of file qgsrendererpropertiesdialog.h.

◆ mStyle

QgsStyle* QgsRendererPropertiesDialog::mStyle = nullptr
protected

Definition at line 150 of file qgsrendererpropertiesdialog.h.


The documentation for this class was generated from the following files: