Loading...
Searching...
No Matches
LineSymbolizerWidget.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/LineSymbolizerWidget.h
22
23 \brief A widget used to build a line symbolizer element.
24*/
25
26#ifndef __TERRALIB_QT_WIDGETS_SE_INTERNAL_LINESYMBOLIZERWIDGET_H
27#define __TERRALIB_QT_WIDGETS_SE_INTERNAL_LINESYMBOLIZERWIDGET_H
28
29// TerraLib
30#include "../Config.h"
31
32// Qt
33#include <QWidget>
34
35// STL
36#include <memory>
37
38// Forward declaraion
39namespace Ui { class LineSymbolizerWidgetForm; }
40
41namespace te
42{
43// Forward declarations
44 namespace se
45 {
46 class LineSymbolizer;
47 class Symbolizer;
48 }
49
50 namespace qt
51 {
52 namespace widgets
53 {
54// Forward declarations
55 class BasicStrokeWidget;
56
57 /*!
58 \class LineSymbolizerWidget
59
60 \brief A widget used to build a line symbolizer element.
61 */
63 {
64 Q_OBJECT
65
66 public:
67
68 /** @name Initializer Methods
69 * Methods related to instantiation and destruction.
70 */
71 //@{
72
73 /*! \brief Constructs a line symbolizer widget which is a child of parent, with widget flags set to f. */
74 LineSymbolizerWidget(QWidget* parent = 0, Qt::WindowFlags f = 0);
75
76 /*! \brief Destructor. */
78
79 //@}
80
81 public:
82
83 /*!
84 \brief Sets a line symbolizer element to this widget.
85
86 \param symb A valid line symbolizer element.
87
88 \note The widget will NOT take the ownership of the given symbolizer.
89 \note The widget form will be update based on given symbolizer parameters.
90 */
92
93 /*!
94 \brief Gets the configured line symbolizer element.
95
96 \return The configured line symbolizer element.
97
98 \note The caller will take the ownership of the returned symbolizer.
99 */
101
102 protected:
103
104 /*! \brief Updates the widget form based on internal line symbolizer element. */
105 void updateUi();
106
107 protected slots:
108
110
112
113 signals:
114
115 /*! This signal is emitted when the internal line symbolizer element is changed. */
117
118 private:
119
120 std::unique_ptr<Ui::LineSymbolizerWidgetForm> m_ui; //!< Widget form.
121 te::qt::widgets::BasicStrokeWidget* m_strokeWidget; //!< Basic Stroke Widget used to configure the line symbolizer stroke element.
122 te::se::LineSymbolizer* m_symb; //!< Line symbolizer element that will be configured by this widget.
123 };
124
125 } // end namespace widgets
126 } // end namespace qt
127} // end namespace te
128
129#endif // __TERRALIB_QT_WIDGETS_SE_INTERNAL_LINESYMBOLIZERWIDGET_H
A widget used to build a basic stroke element.
A widget used to build a line symbolizer element.
std::unique_ptr< Ui::LineSymbolizerWidgetForm > m_ui
Widget form.
te::se::Symbolizer * getSymbolizer() const
Gets the configured line symbolizer element.
void setSymbolizer(const te::se::LineSymbolizer *symb)
Sets a line symbolizer element to this widget.
te::qt::widgets::BasicStrokeWidget * m_strokeWidget
Basic Stroke Widget used to configure the line symbolizer stroke element.
LineSymbolizerWidget(QWidget *parent=0, Qt::WindowFlags f=0)
Constructs a line symbolizer widget which is a child of parent, with widget flags set to f.
te::se::LineSymbolizer * m_symb
Line symbolizer element that will be configured by this widget.
void updateUi()
Updates the widget form based on internal line symbolizer element.
A LineSymbolizer is used to style a stroke along a linear geometry type, such as a string of line seg...
A Symbolizer describes how a feature is to appear on a map.
Definition: Symbolizer.h:81
TerraLib.
#define slots
#define TEQTWIDGETSEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:63