WPF: In Expression Blend, how to change Foreground of a custom button with a Border on different states?

Posted by SubmarineX on Stack Overflow See other posts from Stack Overflow or by SubmarineX
Published on 2013-06-25T04:30:43Z Indexed on 2013/06/28 4:21 UTC
Read the original article Hit count: 147

Filed under:
|
|
|

In Expression Blend 4, I want to change the Foreground of a custom button on different states. I'm just able to change the Background and BorderBrush.

Just like this:

enter image description here

If the state is "Normal", the color of text "Button" is Black, while the state is "Pressed", the color of text "Button" is White.

On Brushes Panel under Properties Panel, there're 3 properties but no Foreground property: enter image description here

Who can help me? I'm so perplexed.

Edit

I find ContentControl have a Foreground property, but ContentPresenter haven't. Wether I should use ContentControl instead of ContentPresenter?

© Stack Overflow or respective owner

Related posts about wpf

Related posts about templates