QGIS API Documentation  3.16.0-Hannover (43b64b13f3)
Public Member Functions | List of all members
QgsAnnotationItemAbstractMetadata Class Referenceabstract

Stores metadata about one annotation item class. More...

#include <qgsannotationitemregistry.h>

Inheritance diagram for QgsAnnotationItemAbstractMetadata:
Inheritance graph
[legend]

Public Member Functions

 QgsAnnotationItemAbstractMetadata (const QString &type, const QString &visibleName, const QString &visiblePluralName=QString())
 Constructor for QgsAnnotationItemAbstractMetadata with the specified class type and visibleName. More...
 
virtual ~QgsAnnotationItemAbstractMetadata ()=default
 
virtual QgsAnnotationItemcreateItem ()=0
 Creates a new, default, annotation item of this class. More...
 
QString type () const
 Returns the unique item type string for the annotation item class. More...
 
QString visibleName () const
 Returns a translated, user visible name for the annotation item class. More...
 
QString visiblePluralName () const
 Returns a translated, user visible name for plurals of the annotation item class (e.g. More...
 

Detailed Description

Stores metadata about one annotation item class.

A companion class, QgsAnnotationItemAbstractGuiMetadata, handles the GUI behavior of QgsAnnotationItems.

Note
In C++ you can use QgsAnnotationItemMetadata convenience class.
Since
QGIS 3.16

Definition at line 41 of file qgsannotationitemregistry.h.

Constructor & Destructor Documentation

◆ QgsAnnotationItemAbstractMetadata()

QgsAnnotationItemAbstractMetadata::QgsAnnotationItemAbstractMetadata ( const QString &  type,
const QString &  visibleName,
const QString &  visiblePluralName = QString() 
)
inline

Constructor for QgsAnnotationItemAbstractMetadata with the specified class type and visibleName.

The optional visiblePluralName argument can be used to specify a plural variant of the item type.

Definition at line 51 of file qgsannotationitemregistry.h.

◆ ~QgsAnnotationItemAbstractMetadata()

virtual QgsAnnotationItemAbstractMetadata::~QgsAnnotationItemAbstractMetadata ( )
virtualdefault

Member Function Documentation

◆ createItem()

virtual QgsAnnotationItem* QgsAnnotationItemAbstractMetadata::createItem ( )
pure virtual

Creates a new, default, annotation item of this class.

Implemented in QgsAnnotationItemMetadata.

◆ type()

QString QgsAnnotationItemAbstractMetadata::type ( ) const
inline

Returns the unique item type string for the annotation item class.

Definition at line 62 of file qgsannotationitemregistry.h.

◆ visibleName()

QString QgsAnnotationItemAbstractMetadata::visibleName ( ) const
inline

Returns a translated, user visible name for the annotation item class.

See also
visiblePluralName()

Definition at line 68 of file qgsannotationitemregistry.h.

◆ visiblePluralName()

QString QgsAnnotationItemAbstractMetadata::visiblePluralName ( ) const
inline

Returns a translated, user visible name for plurals of the annotation item class (e.g.

"Labels" for a "Label" item).

Definition at line 73 of file qgsannotationitemregistry.h.


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