[Chameleon] Legend template using group rather than layer

Tracy Howlett thowlett at whistlermuseum.org
Thu May 20 20:24:29 EDT 2004

Hello All, 

This conversation is really interesting to me.  I've been using the
XMLThemeLegend but now need to incorporate classes.  I've read back through
Rene's thread about getting the LegendTemplate.widget to work but I don't
want a popup.  I want the legend to display all of the time.  How can I stop
the legend from popping up.  The Embed tag seems to make no difference.

Also - the resulting popup legend says 'no icon' before each heading and
then lists a 0 after.  What does this mean?  How can I get the check boxes
and legend boxes to show up?


-----Original Message-----
From: chameleon-bounces at lists.maptools.org
[mailto:chameleon-bounces at lists.maptools.org] On Behalf Of Daniel Morissette
Sent: Thursday, May 20, 2004 7:39 AM
To: spencer at dmsolutions.ca
Cc: Chameleon
Subject: Re: [Chameleon] Legend template using group rather than layer

Paul Spencer wrote:
> "HTML block to use for layer group headers if layers should be grouped 
> in the legend. If not set then layers are not grouped in the legend.
> When the [leg_group_html] tag is used, then layers that don't belong to 
> any group (i.e. LAYER GROUP not set in the mapfile) and their classes 
> will not show up at all in the legend. The group list is decided by the 
> order_metadata parameter, which is explained later."
> What I think is most confusing here is that layers that have no group 
> will not show up in the legend if the leg_group_html is used, regardless 
> of whether you use a leg_layer_html or not.

If you think of a grouped legend as a hierarchy of objects then it all 
makes sense:  A grouped legend contains [1..n] groups which contain 
[1..n] layers which in turn contain [1..n] classes.

If you decide that your legend is going to use groups then it is not 
possible to display layers that don't have a group setting because they 
are orphan and are not attached to anything in the hierarchy described 

We could have decided to create a default (null) group I guess... I'm 
not sure why we didn't, but anyway if you are going to use groups in 
your legend then it just makes sense to use them everywhere or not at all.

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

Chameleon mailing list
Chameleon at lists.maptools.org

More information about the Chameleon mailing list