Bug 320009

Summary: Support reading and writing gx:altitudeMode KML tags
Product: [Applications] marble Reporter: Dennis Nienhüser <nienhueser>
Component: generalAssignee: Sanjiban Bairagya <sanjiban22393>
Status: RESOLVED FIXED    
Severity: task    
Priority: NOR    
Version: 1.6 (KDE 4.11)   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:

Description Dennis Nienhüser 2013-05-19 12:19:16 UTC
We support the <altitudeMode> tag currently, but not <gx:altitudeMode> which extends <altitudeMode> by two more values.
https://developers.google.com/kml/documentation/kmlreference#gxaltitudemode

- Extend the AltitudeMode enum in src/lib/MarbleGlobal.h by the two additional values
- Add a KmlGxAltitudeModeTagHandler that behaves like the existing KmlAltitudeModeTagHandler, but listens to the gx: namespace and parses the two additional values also
- Add a KmlAltitudeModelTagWriter which can both write <altitudeMode> and <gx:altitudeMode>. Have it switch between both based on the enum value to write
- Change KmlCameraTagWriter.cpp, KmlGroundOverlayWriter.cpp, KmlLatLonAltBoxWriter.cpp and KmlModelTagWriter.cpp to use the new KmlAltitudeModelTagWriter instead of writing altitudeMode manually
- Add a test .kml file to tests/data/ which has various combinations of altitudeMode inside and outside the gx namespace with various values. Add the .kml file to tests/TestGeoDataWriter.cpp and verify it works as extended