设为首页 加入收藏

TOP

WPF中textBlock 变色功能
2019-09-17 18:25:05 】 浏览:19
Tags:WPF textBlock 变色 功能
       
  <Window.Resources>
 <Storyboard x:Key="OnLoaded" RepeatBehavior="Forever" AutoReverse="True"  >
            <ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="btn_Register">
                <EasingColorKeyFrame KeyTime="0:0:1" Value="LightBlue"/>
                <EasingColorKeyFrame KeyTime="0:0:2" Value="LightGreen"/>
            </ColorAnimationUsingKeyFrames>
        </Storyboard>
    </Window.Resources>
    <Window.Triggers>
        <EventTrigger RoutedEvent="FrameworkElement.Loaded">
            <BeginStoryboard  Storyboard="{StaticResource OnLoaded}"/>
        </EventTrigger>
    </Window.Triggers>
<Button
                    Name="btn_Register"
                    Margin="62,26,-60,2"
                    Content="新用户注册"
                    Command="{Binding Path=RegisterCmd}"
Foreground="#FF91B9EA" Grid.Column="2" Width="Auto" FontWeight="Bold" FontSize="14"/>

 

】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇基于aws api gateway的asp.net co.. 下一篇C#调用C++(QT5.5.1项目)的C++/C..

最新文章

热门文章

Hot 文章

Python

C 语言

C++基础

大数据基础

linux编程基础

C/C++面试题目