TOC widget - Trying to make legend icons smaller

472
2
Jump to solution
05-10-2012 05:42 AM
BoCastillo
New Contributor
I've been customizing Robert Scheitlin's TOC widget version 2.5. I've been able to figure out everything in my list of changes, except one thing. I want to make the legend icons smaller, more specifically I would like to adjust the polygon icons.
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus
Bo,

   You are digging in pretty deep when you want to start changing swatch and images sizes... In the TocMapLayerItem.as in the processRenderer function look for createSwatch and adjust sizes there. That is only for ArcGIS Server with versions older than 10.01... For the other cases you need to look still in the TocMapLayerItem.as and find the loadImage function and make adjustments there. Best of luck hopefully your tweaks won't screw with the layout of items.

Don't forget to click the Mark as answer check on this post and to click the top arrow (promote).
Follow the steps as shown in the below graphic:

View solution in original post

0 Kudos
2 Replies
RobertScheitlin__GISP
MVP Emeritus
Bo,

   You are digging in pretty deep when you want to start changing swatch and images sizes... In the TocMapLayerItem.as in the processRenderer function look for createSwatch and adjust sizes there. That is only for ArcGIS Server with versions older than 10.01... For the other cases you need to look still in the TocMapLayerItem.as and find the loadImage function and make adjustments there. Best of luck hopefully your tweaks won't screw with the layout of items.

Don't forget to click the Mark as answer check on this post and to click the top arrow (promote).
Follow the steps as shown in the below graphic:
0 Kudos
BoCastillo
New Contributor
Thanks Robert!

I was trying to work with the "processRenderer" function, since it seemed the most obvious. After about a full day of futile code changes while using 10.02, I gave up and decided to ask a question. I would've never have thought to alter the "loadImage" function. Anyway, I'm on my way to finalizing my adjustments.

Thanks again,
Bo
0 Kudos