Loading...
Searching...
No Matches
MapDisplay.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/maptools/MapDisplay.h
22
23 \brief The map display controls how a set of layers are displayed.
24*/
25
26#ifndef __TERRALIB_MAPTOOLS_INTERNAL_MAPDISPLAY_H
27#define __TERRALIB_MAPTOOLS_INTERNAL_MAPDISPLAY_H
28
29// TerraLib
30#include "AbstractMapDisplay.h"
31
32namespace te
33{
34 namespace map
35 {
36 /*!
37 \class MapDisplay
38
39 \brief This class controls how a set of layers are displayed.
40
41 \ingroup map
42
43 \sa AbstractMapDisplay, AbstractLayer
44 */
46 {
47 public:
48
49 /*! \brief It initializes a new MapDisplay. */
51
52 /*! \brief Virtual destructor. */
53 virtual ~MapDisplay();
54
55 virtual std::list<AbstractLayerPtr> getLayerList() const;
56
57 virtual void setLayerList(const std::list<te::map::AbstractLayerPtr>& layers);
58
60
62
64
65 virtual const te::gm::Envelope& getExtent() const;
66
67 virtual void setExtent(te::gm::Envelope& e, bool doRefresh = true);
68
69 virtual int getSRID() const;
70
71 virtual void setSRID(const int& srid, bool doRefresh = true);
72
73 protected:
74
75 te::gm::Envelope m_extent; //!< The display extent.
76 std::list<te::map::AbstractLayerPtr> m_layerList; //!< The layer list to be displayed.
77 int m_srid; //!< The display SRS.
78 te::map::AlignType m_hAlign; //!< The display horizontal align.
79 te::map::AlignType m_vAlign; //!< The display vertical align.
80 };
81
82 } // end namespace map
83} // end namespace te
84
85#endif // __TERRALIB_MAPTOOLS_INTERNAL_MAPDISPLAY_H
It defines the concept of a map display responsible for controlling how a set of layers are displayed...
An Envelope defines a 2D rectangular region.
Definition Envelope.h:52
AbstractMapDisplay()
It initializes a new MapDisplay.
te::map::AlignType m_vAlign
The display vertical align.
Definition MapDisplay.h:79
virtual std::list< AbstractLayerPtr > getLayerList() const
virtual void setLayerList(const std::list< te::map::AbstractLayerPtr > &layers)
It sets the layer list to be showed in the Map Display.
virtual int getSRID() const
It return the Spatial Reference System used by the Map Display.
int m_srid
The display SRS.
Definition MapDisplay.h:77
te::map::AlignType m_hAlign
The display horizontal align.
Definition MapDisplay.h:78
virtual void setExtent(te::gm::Envelope &e, bool doRefresh=true)
It sets the world visible area and refreshes the contents in the map display.
te::gm::Envelope m_extent
The display extent.
Definition MapDisplay.h:75
virtual ~MapDisplay()
Virtual destructor.
virtual void setSRID(const int &srid, bool doRefresh=true)
It sets a new Spatial Reference System to be used by the Map Display.
virtual te::map::AlignType getVAlign() const
It returns the MapDisplay current vertical align.
std::list< te::map::AbstractLayerPtr > m_layerList
The layer list to be displayed.
Definition MapDisplay.h:76
MapDisplay()
It initializes a new MapDisplay.
virtual void setAlign(te::map::AlignType h, te::map::AlignType v)
It will set the align rendering of objects into the map display. Just successive drawings will be aff...
virtual const te::gm::Envelope & getExtent() const
It returns the world extent showned by the MapDisplay.
virtual te::map::AlignType getHAlign() const
It returns the MapDisplay current horizontal align.
Namespace for the Map Tools module of TerraLib.
AlignType
This enum contains values to control the alignment of components (like Canvas and MapDisplay).
Definition Enums.h:126
TerraLib.
#define TEMAPEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition Config.h:60