Sign in to follow this  
Dhruva

Bulb widget showing only upper limit color

Recommended Posts

I am trying to use a bulb widget. This is the XML that I am using:

 

 

 

 

 

 

 

 

 

'0.0'

 

 

 

 

The color that shows up when I use this XML is B41527 - a shade of red when actually the color should be 399E38 which is a shade of green.

 

 

 

Is there something I'm missing?

 

 

 

Thanks

 

Kamal

Share this post


Link to post
Share on other sites

Hello Kamal,

You are inputting the value inside quotes, which is not valid. Also, the color range must be specified in ascending order, which was not the case in the XML you attached. I am pasting the modified XML here, please check:

<chart bgColor='000000,000000' bgAlpha='100' canvasBgColor='000000' showValue = '' lowerLimit = '0.0' upperLimit = '1.0'>

<colorRange>

<color minValue='0.0' maxValue='0.0' code='399E38' />

<color minValue='0.5' maxValue='0.5' code='F87217' />

<color minValue='1.0' maxValue='1.0' code='B41527' />

</colorRange>

<value>0.0</value>

</chart>

I hope this helps!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this