You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current approach(es) to manage and retrieve style titles, and consequently legends, is a grey area, where a mix of solutions are implemented in GeoNode and its client.
The root issue is that the declaration of the style must be done inside the style body itself, and for this reason it also differs between style formats (SLD, CSS, etc.).
For a CSS it can be defined with the @styleTitle attribute. For an SLD the usual approach is to rely on the UserStyle.Title element.
This approach has several drawbacks, last but not least the difficulty for the client to take control of the title while the style content is being edited.
Geoserver provides a very useful feature for styles: metadata. A style can have associated metadata, that currently can be managed through style REST API PUT requestsm and can be retrieved doing a style REST API GET request with the XML format.
An example of a custom title metadata attribute is shown here below:
Currently neither MapStore nor GeoNode rely on this capability, but this would make the management of title far more robust and indepdent from the style format.
To have this in place the followin steps are requred:
implement the parsing of the title metadata (if available) inside geoserver_restconfig, and use this to populate the sld_title field. GeoNode already uses this field in case it's populated
The text was updated successfully, but these errors were encountered:
The current approach(es) to manage and retrieve style titles, and consequently legends, is a grey area, where a mix of solutions are implemented in GeoNode and its client.
The root issue is that the declaration of the style must be done inside the style body itself, and for this reason it also differs between style formats (SLD, CSS, etc.).
For a CSS it can be defined with the
@styleTitle
attribute. For an SLD the usual approach is to rely on theUserStyle.Title
element.This approach has several drawbacks, last but not least the difficulty for the client to take control of the title while the style content is being edited.
Geoserver provides a very useful feature for styles: metadata. A style can have associated metadata, that currently can be managed through style REST API PUT requestsm and can be retrieved doing a style REST API GET request with the XML format.
An example of a custom
title
metadata attribute is shown here below:Currently neither MapStore nor GeoNode rely on this capability, but this would make the management of title far more robust and indepdent from the style format.
To have this in place the followin steps are requred:
UserStyle.Title
element (as it currently does). An issue already exists for this Add metadata to Style Editor to manage title and description geosolutions-it/MapStore2#3750sld_title
field. GeoNode already uses this field in case it's populatedThe text was updated successfully, but these errors were encountered: