C
C#2y 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
JakenVeina2y ago
what icon?
ApathyErr
ApathyErrOP2y 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
JakenVeina2y ago
is that actually an image?
ApathyErr
ApathyErrOP2y ago
yes they are from the "fontawesome sharp" add-on
JakenVeina
JakenVeina2y 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
Accord2y 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.
Want results from more Discord servers?
Add your server