I have made a control in silverlight that has a SolidColorBrush property. In XAML, you can set this to be preexisting Colors such as Black, Yellow, White, etc. I assume there is a TypeConverter that takes the string “Black” and converts it to a Color object and creates a new SolidColorBrush based on this object. I want this functionality to remain, but with the added capability to also accept hex strings to set the color. I would need a TypeConverter for this, correct? Is there a way I can extend from the current one so that I can still pass in color names?
I have made a control in silverlight that has a SolidColorBrush property. In XAML,
Share
XAML already accepts hex. Eg:
Having the VS Properties pane open while on a XAML element helps indicate possibilities thats aren’t necessarily obvious via intelisence (Eg setting Background as hex or a gradiant brush).