QMapControl is a Qt/Qtopia widget which enables your (mobile) applications to use map data. Simply add the widget to your application, have a look at the API and start developing a fancy geospatial (mobile) application.
With QMapControl you can use different map providers, like OpenStreetMap or several WMS-Server. Then you can modify the view of your QMapControl, writing a location based application when having a GPS receiver or just browse the maps. It is possible to have more than one layers, so you can mix maps from different servers. To enrich the maps you can draw your own object to coordinates.
- Compatible with multiple map providers (Tile server and WMS server)
- Draw custom objects into maps (lines, points, images, even other Qt widgets!)
- Objects can be added to any coordinate
- Control elements can be added to QMapControl's layout
- Added objects emit signals on clicks
- The map navigation is customizable (using styles and/or keys)
- GPS parser included for reading gllin output
- Tested on the FIC Neo1973 and Trolltech Greenphone (and Linux/Windows)
- Map tiles can be stored persistently
- Rotating maps
Download sourcecode including sample applications and documentation
For more up to date sources checkout the SVN from sourceforge
Sample code preview
// create MapControl mc = new MapControl(QSize(480,640)); // create MapAdapter to get maps from MapAdapter* mapadapter = new OSMMapAdapter(); // create a map layer with the mapadapter Layer* l = new MapLayer("Custom Layer", mapadapter); // add Layer to the MapControl mc->addLayer(l);
Complete sample applications: here
- 2008-09-21: version 0.9.5.1: Minor changes: limiting zoom to not exceed min and max borders, showScale caused crash if zoom was out of range
- 2008-06-11: version 0.9.5: new method "enablePersistentCache()" allows to store map tiles, new method "showScale(bool)" allows to display the scale of the current map, license changed to LGPL
- 2008-04-03: version 0.9.4: removed "get" prefixes from ancessor functions, to improve Qt-like design,
renamed event "geometryClickEvent()" to "geometryClicked()",
renamed event "draggedRect()" to "boxDragged()"
- 2008-01-13: Source refactored, several bugfixes
new demoapplication: Citymap
- 2007-12-29: bug fixed: widgets were not displayed correctly in the maps
new feature: a yahoo map adapter is available
- 2007-12-26: bug fixed: wrong locale settings which caused false WMS-requests.
new feature: objects can be resized depending on zoom level
- 2007-12-04: initial version 0.9
On questions, ideas or problems please contact me firstname.lastname@example.org
This software is released under LGPL. Please review the licenses of the map providers you are using. I would recommend using OpenStreetMap, since their map data is released under Creative Commons.
QMapControl in action