LineSymbolizerProperty.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/LineSymbolizerProperty.h
22 
23  \brief A widget used to define the line symbolizer
24  properties, such as:
25  - basic stroke
26 */
27 
28 #ifndef __TERRALIB_QT_WIDGETS_SE_INTERNAL_LINESYMBOLIZERPROPERTY_H
29 #define __TERRALIB_QT_WIDGETS_SE_INTERNAL_LINESYMBOLIZERPROPERTY_H
30 
31 // TerraLib
34 #include "../Config.h"
35 
36 // Qt
37 class QWidget;
38 class QtProperty;
39 
40 namespace te
41 {
42 // Forward declarations
43  namespace se
44  {
45  class Symbolizer;
46  }
47 
48  namespace qt
49  {
50  namespace widgets
51  {
52  class StrokePropertyItem;
53  class LinePerpendicularOffsetPropertyItem;
54 
55  /*!
56  \class LineSymbolizerProperty
57 
58  \brief A widget used to define the polygon symbolizer
59  properties, such as:
60  - basic stroke
61 
62  */
63 
65  {
66  Q_OBJECT
67 
68  public:
69  /** @name Initializer Methods
70  * Methods related to instantiation and destruction.
71  */
72  //@{
73 
74  /*! \brief Constructor */
75  LineSymbolizerProperty(QWidget* parent);
76 
77  /*! \brief Destructor. */
79 
80  //@}
81 
82  public:
83 
84  /*!
85  \brief Sets a line symbolizer element to this widget.
86 
87  \param symb A valid line symbolizer element.
88 
89  \note The widget will NOT take the ownership of the given symbolizer.
90  \note The widget form will be update based on given symbolizer parameters.
91  */
92  virtual void setSymbolizer(const te::se::Symbolizer* symb) override;
93 
94  /*!
95  \brief Gets the configured line symbolizer element.
96 
97  \return The configured line symbolizer element.
98 
99  \note The caller will take the ownership of the returned symbolizer.
100  */
101  virtual te::se::Symbolizer* getSymbolizer() const override;
102 
103  virtual void handleValueChanged(QtProperty* qProperty, const QVariant& qVariant) override;
104 
105  protected:
106 
107  StrokePropertyItem* m_strokePropItem; //!< A widget used to define the Stroke Property.
108  LinePerpendicularOffsetPropertyItem* m_perpendicularOffset; //!< A widget used to define the Perpendicular Offset between a line and marks.
109  };
110  }
111  }
112 }
113 
114 #endif //__TERRALIB_QT_WIDGETS_SE_INTERNAL_LINESYMBOLIZERPROPERTY_H
A parent widget used to define the symbolizer properties.
A bse item to represent the style items in property listener.
A parent widget used to define the symbolizer properties.
A widget used to define the Perpendicular Offset between a line and marks.
A widget used to define the polygon symbolizer properties, such as:
LineSymbolizerProperty(QWidget *parent)
Constructor.
virtual void handleValueChanged(QtProperty *qProperty, const QVariant &qVariant) override
< This function will be called every time a value has changed
virtual te::se::Symbolizer * getSymbolizer() const override
Gets the configured line symbolizer element.
LinePerpendicularOffsetPropertyItem * m_perpendicularOffset
A widget used to define the Perpendicular Offset between a line and marks.
virtual void setSymbolizer(const te::se::Symbolizer *symb) override
Sets a line symbolizer element to this widget.
StrokePropertyItem * m_strokePropItem
A widget used to define the Stroke Property.
A widget used to define the stroke se object.
A widget used to define the main property items listener.
A Symbolizer describes how a feature is to appear on a map.
Definition: Symbolizer.h:81
TerraLib.
#define TEQTWIDGETSEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:63