Bug 35 - [Chameleon] XMLThemeLegend-> use ms generated leg_icons/symbol definition.
: [Chameleon] XMLThemeLegend-> use ms generated leg_icons/symbol definition.
Status: NEW
: Chameleon
Widget
: 1.99
: PC Windows 2000
: P4 enhancement
: FUTURE
Assigned To:
:
:
:
:
:
  Show dependency treegraph
 
Reported: 2003-08-11 15:52 by
Modified: 2004-08-10 16:03 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2003-08-11 15:52:24
A good enhancement request to the XMLThemeLegend widget. Is to allow the user to
get mapserver to auto generate the legend icons, based on symbol layer
definitions. Currently the user must point to an image for each group within the
XML theme file. 

Currently:
        <group name="Beach" visible="true" icon="./images/beach.png">
	    <layer name="Beach_rec"/>
               <layer name="Resort_rec"/>
        </group>

Proposed:
        <group name="Beach" visible="true" icon=" Beach_rec ">
	    <layer name="Beach_rec"/>
                <layer name="Resort_rec"/>
        </group>

(Where the ThemeParser would search the layers within the group to see if
“Beach_rec” layer is found. If layer name found go to mapfile to get the symbol
definition of the first class.)


Also, it would be handy if a symbol definition can be read from the theme layers
to display the legend icon. 

Eg.
        <group name="Beach" visible="true" symbol="beach ">
	    <layer name="Beach_rec"/>
                <layer name="Resort_rec"/>
        </group>

(Where the symbol definition would be read directly from the symbol.sym file
used in the mapfile.)
------- Comment #1 From 2004-04-07 12:21:07 -------
this is an interesting idea and probably quite useful but very hard to implement
so that it will work consistently in all uses.  The primary use of the
XMLThemeLegend was originally to abstract layers into groups of layers for use
with Context file (which have no sense of grouping), this makes it difficult to
preserve the design of the widget and provide a one-to-one mapping from the
interface to layers in the map file.

A better solution would be to use the XMLThemeLegend to generate layer controls
and the LegendTemplate to generate a real legend with icons.
------- Comment #2 From 2004-04-08 08:39:15 -------
updated version to 1.99
------- Comment #3 From 2004-04-14 10:31:30 -------
Since seeing how the XML Theme Legend widget and the HTML Legend can work
together within an application (ie. gsc_worldminerals). I makes total sense to
separate map layer/group interaction, from legend information.

I guess the problem originated when we were trying to us the HTML Legend in an
unrealistic manner. In the future I hope we will never use the HTML Legend as a
layer/group controller.
------- Comment #4 From 2004-07-07 17:10:14 -------
Changed target to 2.1.
------- Comment #5 From 2004-08-10 16:03:58 -------
Changed Target Milestone to FUTURE. (Enhancements may be moved from this target 
to specific "versioned" targets after product design review cycles.)