C
C#15mo ago
ApathyErr

❔ WPF how do I recolor the icon on hover?

I repainted the background of the button that uses the icon using this code, but I can't apply it to the icon.
6 Replies
JakenVeina
JakenVeina15mo ago
what icon?
ApathyErr
ApathyErr15mo ago
<Style x:Key="menuButtonIcon" TargetType="fa:IconImage">
<Setter Property="Foreground" Value="{Binding Path=Tag, RelativeSource={RelativeSource AncestorType=RadioButton}}"/>
<Setter Property="Width" Value="22"/>
<Setter Property="Height" Value="22"/>
<Setter Property="Margin" Value="35,0,20,0"/>
</Style>
<Style x:Key="menuButtonIcon" TargetType="fa:IconImage">
<Setter Property="Foreground" Value="{Binding Path=Tag, RelativeSource={RelativeSource AncestorType=RadioButton}}"/>
<Setter Property="Width" Value="22"/>
<Setter Property="Height" Value="22"/>
<Setter Property="Margin" Value="35,0,20,0"/>
</Style>
JakenVeina
JakenVeina15mo ago
is that actually an image?
ApathyErr
ApathyErr15mo ago
yes they are from the "fontawesome sharp" add-on
JakenVeina
JakenVeina15mo ago
you can't recolor an image that just doesn't even make sense images are static, by definition, and don't have just one color
Accord
Accord15mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.