TextPropertyItem.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/TextPropertyItem.h
22
23
\brief A widget used to define the text se object.
24
*/
25
26
#ifndef __TERRALIB_QT_WIDGETS_SE_INTERNAL_TEXTPROPERTYITEM_H
27
#define __TERRALIB_QT_WIDGETS_SE_INTERNAL_TEXTPROPERTYITEM_H
28
29
// TerraLib
30
#include "../Config.h"
31
#include "../propertybrowser/AbstractPropertyItem.h"
32
33
namespace
te
34
{
35
// Forward declarations
36
namespace
se
37
{
38
class
Font;
39
class
TextSymbolizer;
40
}
41
42
namespace
qt
43
{
44
namespace
widgets
45
{
46
class
BasicFillPropertyItem;
47
48
/*!
49
\class TextPropertyItem
50
51
\brief A widget used to define the text se object.
52
53
*/
54
55
class
TEQTWIDGETSEXPORT
TextPropertyItem
:
public
te::qt::widgets::AbstractPropertyItem
56
{
57
Q_OBJECT
58
59
public
:
60
/** @name Initializer Methods
61
* Methods related to instantiation and destruction.
62
*/
63
//@{
64
65
/*! \brief Constructor */
66
TextPropertyItem
(QtTreePropertyBrowser* pb, QColor c = QColor());
67
68
/*! \brief Destructor. */
69
~
TextPropertyItem
();
70
71
//@}
72
73
/** @name Re-implementation of Pure Virtual Method
74
* AbstractFillWidget methods.
75
*/
76
//@{
77
78
void
setTextSymbolizer(
const
te::se::TextSymbolizer
* ts);
79
80
void
setLabels(std::vector<std::string> labels);
81
82
te::se::TextSymbolizer
* getTextSymbolizer()
const
;
83
84
/*! \brief Updates the widget form based on internal fill element. */
85
void
updateUi();
86
87
public
slots
:
88
89
virtual
void
valueChanged(QtProperty* p,
int
value);
90
91
virtual
void
valueChanged(QtProperty* p,
const
QFont &value);
92
93
void
onFillChanged();
94
95
signals:
96
97
/*! This signal is emitted when the internal fill element is changed. */
98
void
textChanged();
99
100
protected
:
101
102
te::qt::widgets::BasicFillPropertyItem
*
m_bf
;
103
104
QtProperty*
m_labelProperty
;
105
QtProperty*
m_fontProperty
;
106
107
te::se::TextSymbolizer
*
m_textSymbolizer
;
//!< Fill element that will be configured by this widget.
108
109
std::vector<std::string>
m_labels
;
110
111
bool
m_update
;
112
};
113
}
114
}
115
}
116
117
#endif //__TERRALIB_QT_WIDGETS_SE_INTERNAL_TEXTPROPERTYITEM_H
te::se::TextSymbolizer
A TextSymbolizer is used to render text labels according to various graphical parameters.
Definition:
TextSymbolizer.h:62
te::qt::widgets::TextPropertyItem::m_labels
std::vector< std::string > m_labels
Definition:
TextPropertyItem.h:109
slots
#define slots
Definition:
VirtualMachine.h:48
te::qt::widgets::AbstractPropertyItem
A widget used to define the main property items that can be used to describe a se object...
Definition:
AbstractPropertyItem.h:54
te::qt::widgets::TextPropertyItem::m_bf
te::qt::widgets::BasicFillPropertyItem * m_bf
Definition:
TextPropertyItem.h:102
te::qt::widgets::TextPropertyItem::m_textSymbolizer
te::se::TextSymbolizer * m_textSymbolizer
Fill element that will be configured by this widget.
Definition:
TextPropertyItem.h:107
te::qt::widgets::TextPropertyItem::m_update
bool m_update
Definition:
TextPropertyItem.h:111
te
URI C++ Library.
Definition:
AddressGeocodingOp.h:51
te::qt::widgets::TextPropertyItem::m_fontProperty
QtProperty * m_fontProperty
Definition:
TextPropertyItem.h:105
te::qt::widgets::TextPropertyItem::m_labelProperty
QtProperty * m_labelProperty
Definition:
TextPropertyItem.h:104
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::BasicFillPropertyItem
A widget used to define the basic fill se object.
Definition:
BasicFillPropertyItem.h:52
te::qt::widgets::TextPropertyItem
A widget used to define the text se object.
Definition:
TextPropertyItem.h:55
git_master
src
terralib
qt
widgets
se
TextPropertyItem.h
Generated on Tue Jul 17 2018 14:31:06 for TerraLib by
1.8.14