Each map component is created with certain settings. Adjusting the settings allows you to make small modifications to the created map components, such as removing components, or adjusting tooltips without the need to write code.
The settings for the map components are not stored directly in the configuration file of the The
TLcyLspMapAddOn.cfg file contains pointers to the configuration file of the map component
This mechanism was used to support multiple map types. |
The default settings are stored in a configuration file.
The path to that configuration file is defined in the configuration file of the TLcyLspMapAddOn
(TLcyLspMapAddOn.cfg
).
If you want to change the configuration file for a map component, you need to update that path and let it point to a custom configuration file.
For example, if you want to adjust the logo on the map for all maps of the default type, you:
-
Create a custom configuration file containing the adjusted settings for the default map component type:
# Include the default configuration, so that you only need # to overwrite the settings you want to customize includeConfig=lucy/lspmap/TLcyLspMapAddOn_MapComponent.cfg # Adjust the logo TLcyLspMapAddOn.logo.imageFileName=path/to/custom/logo.png
-
Create a custom configuration file for the
TLcyLspMapAddOn
where you replace the configuration file for the default map component type:Program: Custom configuration file for theTLcyLspMapAddOn
# Include the default configuration, so that you only need # to overwrite the settings you want to customize includeConfig=lucy/lspmap/TLcyLspMapAddOn.cfg # Replace the configuration file of the default map component type # with the custom file created in the previous step TLcyLspMapAddOn.configurationFile.default=path/to/custom/config/file.cfg
-
Adjust the
addons.xml
file to let theTLcyLspMapAddOn
use the modified configuration file. See How to customize the configuration file of a standard Lucy add-on for more info on how to change the config file of an add-on.
See the available documentation in the TLcyLspMapAddOn_MapComponent.cfg
file to discover which options the configuration file supports.
If the configuration file does not support the change you want to make, it is possible to adjust the TLcyLspMapComponentFactory
itself, as explained in How to modify a map component through the API.