[OpenLayers-Users] Control Panel Multiple Tools with different icons

Christopher Schmidt crschmidt at metacarta.com
Thu Dec 6 15:59:13 EST 2007


On Thu, Dec 06, 2007 at 10:45:49PM +0200, Andrew de Klerk wrote:
> The measure tool will be implemented using the "DrawFeaturePath" and the
> Delete feature using the "SelectFeature". I can successfully assign the
> appropriate function to each tool, but cannot seem to get it right in
> assigning an appropriate icon through the stylesheet - i.e Measure icon
> always defaults to the DrawFeaturePathItemActive/Inactive icons regardless
> of trying to assign it different classes. 

If you look in firebug, is your displayClass being applied? This would
show up as the class name being "MeasureTool" on the control.panel div.

> What do I need to do to assign it a different icon? Also, How do you assign
> the default control to your panel? I think my syntax must be incorrect below
> for "defaultControl".  Below is my code I have implemented:

Control.Panel only takes on arg. Put 'em all together.

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list