Factory class for creating custom map layer property pages.
More...
#include <qgsmaplayerconfigwidgetfactory.h>
Factory class for creating custom map layer property pages.
Definition at line 33 of file qgsmaplayerconfigwidgetfactory.h.
◆ ParentPage
Available parent pages, for factories which create a widget which is a sub-component of a standard page.
- Since
- QGIS 3.20
Enumerator |
---|
NoParent | Factory creates pages itself, not sub-components.
|
Temporal | Factory creates sub-components of the temporal properties page (only supported for raster layer temporal properties)
|
Definition at line 43 of file qgsmaplayerconfigwidgetfactory.h.
◆ QgsMapLayerConfigWidgetFactory() [1/2]
QgsMapLayerConfigWidgetFactory::QgsMapLayerConfigWidgetFactory |
( |
| ) |
|
|
default |
◆ QgsMapLayerConfigWidgetFactory() [2/2]
QgsMapLayerConfigWidgetFactory::QgsMapLayerConfigWidgetFactory |
( |
const QString & |
title, |
|
|
const QIcon & |
icon |
|
) |
| |
◆ ~QgsMapLayerConfigWidgetFactory()
virtual QgsMapLayerConfigWidgetFactory::~QgsMapLayerConfigWidgetFactory |
( |
| ) |
|
|
virtualdefault |
◆ createWidget()
Factory function to create the widget on demand as needed by the dock.
- Parameters
-
layer | The active layer in the dock. |
canvas | The map canvas. |
dockWidget | true of the widget will be shown a dock style widget. |
parent | The parent of the widget. |
- Returns
- A new QgsMapStylePanel which is shown in the map style dock.
- Note
- This function is called each time the panel is selected. Keep it light for better UX.
◆ icon()
virtual QIcon QgsMapLayerConfigWidgetFactory::icon |
( |
| ) |
const |
|
inlinevirtual |
◆ layerPropertiesPagePositionHint()
QString QgsMapLayerConfigWidgetFactory::layerPropertiesPagePositionHint |
( |
| ) |
const |
|
virtual |
Returns a tab name hinting at where this page should be inserted into the layer properties tab list.
If the returned string is non-empty, the config widget page will be inserted before the existing page with matching object name.
The default implementation returns an empty string, which causes the widget to be placed at the end of the dialog page list.
- Since
- QGIS 3.14
Definition at line 24 of file qgsmaplayerconfigwidgetfactory.cpp.
◆ parentPage()
◆ setIcon()
void QgsMapLayerConfigWidgetFactory::setIcon |
( |
const QIcon & |
icon | ) |
|
|
inline |
◆ setSupportLayerPropertiesDialog()
void QgsMapLayerConfigWidgetFactory::setSupportLayerPropertiesDialog |
( |
bool |
supports | ) |
|
|
inline |
◆ setSupportsStyleDock()
void QgsMapLayerConfigWidgetFactory::setSupportsStyleDock |
( |
bool |
supports | ) |
|
|
inline |
◆ setTitle()
void QgsMapLayerConfigWidgetFactory::setTitle |
( |
const QString & |
title | ) |
|
|
inline |
Set the title for the interface.
- Note
- Not all users may show this as a label e.g style dock uses this as a tooltip.
- Parameters
-
Definition at line 81 of file qgsmaplayerconfigwidgetfactory.h.
◆ supportLayerPropertiesDialog()
virtual bool QgsMapLayerConfigWidgetFactory::supportLayerPropertiesDialog |
( |
| ) |
const |
|
inlinevirtual |
Flag if widget is supported for use in layer properties dialog.
The default implementation returns false
.
- Returns
true
if supported
Definition at line 101 of file qgsmaplayerconfigwidgetfactory.h.
◆ supportsLayer()
bool QgsMapLayerConfigWidgetFactory::supportsLayer |
( |
QgsMapLayer * |
layer | ) |
const |
|
virtual |
◆ supportsLayerTreeGroup()
bool QgsMapLayerConfigWidgetFactory::supportsLayerTreeGroup |
( |
QgsLayerTreeGroup * |
group | ) |
const |
|
virtual |
Check if a layer tree group is supported for this widget.
- Returns
true
if the group is supported for this widget
- Since
- QGIS 3.24
Definition at line 35 of file qgsmaplayerconfigwidgetfactory.cpp.
◆ supportsStyleDock()
virtual bool QgsMapLayerConfigWidgetFactory::supportsStyleDock |
( |
| ) |
const |
|
inlinevirtual |
Flag if widget is supported for use in style dock.
The default implementation returns false
.
- Returns
true
if supported
Definition at line 88 of file qgsmaplayerconfigwidgetfactory.h.
◆ title()
virtual QString QgsMapLayerConfigWidgetFactory::title |
( |
| ) |
const |
|
inlinevirtual |
The documentation for this class was generated from the following files: