QGIS API Documentation
4.3.0-Master (16eddb2670e)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
core
labeling
qgslabelsearchtree.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgslabelsearchtree.h
3
Node for raster calculator tree
4
--------------------
5
begin : 2010-11-02
6
copyright : (C) 2010 by Marco Hugentobler
7
email : marco dot hugentobler at sourcepole dot ch
8
***************************************************************************/
9
10
/***************************************************************************
11
* *
12
* This program is free software; you can redistribute it and/or modify *
13
* it under the terms of the GNU General Public License as published by *
14
* the Free Software Foundation; either version 2 of the License, or *
15
* (at your option) any later version. *
16
* *
17
***************************************************************************/
18
19
#ifndef QGSLABELSEARCHTREE_H
20
#define QGSLABELSEARCHTREE_H
21
22
#include "qgis_core.h"
23
#include "
qgis_sip.h
"
24
#include "
qgscalloutposition.h
"
25
#include "
qgsgenericspatialindex.h
"
26
#include "
qgslabelposition.h
"
27
#include "
qgsmapsettings.h
"
28
29
#include <QList>
30
#include <QVector>
31
32
class
QgsPointXY
;
33
34
#ifndef SIP_RUN
35
namespace
pal
36
{
37
class
LabelPosition
;
38
}
39
#endif
40
41
// TODO QGIS 5.0 - this should be private, not exposed to SIP
42
49
class
CORE_EXPORT
QgsLabelSearchTree
50
{
51
public
:
52
QgsLabelSearchTree
();
53
~QgsLabelSearchTree
();
54
55
QgsLabelSearchTree
(
const
QgsLabelSearchTree
&rh ) =
delete
;
56
QgsLabelSearchTree
&
operator=
(
const
QgsLabelSearchTree
&rh ) =
delete
;
57
62
Q_DECL_DEPRECATED
void
clear
()
SIP_DEPRECATED
;
63
68
void
label
( const
QgsPointXY
&p, QList<
QgsLabelPosition
*> &posList ) const
SIP_SKIP
;
69
75
Q_DECL_DEPRECATED QList<
QgsLabelPosition
>
allLabels
() const
SIP_DEPRECATED
;
76
81
void
labelsInRect
( const
QgsRectangle
&r, QList<
QgsLabelPosition
*> &posList ) const
SIP_SKIP
;
82
92
QList<const
QgsCalloutPosition
*>
calloutsInRectangle
( const
QgsRectangle
&rectangle ) const;
93
98
Q_DECL_DEPRECATED
void
setMapSettings
( const
QgsMapSettings
&settings )
SIP_DEPRECATED
;
99
100
private:
101
QgsGenericSpatialIndex
<
QgsLabelPosition
> mSpatialIndex;
102
QgsGenericSpatialIndex
<
QgsCalloutPosition
> mCalloutIndex;
103
104
#ifdef SIP_RUN
105
QgsLabelSearchTree
(
const
QgsLabelSearchTree
&rh );
106
QgsLabelSearchTree
&
operator=
(
const
QgsLabelSearchTree
& );
107
#endif
108
109
friend
class
QgsLabelingResults
;
110
};
111
112
#endif
// QGSLABELTREE_H
QgsCalloutPosition
Represents the calculated placement of a map label callout line.
Definition
qgscalloutposition.h:32
QgsGenericSpatialIndex
A generic rtree spatial index based on a libspatialindex backend.
Definition
qgsgenericspatialindex.h:48
QgsLabelPosition
Represents the calculated placement of a map label.
Definition
qgslabelposition.h:36
QgsLabelSearchTree::operator=
QgsLabelSearchTree & operator=(const QgsLabelSearchTree &rh)=delete
QgsLabelSearchTree::clear
Q_DECL_DEPRECATED void clear()
Removes and deletes all the entries.
Definition
qgslabelsearchtree.cpp:84
QgsLabelSearchTree::QgsLabelSearchTree
QgsLabelSearchTree()
QgsLabelSearchTree::label
void label(const QgsPointXY &p, QList< QgsLabelPosition * > &posList) const
Returns label position(s) at a given point.
Definition
qgslabelsearchtree.cpp:21
QgsLabelSearchTree::QgsLabelSearchTree
QgsLabelSearchTree(const QgsLabelSearchTree &rh)=delete
QgsLabelSearchTree::labelsInRect
void labelsInRect(const QgsRectangle &r, QList< QgsLabelPosition * > &posList) const
Returns label position(s) in given rectangle.
Definition
qgslabelsearchtree.cpp:48
QgsLabelSearchTree::calloutsInRectangle
QList< const QgsCalloutPosition * > calloutsInRectangle(const QgsRectangle &rectangle) const
Returns the list of callouts with origins or destinations inside the given rectangle.
Definition
qgslabelsearchtree.cpp:67
QgsLabelSearchTree::QgsLabelingResults
friend class QgsLabelingResults
Definition
qgslabelsearchtree.h:109
QgsLabelSearchTree::~QgsLabelSearchTree
~QgsLabelSearchTree()
QgsLabelSearchTree::setMapSettings
Q_DECL_DEPRECATED void setMapSettings(const QgsMapSettings &settings)
Sets the map settings associated with the labeling run.
Definition
qgslabelsearchtree.cpp:81
QgsLabelSearchTree::allLabels
Q_DECL_DEPRECATED QList< QgsLabelPosition > allLabels() const
Returns a list of all labels generated by the labeling run.
Definition
qgslabelsearchtree.cpp:43
QgsMapSettings
Contains configuration for rendering maps.
Definition
qgsmapsettings.h:91
QgsPointXY
Represents a 2D point.
Definition
qgspointxy.h:62
QgsRectangle
A rectangle specified with double values.
Definition
qgsrectangle.h:47
pal::LabelPosition
LabelPosition is a candidate feature label position.
Definition
labelposition.h:57
pal
Definition
qgsdiagramrenderer.h:51
qgis_sip.h
SIP_DEPRECATED
#define SIP_DEPRECATED
Definition
qgis_sip.h:113
SIP_SKIP
#define SIP_SKIP
Definition
qgis_sip.h:138
qgscalloutposition.h
qgsgenericspatialindex.h
qgslabelposition.h
qgsmapsettings.h
Generated on
for QGIS API Documentation by
1.17.0