I was wondering, whether it is possible to style the CustomMessageBox from Windows Phone 8 Toolkit more precisely?
In this case, I'd like to have different foreground colors for the Caption and for the actual Message / the button text/border.
Can I define the Box in XAML as well?
It should not be too much effort. All you have to do is subclass
CustomMessageBox
, add dependency properties for the separate foreground colors, and then modify the default control template. (You will see that default template uses the sameForeground
property for the title, caption, message, and button.)As an example, let's take the title color. First add a dependency property:
Now modify the appropriate part of the control template. Use a
TemplateBinding
to reference the new property:(Note that you can find the full control template in the WP8 toolkit download, in the file
Themes\Generic.xaml
. Just copy-paste into your project's resources, and modify.)