change dynamic legend text color from default black to another color

1187
3
08-25-2014 08:05 AM
AdrianoNicolucci
New Contributor

Hi,

I am trying to set up a layout templates for the export web map tool. The layouts I am using have a black background. I understand that you can change the text color of the legend in a map document by clicking properties  -> items on the legend but however, if I remove all the layers and then re-add them, the color will go back to the deafult "black" which then can't be visible on my black backround.

Is there a way to set up the templates to recognize a specific color as the legend text default so when I use the export web map tool, the exported map will not have a legend with black text?

0 Kudos
3 Replies
BrandonVan_Horn
Occasional Contributor

You can add a css to the property of the text, load it below the esri.css. While this works it is not to friendly for changing versions. Hope that helps.

0 Kudos
AdrianoNicolucci
New Contributor

Hi Brandon,

Thanks you for your response!

Can you add a css property to the legend properties? The legend box is dynamic and I don't see any options in the legend properties to add a css to the property of the text.

0 Kudos
BrandonVan_Horn
Occasional Contributor

Try adding this in your css after the claro and esri css.

.dijitReset {

color: white !important;

}

This command overrides the other css source. Also note that I tested this on 3.10 javascript. It may or may not work other versions. Another thing that you could do is change the background color on the Legend box to make the text show up. Good luck.

0 Kudos