16#ifndef QGSANNOTATIONITEMGUIREGISTRY_H
17#define QGSANNOTATIONITEMGUIREGISTRY_H
59 , mName( visibleName )
68 QString
type()
const {
return mType; }
78 QString
groupId()
const {
return mGroupId; }
88 virtual QIcon creationIcon()
const;
135 Qgis::AnnotationItemGuiFlags mFlags;
171 const QString &groupId = QString(),
176 , mIcon( creationIcon )
177 , mWidgetFunc( pfWidget )
178 , mCreateFunc( pfCreateFunc )
179 , mCreateMapToolFunc( pfCreateMapToolFunc )
230 QIcon creationIcon()
const override;
337 int metadataIdForItemType(
const QString &type )
const;
412 QList< int > itemMetadataIds()
const;
417 void addDefaultItems();
432 QMap< int, QgsAnnotationItemAbstractGuiMetadata *> mMetadata;
434 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.