开发者

Can someone show me how to style a radiobutton in Silverlight XAML to outline it (or change it's color) when it get's focus?

开发者 https://www.devze.com 2023-02-11 05:58 出处:网络
I have a radiobutton VisualStateGroup for Focuses, but I don\'t know how to change the storyboard to highlight the radiobutton on focus.

I have a radiobutton VisualStateGroup for Focuses, but I don't know how to change the storyboard to highlight the radiobutton on focus.

 <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused">
                                        <Storyboard>
                                 开发者_如何学C           <DoubleAnimationUsingKeyFrames Storyboard.TargetName="ContentFocusVisualElement" Storyboard.TargetProperty="Opacity">
                                                <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Unfocused"/>
                                </VisualStateGroup>


I worked it out. It turns out the the target element needed to be layered on top of the other elements.

0

精彩评论

暂无评论...
验证码 换一张
取 消