summaryrefslogtreecommitdiff
path: root/platform/qt/include/qmapbox.hpp
diff options
context:
space:
mode:
authorThiago Marcos P. Santos <thiago@mapbox.com>2016-02-02 16:38:24 +0200
committerThiago Marcos P. Santos <thiago@mapbox.com>2016-04-20 20:55:51 +0300
commit19e11293676db729909e10659f3e0710a251a03b (patch)
tree830650dd1a9a885df8df05d60c521a8f90273200 /platform/qt/include/qmapbox.hpp
parentdd075d53edaa34d530bdd4a876ab329f9de45f44 (diff)
downloadqtlocation-mapboxgl-19e11293676db729909e10659f3e0710a251a03b.tar.gz
[Qt] Add the QMapbox header with QMapbox datatypes
Diffstat (limited to 'platform/qt/include/qmapbox.hpp')
-rw-r--r--platform/qt/include/qmapbox.hpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/platform/qt/include/qmapbox.hpp b/platform/qt/include/qmapbox.hpp
new file mode 100644
index 0000000000..8877d730bb
--- /dev/null
+++ b/platform/qt/include/qmapbox.hpp
@@ -0,0 +1,28 @@
+#ifndef QMAPBOX_H
+#define QMAPBOX_H
+
+#include <QList>
+#include <QPair>
+#include <QString>
+
+// This header follows the Qt coding style: https://wiki.qt.io/Qt_Coding_Style
+
+namespace QMapbox {
+
+typedef QPair<double, double> Coordinate;
+typedef QList<Coordinate> Coordinates;
+typedef QList<Coordinates> CoordinateSegments;
+
+typedef quint32 AnnotationID;
+typedef QList<AnnotationID> AnnotationIDs;
+
+typedef QPair<Coordinate, QString> PointAnnotation;
+typedef QList<PointAnnotation> PointAnnotations;
+
+// FIXME: We need to add support for custom style properties
+typedef QPair<CoordinateSegments, QString> ShapeAnnotation;
+typedef QList<ShapeAnnotation> ShapeAnnotations;
+
+}
+
+#endif // QMAPBOX_H