TextSymbolizerProperty.h
Go to the documentation of this file.
1
/* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2
3
This file is part of the TerraLib - a Framework for building GIS enabled applications.
4
5
TerraLib is free software: you can redistribute it and/or modify
6
it under the terms of the GNU Lesser General Public License as published by
7
the Free Software Foundation, either version 3 of the License,
8
or (at your option) any later version.
9
10
TerraLib is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY; without even the implied warranty of
12
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
GNU Lesser General Public License for more details.
14
15
You should have received a copy of the GNU Lesser General Public License
16
along with TerraLib. See COPYING. If not, write to
17
TerraLib Team at <terralib-team@terralib.org>.
18
*/
19
20
/*!
21
\file terralib/qt/widgets/se/TextSymbolizerProperty.h
22
23
\brief A widget used to define the text symbolizer
24
properties, such as:
25
- basic fill
26
- font
27
- halo
28
*/
29
30
#ifndef __TERRALIB_QT_WIDGETS_SE_INTERNAL_TEXTSYMBOLIZERPROPERTY_H
31
#define __TERRALIB_QT_WIDGETS_SE_INTERNAL_TEXTSYMBOLIZERPROPERTY_H
32
33
// TerraLib
34
#include "../Config.h"
35
36
// Qt
37
#include <QWidget>
38
39
40
namespace
te
41
{
42
// Forward declarations
43
namespace
se
44
{
45
class
TextSymbolizer;
46
class
Symbolizer;
47
}
48
49
namespace
qt
50
{
51
namespace
widgets
52
{
53
class
HaloPropertyItem;
54
class
LinePlacementPropertyItem;
55
class
PointPlacementPropertyItem;
56
class
TextPropertyItem;
57
58
/*!
59
\class TextSymbolizerProperty
60
61
\brief A widget used to define the text symbolizer
62
properties, such as:
63
- basic fill
64
- font
65
- halo
66
67
*/
68
69
class
TEQTWIDGETSEXPORT
TextSymbolizerProperty
:
public
QWidget
70
{
71
Q_OBJECT
72
73
public
:
74
/** @name Initializer Methods
75
* Methods related to instantiation and destruction.
76
*/
77
//@{
78
79
/*! \brief Constructor */
80
TextSymbolizerProperty
(QWidget* parent);
81
82
/*! \brief Destructor. */
83
~
TextSymbolizerProperty
();
84
85
//@}
86
87
public
:
88
89
/*!
90
\brief Sets a text symbolizer element to this widget.
91
92
\param symb A valid text symbolizer element.
93
94
\note The widget will NOT take the ownership of the given symbolizer.
95
\note The widget form will be update based on given symbolizer parameters.
96
*/
97
void
setSymbolizer(
te::se::TextSymbolizer
* symb);
98
99
/*!
100
\brief Gets the configured polygon symbolizer element.
101
102
\return The configured polygon symbolizer element.
103
104
\note The caller will take the ownership of the returned symbolizer.
105
*/
106
te::se::Symbolizer
* getSymbolizer()
const
;
107
108
109
/*!
110
\brief Used to set all properties names to use as label
111
*/
112
void
setLabels(std::vector<std::string> names);
113
114
protected
slots
:
115
116
void
onTextChanged();
117
118
void
onLinePlacementChanged();
119
120
void
onPointPlacementChanged();
121
122
void
onHaloChanged();
123
124
signals:
125
126
/*! This signal is emitted when the internal polygon symbolizer element is changed. */
127
void
symbolizerChanged();
128
129
protected
:
130
te::qt::widgets::TextPropertyItem
*
m_text
;
131
te::qt::widgets::LinePlacementPropertyItem
*
m_lp
;
132
te::qt::widgets::PointPlacementPropertyItem
*
m_pp
;
133
te::qt::widgets::HaloPropertyItem
*
m_halo
;
134
135
bool
m_setLocalSymbol
;
136
137
te::se::TextSymbolizer
*
m_symb
;
//!< Text symbolizer element that will be configured by this widget.
138
};
139
}
140
}
141
}
142
143
#endif //__TERRALIB_QT_WIDGETS_SE_INTERNAL_TEXTSYMBOLIZERPROPERTY_H
te::se::TextSymbolizer
A TextSymbolizer is used to render text labels according to various graphical parameters.
Definition:
TextSymbolizer.h:62
slots
#define slots
Definition:
VirtualMachine.h:48
te::qt::widgets::TextSymbolizerProperty
A widget used to define the text symbolizer properties, such as:
Definition:
TextSymbolizerProperty.h:69
te::se::Symbolizer
A Symbolizer describes how a feature is to appear on a map.
Definition:
Symbolizer.h:80
te::qt::widgets::PointPlacementPropertyItem
A widget used to define the PointPlacement se object.
Definition:
PointPlacementPropertyItem.h:52
te::qt::widgets::TextSymbolizerProperty::m_halo
te::qt::widgets::HaloPropertyItem * m_halo
Definition:
TextSymbolizerProperty.h:133
te::qt::widgets::HaloPropertyItem
A widget used to define the halo se object.
Definition:
HaloPropertyItem.h:55
te::qt::widgets::TextSymbolizerProperty::m_setLocalSymbol
bool m_setLocalSymbol
Definition:
TextSymbolizerProperty.h:135
te::qt::widgets::TextSymbolizerProperty::m_text
te::qt::widgets::TextPropertyItem * m_text
Definition:
TextSymbolizerProperty.h:130
te
URI C++ Library.
Definition:
AddressGeocodingOp.h:51
te::qt::widgets::LinePlacementPropertyItem
A widget used to define the LinePlacement se object.
Definition:
LinePlacementPropertyItem.h:52
te::qt::widgets::TextSymbolizerProperty::m_pp
te::qt::widgets::PointPlacementPropertyItem * m_pp
Definition:
TextSymbolizerProperty.h:132
te::qt::widgets::TextSymbolizerProperty::m_lp
te::qt::widgets::LinePlacementPropertyItem * m_lp
Definition:
TextSymbolizerProperty.h:131
TEQTWIDGETSEXPORT
#define TEQTWIDGETSEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition:
Config.h:63
te::qt::widgets::TextSymbolizerProperty::m_symb
te::se::TextSymbolizer * m_symb
Text symbolizer element that will be configured by this widget.
Definition:
TextSymbolizerProperty.h:137
te::qt::widgets::TextPropertyItem
A widget used to define the text se object.
Definition:
TextPropertyItem.h:55
git_master
src
terralib
qt
widgets
se
TextSymbolizerProperty.h
Generated on Tue Jul 17 2018 14:31:06 for TerraLib by
1.8.14