<TextBlock Text="XAML" FontSize="150pt" FontFamily="Arial Black"

  HorizontalAlignment="Center" VerticalAlignment="Center" RenderTransformOrigin=".5,.5">

<TextBlock.RenderTransform> <!--프로퍼티엘리먼트(속성) -데이터를 한개만 가질 있음-->

<TransformGroup> <!--동시에 두개이상의 변형을 주려할때 사용-->

<RotateTransform x:Name="xformRotate"/> <!--Transform객체에도 이름지정 가능-->

<ScaleTransform x:Name="xformScale"/>

</TransformGroup>

</TextBlock.RenderTransform>

 

<TextBlock.Triggers>

<EventTrigger RoutedEvent="TextBlock.MouseDown">

<BeginStoryboard>

<Storyboard>

<DoubleAnimation

Storyboard.TargetName="xformRotate"

Storyboard.TargetProperty="Angle"

From="0" To="360"

Duration="0:0:5"

RepeatBehavior="Forever"/>

 

<DoubleAnimation

Storyboard.TargetName="xformScale"

Storyboard.TargetProperty="ScaleX"

From="-1" To="1"

Duration="0:0:3"

RepeatBehavior="Forever"

AutoReverse="True"/>

</Storyboard>

</BeginStoryboard>

</EventTrigger>

</TextBlock.Triggers>

</TextBlock>




by 피요히코~ 2009. 2. 25. 13:06