TNLayer

Hierarchy

TReadMapFile->TCollectionItem->TPersistent->TObject

Unit

uNLayer

Description

Object layer, an element of collection TNLayers. It is used for work with one layer of data MapInfo which includes geographical coordinates and table data. There are three ways of data location in a component. The first way to set property "FileName" a path on the disk. The second way, for convenience of carrying the application on the other computer, it is possible to set the path to geographical data through the system registry. For this purpose fill in properties "NRegistryRoot", "NRegistryPath", "NRegistryName" which indicate path value from registry. Now in property "FileName" it is possible to use a keyword %REG%. Opening the layer, the keyword will be replaced with value from registry. The third way to save the geographical data in file DFM, in given way the application can consist of one file. It is also possible to set the following parameters:
  • Scale parameter in which the given layer will be shown.
  • Parameter which is responsible for an opportunity to select objects on the given layer.
  • Display parameters of object labels on the map, to set style of a label font.
Also you can connect with an external source of data.

Properties

property SaveToDFM:Boolean Defines to save map in DFM file
Property NRegistryRoot:HKEY Defines way in Windows registry for getting the path to map
Property NRegistryPath:String Defines way in Windows registry for getting the path to map
Property NRegistryName:String Defines way in Windows registry for getting the path to map
Property NMinWidth:double Minimum width of the visibility area of the map
Property NMaxWidth:double Maximum width of the visibility area of the map
property FileName: TFileName

Path to map files

property ShowMap:Boolean Defines to display layer with map on screen
property SelectMap: Boolean Defines the opportunity of selection objects in layer
Property LabelParams:TLabelParams Defines possibility of the selecting object in layer
property DrawLabels: Boolean Display labels in layer

Methods

constructor Create(Collection: TCollection) Constructor
destructor Destroy Destructor
Procedure Assign (Source:TPersistent) Copyings one layer in another
Procedure Loaded For interaction with TNMap

Events