QGIS API Documentation
3.36.0-Maidenhead (09951dc0acf)
Toggle main menu visibility
Main Page
Related Pages
Topics
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
w
z
Functions
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
w
z
Variables
Typedefs
Enumerations
Enumerator
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
2
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
2
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
c
e
f
g
h
i
k
l
m
o
p
r
s
t
u
v
w
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
y
z
Related Symbols
3
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
Files
File List
File Members
All
3
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
z
Variables
a
b
c
d
e
f
g
h
i
l
n
o
p
q
r
s
t
u
w
Typedefs
3
a
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
w
Enumerations
Enumerator
c
l
s
t
Macros
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
w
x
y
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
Loading...
Searching...
No Matches
src
core
annotations
qgsannotationmanager.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsannotationmanager.h
3
----------------------
4
Date : January 2017
5
Copyright : (C) 2017 Nyall Dawson
6
Email : nyall dot dawson at gmail dot com
7
***************************************************************************
8
* *
9
* This program is free software; you can redistribute it and/or modify *
10
* it under the terms of the GNU General Public License as published by *
11
* the Free Software Foundation; either version 2 of the License, or *
12
* (at your option) any later version. *
13
* *
14
***************************************************************************/
15
16
#ifndef QGSANNOTATIONMANAGER_H
17
#define QGSANNOTATIONMANAGER_H
18
19
#include "qgis_core.h"
20
#include "
qgis.h
"
21
#include <QObject>
22
#include <QDomElement>
23
24
class
QgsReadWriteContext
;
25
class
QgsProject
;
26
class
QgsAnnotation
;
27
class
QgsStyleEntityVisitorInterface
;
28
43
class
CORE_EXPORT
QgsAnnotationManager
:
public
QObject
44
{
45
Q_OBJECT
46
47
public
:
48
53
explicit
QgsAnnotationManager
(
QgsProject
*project
SIP_TRANSFERTHIS
=
nullptr
);
54
55
~QgsAnnotationManager
()
override
;
56
63
bool
addAnnotation(
QgsAnnotation
*annotation
SIP_TRANSFER
);
64
74
bool
removeAnnotation(
QgsAnnotation
*annotation );
75
80
void
clear();
81
86
QList< QgsAnnotation * > annotations()
const
;
87
94
QList< QgsAnnotation * > cloneAnnotations()
const
SIP_FACTORY
;
95
101
bool
readXml(
const
QDomElement &element,
const
QgsReadWriteContext
&context );
102
107
QDomElement writeXml( QDomDocument &doc,
const
QgsReadWriteContext
&context )
const
;
108
118
bool
accept(
QgsStyleEntityVisitorInterface
*visitor )
const
;
119
120
signals:
121
123
void
annotationAdded
(
QgsAnnotation
*annotation );
124
126
void
annotationRemoved
();
127
129
void
annotationAboutToBeRemoved
(
QgsAnnotation
*annotation );
130
131
private
:
132
133
QgsProject
*mProject =
nullptr
;
134
135
QList< QgsAnnotation * > mAnnotations;
136
137
void
createAnnotationFromXml(
const
QDomElement &element,
const
QgsReadWriteContext
&context );
138
139
};
43
class
CORE_EXPORT
QgsAnnotationManager
:
public
QObject {
…
};
140
141
#endif
// QGSANNOTATIONMANAGER_H
QgsAnnotationManager
Manages storage of a set of QgsAnnotation annotation objects.
Definition
qgsannotationmanager.h:44
QgsAnnotationManager::annotationRemoved
void annotationRemoved()
Emitted when an annotation was removed from the manager.
QgsAnnotationManager::annotationAboutToBeRemoved
void annotationAboutToBeRemoved(QgsAnnotation *annotation)
Emitted when an annotation is about to be removed from the manager.
QgsAnnotationManager::annotationAdded
void annotationAdded(QgsAnnotation *annotation)
Emitted when a annotation has been added to the manager.
QgsAnnotation
Abstract base class for annotation items which are drawn over a map.
Definition
qgsannotation.h:53
QgsProject
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...
Definition
qgsproject.h:107
QgsReadWriteContext
The class is used as a container of context for various read/write operations on other objects.
Definition
qgsreadwritecontext.h:34
QgsStyleEntityVisitorInterface
An interface for classes which can visit style entity (e.g.
Definition
qgsstyleentityvisitor.h:34
qgis.h
SIP_TRANSFERTHIS
#define SIP_TRANSFERTHIS
Definition
qgis_sip.h:53
SIP_TRANSFER
#define SIP_TRANSFER
Definition
qgis_sip.h:36
SIP_FACTORY
#define SIP_FACTORY
Definition
qgis_sip.h:76
Generated on Mon Feb 26 2024 10:02:44 for QGIS API Documentation by
1.9.8