This is a migrated thread and some comments may be shown as answers.

No colour and white

3 Answers 88 Views
ColorPicker
This is a migrated thread and some comments may be shown as answers.
Jon
Top achievements
Rank 1
Jon asked on 13 Dec 2011, 11:48 AM
My apologies if this has come up before but when using the ShowIcon mode is there a way to make this work properly with No colour?

If I select no colour then the colour shown in the Icon is white - not the nothing icon (checked background with a red line through it).  I appreciate the fact that it does work behind the scenes but visually this is very misleading to the user.

When opening a form how do I know which are set to white and which are set to no colour?  This wouldn't be so much of a worry if when clicking the icon you could tell if white or no colour is picked but you can't - there is no indication whatsoever which is the active colour.

Does anyone know of a work around and can this be added as a bugfix or improvement (depends on your viewpoint but I regard as a bug).

Best Regards,

Jon

3 Answers, 1 is accepted

Sort by
0
Jon
Top achievements
Rank 1
answered on 14 Dec 2011, 03:49 PM
Further to my comment yesterday I've had to implement the result of changing a colour in a grid - to that end i just used a div and coloured the background accordingly,  then for an empty colour I reused the transparent image as the background-image.

Looking at the css it looks like there is a distinct rule for this, could something be added to the OnClientColorChanging event to change the rule to show an image instead of the background-color style (css tag seems to be .RadColorPicker .rcpIcon em)

It would be nice to have this built in but for now a work around would be helpful

Regards,

Jon
0
Accepted
Slav
Telerik team
answered on 15 Dec 2011, 02:15 PM
Hello Jon,

Thank you for your suggestion about the color preview when the RadColorPicker's ShowIcon property is set to true and No Color is selected. It will be brought to the attention of our developers and the feature's implementation will be discussed.

Currently, such effect could be achieved by modifying the CSS styles of the control on its client event OnClientColorChange, as you have correctly guessed. For your convenience I have prepared a sample project, demonstrating this solution. Please use it as a reference for achieving the desired effect into your actual project.

Kind regards,
Slav
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
0
Jon
Top achievements
Rank 1
answered on 15 Dec 2011, 02:24 PM
Slav,

You're a star!  That works perfectly and it looks much better than having the white.  

If anyone else uses this you'll need to use the same function call for the OnClientLoad event of the colourpicker - otherwise it starts off white...

Thanks again Slav,

Best Regards,

Jon
Tags
ColorPicker
Asked by
Jon
Top achievements
Rank 1
Answers by
Jon
Top achievements
Rank 1
Slav
Telerik team
Share this question
or