Skip to content

What Delphi Google Map is ​

TEdgeGoogleMapViewer is a VCL component that shows a Google Map inside your Delphi application. It is a wrapper on the WebView2 component (TCustomEdgeBrowser, the Microsoft Edge engine) that adds what an application needs from a map: go to an address or to a position, markers, circles, polylines and polygons, routing with the directions panel, map events, and the map type, layers and controls as properties.

You set properties and call methods; the component generates the web page, loads the Google Maps JavaScript API in it and calls its functions for you.

pascal
// Go to an address
EdgeGoogleMapViewer.GotoAddress(MemoAddress.Lines.Text);

// Go to a latitude / longitude
var
  Location: TLatLng;
begin
  Location.Latitude := TEdgeGoogleMapViewer.TextToCoord(Latitude.Text);
  Location.Longitude := TEdgeGoogleMapViewer.TextToCoord(Longitude.Text);
  EdgeGoogleMapViewer.GotoLocation(Location);
end;

// Change the view mode
EdgeGoogleMapViewer.MapTypeId := mtHYBRID;

At a glance ​

ComponentTEdgeGoogleMapViewer, unit Vcl.GoogleMap, in the Ethea page of the palette
FrameworkVCL only (it needs WebView2)
Delphi10.4.2, 11, 12 and 13
PlatformsWindows 32 and 64 bit
NeedsA Google Maps API key, an internet connection, WebView2Loader.dll and the Microsoft Edge WebView2 Runtime on the user's machine
LicenseApache 2.0

What it can do ​

  • Show the map: by address or coordinates, map type (road map, satellite, hybrid, terrain), zoom, traffic and bicycling layers, controls, light and dark colour scheme.
  • Markers: by coordinates or by address, with label, animation, info window and custom drawing.
  • Circles, polylines and polygons, and the distance between two points.
  • Routing between addresses or coordinates, with the directions panel.
  • Events: click, right click and zoom of the map.
  • Your own JavaScript inside the page, for what the component does not wrap.

There is a complete demo that uses every one of these, and the Quick Start goes from an empty form to a map.

The documentation is the demo too

The demo application is where each feature is shown at work, with the Delphi code that calls it. Open Demo\GoogleMaps\GoogleMapsTest.dproj: the pages of this site refer to its code.

License ​

Copyright © 2021-2026 Ethea S.r.l. Licensed under the Apache License, Version 2.0. Google Maps is a product of Google; its use is subject to the Google Maps Platform terms.

Released under the Apache License 2.0