[ka-Map-users] setting up keymap and legend

Dylan Beaudette dylan.beaudette at gmail.com
Tue Feb 20 18:07:42 EST 2007


Hi everyone,

I am wondering if there is a better way to customize the display of the legend 
and keymap. I have hacked something together, but it does not scale well when 
the legend gets over about 7 entries.

from kaExplorer/startUp.js:

// i changed the following two lines:
//getRawObject('mapLegend').style.top = parseInt(getObjectHeight(service)) 
+ "px";
//getRawObject('mapInfo').style.top = "0px";

// into these:
getRawObject('mapInfo').style.top = "275px";
getRawObject('mapLegend').style.top = "0px";

I wanted the legend and keymap to be shown on the same panel, and thus hard 
coded these values. I cannot seem to figure out how to automatically set the 
height of the legend or mapinfo section based on the inherent size of the 
legend. i.e. this does not work as expected:

getRawObject('mapLegend').style.top = parseInt(getObjectHeight(service)) 
+ "px";

any ideas?

thanks!


-- 
Dylan Beaudette
Soils and Biogeochemistry Graduate Group
University of California at Davis
530.754.7341


More information about the ka-Map-users mailing list