Table of Contents
The retrieval and local caching of the map tiles, as well as the supported viewing options, are all configured in a simple Java properties file. This is the file being handled by this FileHandler.
The contained properties are grouped into general settings, part of which can be manipulated through the GUI, and the setup of map services with their respective local caching strategies.
The properties for general settings all have a "Setting." prefix and these are being used for all setups. Then there is a comma separated list of setup names in the "SetupNames" property of which the "SetupName" property denotes which of them is the active one. The configuration of each setup is then in the properties with a prefix of "Setups.[setupName].".
In each of those property groups for a specific setup, the "Provider" property denotes the service which is being accessed for tile retrieval. The possible provider types are:
ArcGIS
BingMaps
CacheFile
CacheMemory
GoogleMaps
Offline
OpenStreetMap
WebMapService
YandexMaps
The two caching provider types are special, however: they both have a "Provider" sub-property and thus support building provider chains. An example would be a CacheMemory provider which caches tiles in memory that were retrieved from a CacheFile provider that looks up tiles in a local directory first, before ultimately resolving to one of the URL-based providers (GoogleMaps, etc.) to retrieve a missing local tile from the corresponding internet service:
MapViewerGUI <= CacheMemory <= CacheFile <= GoogleMaps
Another example might be the same caching providers but with an Offline provider at the end of the chain. This could be used to provide access to a local tile repository without any network traffic:
MapViewerGUI <= CacheMemory <= CacheFile <= Offline
In case there is a "Provider" property without a setup prefix, this will take precedence over the configured setups. It will then behave as if no setup names were configured and thus no further prefix will be used for resolving the provider properties.
Table 3.1. The properties for general settings
Property name | Value type | Default value | Description |
---|---|---|---|
Setting.AllowNetwork
|
boolean
|
true
| Determines whether tiles may be retrieved from the internet. |
Setting.Center.Latitude
|
double
|
0.0
| Specifies the initial center coordinate latitude after loading. |
Setting.Center.Longitude
|
double
|
0.0
| Specifies the initial center coordinate longitude after loading. |
Setting.DataDirectory
|
string
|
| Specifies the directory for GPX- and other data. Its value may reference variables which can be resolved from System Properties and DYN_ properties for the .geomap file. |
Setting.DisplayOutdatedCachedTiles
|
boolean
|
true
| Determines whether outdated tiles should be displayed. |
Setting.GPX.*
|
[various]
|
[various]
| These define the setting for the display of GPX data. These can be configured using the GUI and hence don't require manual configuration. |
Setting.Scale
|
integer
|
0
| Specifies the initial scale after loading. Note that this will be limited to lie within the scale boundaries of the active provider. |
Setting.Zoom
|
integer
|
0
| Specifies the initial zoom level after loading. Note that this will be limited to lie within the zoom boundaries of the active provider. |
Table 3.2. The properties for the scale information overlays
Property name | Value type | Default value | Description |
---|---|---|---|
Setting.ScaleInfo.Background
|
color
|
lightGray
| Determines the background color of the scale info overlays. |
Setting.ScaleInfo.FontColor
|
color
|
black
| Determines the font color of the scale info overlays. This is used for the scale and distance estimation texts as well as for the distance length marker lines. |
Setting.ScaleInfo.FontName
|
string
|
Dialog-PLAIN-12
| Determines the font name of the scale info overlays. |
Setting.ScaleInfo.Visible
|
boolean
|
false
| Determines whether the scale info overlays are visible. |
Table 3.3. The properties for the tile cache overlays
Property name | Value type | Default value | Description |
---|---|---|---|
Setting.TileCache.Directory
|
string
|
| Specifies the directory where the cache for tiles should be stored. Its value may reference variables which can be resolved from System Properties and DYN_ properties for the .geomap file. |
Setting.TileCache.OutdatedColor
|
color
|
blue
| Determines the overlay color of outdated cache tiles. |
Setting.TileCache.UnavailableColor
|
color
|
red
| Determines the overlay color of unavailable cache tiles. |
Setting.TileCache.UpToDateColor
|
color
|
green
| Determines the overlay color of up-to-date cache tiles. |
Setting.TileCache.Visible
|
boolean
|
false
| Determines whether the tile cache overlays are visible. |
Setting.TileCache.Zoom
|
integer
|
${Setting.Zoom}
| Determines the zoom level for the cache tiles. |
Table 3.4. The properties for the tile grid display
Property name | Value type | Default value | Description |
---|---|---|---|
Setting.TileGrid.Color
|
color
|
black
| Determines the color of the tile grid lines. |
Setting.TileGrid.FontColor
|
color
|
black
| Determines the font color of the tile grid coordinates. |
Setting.TileGrid.FontName
|
string
|
Dialog-BOLD-18
| Determines the font name of the tile grid coordinates. |
Setting.TileGrid.FontShadow
|
color
|
lightGray
| Determines the font shadow color of the tile grid coordinates. This should be a color that has a good contrast in respect to the font color in order to ensure that the coordinates are legible on all kinds of backgrounds. |
Setting.TileGrid.Visible
|
boolean
|
false
| Determines whether the tile grid lines and coordinates are visible. |
Note that the color property values can be given in a number of different styles:
Some English names like "black", "red" and so forth
Three comma separated integer values for red, green and blue, e.g. decimal "51,102,153" or in hex "0x33,0x66,0x99"
Font name property values are to be given in the following form:
The name of the font, e.g. "Arial", "Courier", "Serif", "Dialog", etc.
A single dash: "-"
One of the strings "PLAIN", "BOLD", "ITALIC", "BOLDITALIC"
A single dash: "-"
The font size as an integer, e.g. "12", "28"
java.awt.Font.decode()
method documentation),
but can quickly lead to undesired results if not adhered to.