[Fwd: Re: [UMN_MAPSERVER-DEV] single classed layers and GetLegendGraphic]

Daniel Morissette dmorissette at DMSOLUTIONS.CA
Tue Nov 9 11:06:28 EST 2004


Kralidis,Tom [Burlington] wrote:
> RULE makes me nervous because it's a MapServer specific which a WMS
> client doesn't necessarily know at runtime.
>

What do you mean by MapServer specific? RULE is part of the SLD spec
AFAIK, and the current behavior was derived from cubeserv examples (see
bug 653).


> This is what I propose:
>
> - update GetLegendGraphic to:
>  - print out legend icons of one layer as *just* an icon if there's only
> one CLASS object
>   - code change needed to handle this
>  - print out legend icons of one layer with text of rule names if
> there's more than one CLASS object
>   - this is present behaviour -- no code change required

This would still result in an unpredictable behavior for clients: it
would be impossible for a client to know whether they should expect a
single icon or a legend with text labels unless they go back to the
server and find out if there are multiple rules (classes) or not.

I think we need to be consistent: either always produce a label when no
rule is specified (the current behavior), or never produce a label (that
was our first interpretation but we had requests to align our behavior
with other servers in bug 653).


>  - implement a VendorSpecific Capability called "GetLegend" which acts
> like mode=legend, and prints out 'full' legends of multiple layers,
> which includes titles for layers with icons
>

That might be nice for clients that know they're dealing with MapServer,
but won't help for "real" interoperability until this request is added
to the spec.

Daniel
--
------------------------------------------------------------
  Daniel Morissette               dmorissette at dmsolutions.ca
  DM Solutions Group              http://www.dmsolutions.ca/
------------------------------------------------------------



More information about the mapserver-dev mailing list