• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

marble

  • sources
  • kde-4.14
  • kdeedu
  • marble
  • src
  • lib
  • marble
  • geodata
  • handlers
  • kml
KmlRangeTagHandler.cpp
Go to the documentation of this file.
1 #include "KmlRangeTagHandler.h"
2 
3 #include "MarbleDebug.h"
4 
5 #include "KmlElementDictionary.h"
6 
7 #include "MarbleGlobal.h"
8 #include "GeoDataLookAt.h"
9 #include "GeoParser.h"
10 #include "GeoDataCoordinates.h"
11 
12 
13 namespace Marble
14 {
15 namespace kml
16 {
17 KML_DEFINE_TAG_HANDLER (range)
18  GeoNode *KmlrangeTagHandler::parse (GeoParser & parser) const
19  {
20  Q_ASSERT (parser.isStartElement ()
21  && parser.isValidElement (kmlTag_range));
22 
23  GeoStackItem parentItem = parser.parentElement ();
24 
25  if ( parentItem.is<GeoDataLookAt>() ){
26 
27  QString rangeTemp = parser.readElementText().trimmed();
28  qreal range = rangeTemp.toDouble();
29 
30  parentItem.nodeAs<GeoDataLookAt>()->setRange( range );
31  }
32 
33  return 0;
34  }
35 }
36 }
37 
GeoDataCoordinates.h
Marble::kml::kmlTag_range
const char * kmlTag_range
Definition: KmlElementDictionary.cpp:147
Marble::GeoNode
A shared base class for all classes that are mapped to a specific tag (ie.
Definition: GeoDocument.h:60
GeoParser.h
KmlRangeTagHandler.h
QString::toDouble
double toDouble(bool *ok) const
MarbleDebug.h
Marble::GeoParser
Definition: GeoParser.h:40
GeoDataLookAt.h
KmlElementDictionary.h
QString::trimmed
QString trimmed() const
Marble::GeoStackItem
Definition: GeoParser.h:97
KML_DEFINE_TAG_HANDLER
#define KML_DEFINE_TAG_HANDLER(Name)
Definition: KmlElementDictionary.h:242
QString
MarbleGlobal.h
Marble::GeoDataLookAt
Definition: GeoDataLookAt.h:23
Marble::kml::KmlrangeTagHandler
Definition: KmlRangeTagHandler.h:11
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:40 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

marble

Skip menu "marble"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal