16#ifndef QGSANNOTATIONITEMGUIREGISTRY_H
17#define QGSANNOTATIONITEMGUIREGISTRY_H
58 , mName( visibleName )
67 QString
type()
const {
return mType; }
77 QString
groupId()
const {
return mGroupId; }
87 virtual QIcon creationIcon()
const;
133 Qgis::AnnotationItemGuiFlags mFlags;
167 , mIcon( creationIcon )
168 , mWidgetFunc( pfWidget )
169 , mCreateFunc( pfCreateFunc )
170 , mCreateMapToolFunc( pfCreateMapToolFunc )
221 QIcon creationIcon()
const override;
324 int metadataIdForItemType(
const QString &type )
const;
399 QList<int> itemMetadataIds()
const;
404 void addDefaultItems();
419 QMap<int, QgsAnnotationItemAbstractGuiMetadata *> mMetadata;
421 QMap<QString, QgsAnnotationItemGuiGroup> mItemGroups;
The Qgis class provides global constants for use throughout the application.
QFlags< AnnotationItemGuiFlag > AnnotationItemGuiFlags
Annotation item GUI flags.
Stores GUI metadata about a group of annotation item classes.
QgsAnnotationItemGuiGroup(const QString &id=QString(), const QString &name=QString(), const QIcon &icon=QIcon())
Constructor for QgsAnnotationItemGuiGroup.
QString name
Translated group name.
QString id
Unique (untranslated) group ID string.
QIcon icon
Icon for group.
Registry of available annotation item GUI behavior.
QgsAnnotationItemGuiRegistry(const QgsAnnotationItemGuiRegistry &rh)=delete
void typeAdded(int metadataId)
Emitted whenever a new item type is added to the registry, with the specified metadataId.
QgsAnnotationItemGuiRegistry & operator=(const QgsAnnotationItemGuiRegistry &rh)=delete
Abstract base class for annotation items which are drawn with QgsAnnotationLayers.
Represents a map layer containing a set of georeferenced annotations, e.g.
Map canvas is a class for displaying all GIS data types on a canvas.
std::function< QgsCreateAnnotationItemMapToolInterface *(QgsMapCanvas *, QgsAdvancedDigitizingDockWidget *)> QgsCreateAnnotationItemMapToolFunc
Create annotation map tool creation function.
std::function< void(QgsAnnotationItem *, QgsAnnotationLayer *layer)> QgsAnnotationItemAddedToLayerFunc
Annotation item added to layer callback.
std::function< QgsAnnotationItemBaseWidget *(QgsAnnotationItem *)> QgsAnnotationItemWidgetFunc
Annotation item configuration widget creation function.
std::function< QgsAnnotationItem *()> QgsAnnotationItemCreateFunc
Annotation item creation function.