ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Communication / Google functions / Managing Google Maps
  • Properties specific to gglMapParameter variables
  • Functions that use gglMapParameter variables
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
gglMapParameter (Variable type)
In french: gglParamètreCarte
The type gglParameterCarte is used to define all the advanced features of a map: points, paths, etc. The characteristics of this map can be defined and modified using various WLanguage properties.
Then, the corresponding map can be retrieved by GglGetStaticMap.
Note: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
// Paramétrage d'une carte
Params is gglMapParameter
// Définition des marqueurs
M1 is gglMarker
M1.Latitude = 47.022356
M1.Longitude = 52.423654
M1.Color = 0x0000FF // bleu
M1.Size = gglSmall
// Ajout des marqueurs
Add(Params.Marker, M1)
// Paramètres divers
Params.Format = gglJPG
Params.Border = True
Properties

Properties specific to gglMapParameter variables

The following properties can be used to handle gglMapParameter variables:
Property nameType usedEffect
AreagglCoordinateSpecifies the range in latitude and in longitude that must be displayed on the map. In order for this parameter to be taken into account, the <Zoom> parameter found in GglGetStaticMap must correspond to the gglAutoZoom constant.
In previous versions, this property corresponds to Span.
BorderBoolean
  • True to add a border around the image,
  • False to display no border.
The characteristics of the frame are as follows: blue frame, 5 pixels wide, with 55% opacity.
Remark: since the switch to version 2 of Google's service, this parameter has become obsolete and is ignored.
FormatString constantFormat of image received. This parameter can correspond to the following constants:
  • gglGIF (default): image in GIF format
  • gglJPG: image in JPG format.
  • gglJPGNonProgressive: image in non-progressive JPG format.
  • gglPNG8: image in PNG 8 format
  • gglPNG32: image in PNG 32 format
LanguageCharacter stringLanguage in which the information will be displayed on the map. This parameter can correspond to "fr", "en", "de", ...
MarkerArray of gglMarkerMarkers to display on the map. The maximum number of markers that can be used is set to 50. This number is reduced if points are added (indeed, the size of the URL expected by Google limits the maximum number of markers).
MobileDeviceBoolean
  • True to retrieve a map optimized for the display on a mobile device,
  • False otherwise.
PathgglPathPath to draw on the map. The drawing of the route uses the specified points (and not the streets on the map). The points are linked by a line.
ScaleIntegerModifies the number of pixels returned. This property is required for a display on a high-resolution screen.
If the Scale property is set to 2, it returns twice as many pixels as if it were set to 1, for the same area covered and the same level of detail (map content is unchanged).
Possible values:
  • 1 (default value),
  • 2,
  • 4 (available if owning a Google Maps APIs Premium Plan license).
Remarks

Functions that use gglMapParameter variables

GglGetStaticMapRetrieves the map of a specific location via the Google Maps service.
Related Examples:
The GglGetStaticMap function Unit examples (WINDEV): The GglGetStaticMap function
[ + ] Using gglGetMap to display a Google map in an Image control.
The GglGetStaticMap function Unit examples (WEBDEV): The GglGetStaticMap function
[ + ] Using GglGetStaticMap function to display a Google map in an Image control.
Minimum version required
  • Version 14
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 09/20/2024

Send a report | Local help