Modify

Opened 2 years ago

Last modified 21 months ago

#22725 new enhancement

Add legend for WMS

Reported by: nkamapper Owned by: team
Priority: normal Milestone:
Component: Core imagery Version:
Keywords: Cc:

Description

It would be great to see legends for WMS imageries.

For example, for the Trafikverket road network endpoint in Sweden, and for the "Hastighetsgrans" (maxspeed) layer, there are only colours for each maxspeed but no number, so interpreting the layer is not easy.

However, in the GetCapabilities the WMS layer defines in the LegendURL element the following link to a legend: https://geo-netinfo.trafikverket.se/mapservice/wms.axd/NetInfo?service=WMS&request=GetLegendGraphic&version=1.3.0&sld_version=1.1.0&format=image/png&layer=Hastighetsgrans&width=171&height=128

The legend could be a pop-up window available from the list of layers.

Attachments (0)

Change History (7)

comment:1 by stoecker, 2 years ago

Owner: changed from team to nkamapper
Status: newneedinfo

terms-of-use-url A link that is opened, when the user clicks on the terms-of-use text
terms-of-use-text Customized text for the terms of use link (default is "Background Terms of Use")

What about simply reusing these two maps info fields? Should be displayed at the bottom of the page. Add the link there and call it "Legend" ;-)

Last edited 2 years ago by stoecker (previous) (diff)

comment:2 by nkamapper, 2 years ago

The link is different for each layer.

comment:3 by stoecker, 2 years ago

Is legendurl a widespread usage or only a special case? In the second case I'd recommend to make multiple maps entries for each layer or create a webpage which joins all legends into one linkable page.

In the first case JOSM should support it.

comment:4 by nkamapper, 2 years ago

I think legendurl is a standard feature of most WMS. Something that one would expect to see.
Not related only to the example above but a particular problem there because there are so many different layers.

comment:5 by stoecker, 2 years ago

Well, WMS has a large amount of features. Most of them seldom used or not very helpful or badly configured or ...
So the question for implementation is always if there is a benefit for multiple systems or only for very few.

Last edited 2 years ago by stoecker (previous) (diff)

comment:6 by nkamapper, 2 years ago

Agree, but a large number of WMS services use colour coding and symbols which are not easy to guess - I think the majority in my region (Scandinavia), so it certainly would be helpful. There recently was a discussion on the Swedish community on how to interpret the example above.
And many WMS browsers are using the imageurl.

comment:7 by nkamapper, 21 months ago

Owner: changed from nkamapper to team
Status: needinfonew

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from team to the specified user.
Next status will be 'needinfo'. The owner will be changed from team to nkamapper.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from team to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.