vcl-dxmaplayer.md
The base class for map layers.
TdxMapLayer = class(
TcxComponentCollectionItem
)
Map Control content is arranged into layers. Each map layer type is designed to display the corresponding content type – map tiles, shapes (custom marks on a map), etc.
The list below outlines key members of the TdxMapLayer class. These members allow you to configure basic map layer settings and convert map coordinates into different measurement units.
GeoPointToMapUnit | GeoPointToScreenPointConvert geographical coordinates into map and screen coordinates.MapUnitToScreenPointConverts a point position in map measurement units into screen (pixel) coordinates.ScreenPointToGeoPoint | ScreenPointToMapUnitConvert screen (pixel) coordinates into geographical and map point coordinates.
CollectionProvides access to the parent map layer collection.Index
Specifies the map layer’s index in the parent collection.
Tip
The Index property value also determines the map layer’s Z-order (draw order). A map layer with the highest index is displayed on top of all other layers.
We recommend that you display the most transparent layers on top (map item layers with markers, for example).
IsActuallyVisibleIdentifies if the parent Map Control displays the map layer.VisibleSpecifies if the map layer is visible.
The TdxMapLayers.Items property references terminal TdxMapLayer class descendants as a TdxMapLayer object.
Do not use the TdxMapLayer class directly. Use the following descendants instead:
TdxMapImageTileLayerA map tile layer.TdxMapItemFileLayerAn item file layer.TdxMapItemLayerAn item layer.
Call the following Map Control functions to create corresponding supported map layers:
TdxCustomMapControl.AddImageTileLayerCreates a new image tile layer and adds it to the map layer collection.TdxCustomMapControl.AddItemFileLayerCreates a new item file layer and adds it to the map layer collection.TdxCustomMapControl.AddItemLayerCreates a new item layer.
To see map tile layers with all supported information providers in action, run the Mapping demo in the VCL Demo Center installed with compiled DevExpress demos. Click the Data Providers item in the side bar to the left and switch between available data providers in the Ribbon UI.
Tip
Compiled DevExpress demos ship with source code installed in the Public Documents folder (%Public%) for all users ( default ). You can find all project and source code files for the Map Control demo in the following folder:
%Public%\Documents\DevExpress VCL Demos\MegaDemos\Product Demos\ExpressMapControl
TObject TPersistent TComponent TcxCustomComponent TcxComponentCollectionItem TdxMapLayer
See Also