osm-gps-map
A Gtk+ widget (and Python bindings) for displaying OpenStreetMap tiles.
Project maintained by nzjrs
Hosted on GitHub Pages — Theme by mattgraham
Download 1.2.2 archive
(Release notes for 1.2.2).
A Gtk+ widget (and Python bindings) that when given GPS co-ordinates, draws a GPS track, and points of interest on a moving map display. Downloads map data from a number of websites, including openstreetmap.org. The library has excellent performance and is currently used in a number of Gtk+ applications.


Currently supports a number of different mapping sources:
- OpenStreetMap (default)
- OpenTopoMap
- OpenCycleMap
- Maps-For-Free
- Google Maps / Satellite and Bing Maps (Virtual Earth)
It also has the following features:
- Intelligent, flexible and customizable caching of maps, including the ability to request a specific area of the map to be cached ahead of time
- Recording of points of interest on the map (and the ability to add arbitrary pixmaps at those points)
- Automatically draws a GPS track (a line showing the history of past added points)
- Automatic centering on new GPS points
- Support for multiple other tracks of co-ordinate points
- Adjustable Zoom
- Built in support for keyboard navigation
- Includes a set of examples
- Simple, flat API
- Support for showing additional display layers rendered on top of the map
- Optional on screen display (OSD)
- Proper map copyright attribution and user-agent usage to comply with various map requirements
Documentation
Install Instructions
osm-gps-map should be packaged by your distribution. On Debian, Ubuntu or similar, you can install the GTK+ library and its Python bindings like this:
sudo apt install libosmgpsmap-1.0-1 gir1.2-osmgpsmap-1.0 python3-gi
And if you want to build some application that depends on osm-gps-map, you can install the development files like this:
sudo apt install libosmgpsmap-1.0-dev
Installing From Source
To build from source on Debian or Ubuntu you will need:
sudo apt install build-essential autoconf automake libtool \
libgtk-3-dev libsoup-3.0-dev libgirepository1.0-dev
Then:
./autogen.sh && make && sudo make install
News
Changes in 1.2.2 (2026-10-11)
- Don't use floats for division because of rounding errors; fixes center hopping (znuh)
- Avoid div-by-zero in latlon2zoom when a latitude or longitude distance is zero (Hubert Kowalski)
- Floor tile origin for negative map-x so overlays stay aligned (Hubert Kowalski)
- Fix insert_point double-free (Hubert Kowalski)
- Hold the map until tile downloads complete so leftover Soup callbacks cannot touch freed tile state (Hubert Kowalski)
- Fix map redraw using width as height (Hubert Kowalski)
- Show drawing on the map in the examples (Hubert Kowalski)
- Add optional Glade catalog installation (Hubert Kowalski)
- Correctly support LFS (David Paleino, Bas Couwenberg)
Download
You may download any of the following archives:
You can also clone the project with Git by running:
$ git clone https://github.com/nzjrs/osm-gps-map.git
A snapshot of master is also available as tar or zip.
License
Authors
- John Stowers
- Till Harbaum
- Alberto Mardegan
- Mark Cottrell
- Originally based on tangoGPS by Marcus Bauer
get the source code on GitHub : nzjrs/osm-gps-map