This project has moved. For the latest updates, please go here.

ColorPicker stays open

Feb 8, 2011 at 2:46 PM

Hi,  thanks so much for your controls - they're great!

I'm using the color picker on a screen with a rich text box and a number of other controls, and I'm having an issue where it stays open even when other controls on the page are selected, unless the user first selects a color or clicks the button to close the popup.  Even it another popup is opened, the color picker popup is still visible.  Is there something I can do to fix this on my end?




Feb 8, 2011 at 2:49 PM

Unfortunately no.  This is a known issue.  The user will have to either select a color or click on the drop down button again to close the popup.  I will research for a fix.

Feb 8, 2011 at 2:49 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Feb 8, 2011 at 2:52 PM

Thanks for such a quick response.  I could be wrong, but I think if you just set StaysOpen="False" on the Popup itself in your generic.xaml, it would behave correctly.

Feb 8, 2011 at 3:03 PM

I don't currently have time to test that out.  If you don't mind, could you try that and let me know if that works.  If so I will put the fix in the code base as soon as I can.

Feb 8, 2011 at 5:46 PM

I just downloaded your source and tested it out, and it works.  All I did was add the StaysOpen="False" to the following line of Generic.xaml

<Popup x:Name="PART_ColorPickerPalettePopup"  VerticalAlignment="Bottom" IsOpen="False" StaysOpen="False" >
Feb 10, 2011 at 12:14 AM

This was actually more complicated than just setting the StaysOpen property to true.  But I have modified the color picker and it should now behave properly.  I even added a small feature that allows you to change the way the selected color is shown in the editor.  Just set the DisplayColorAndName property to true to show a color block and the color's name next to it.

Feb 10, 2011 at 12:07 PM

Awesome, thanks!