블로그 이미지
Magic_kit
study 관련자료를 한곳으로 자기 개발 목적으로 재태크 재무 관리 목적으로 일상생활의 팁을 공유 하기 위하여 블로그를 개설 하였습니다.

calendar

1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
반응형

Category

Recent Post

Recent Comment

Archive

2009. 12. 7. 17:58 .Net Project/SilverLight 3.0
반응형
  FillBehaviorExample
- 애니메이션이 끝나면 Duration에서 설정한 시간이 되면, 어떻게 할것인지 결정하는 프로퍼티 입니다
- HoldEnd : 애니메이션이 끝나면 다른 요청이 있기 전까지 그 상태를 유지
- Stop : 애니메이션이 끝나면 애니메이션 시작한 값으로 초기화
  FillBehaviorExample.Xamls

<UserControl x:Class="AnimationExample.MainPage"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns
:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

    mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480">

    <Canvas x:Name="LayoutRoot">

        <Canvas.Resources>

 

            <!-- 사각형을 이동 시키는 스토리 보드-->

            <Storyboard x:Name="rectAnimation">

 

                <!-- Y 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    FillBehavior="Stop"

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Top)"

                        From="0" To="100"/>

 

                <!-- X 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    FillBehavior="Stop"            

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Left)"

                        From="0" To="100"/>

 

            </Storyboard>

        </Canvas.Resources>

 

        <!-- 사각형 -->

        <Rectangle x:Name="rect" Fill="Red"

                   Width="100" Height="100"

                   Canvas.Left="0" Canvas.Top="0"/>

    </Canvas>

</UserControl> 




반응형
posted by Magic_kit
2009. 12. 7. 17:52 .Net Project/SilverLight 3.0
반응형
  DurationExample
- 애니메이션 수행 시간 의미
- 값을 입력하지 않으면 디폴트 값인 "00:00:01"이 설정되어 1초 동안 애니메이션 수행 됩니다.
  DurationExample.Xamls

<UserControl x:Class="AnimationExample.MainPage"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

    mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480">

    <Canvas x:Name="LayoutRoot">

        <Canvas.Resources>

 

            <!--  사각형을 이동 시키는 스토리 보드 -->

            <Storyboard x:Name="rectAnimation">

 

                <!-- Y 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    Duration="00:00:05"

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Top)"

                        From="0" To="100"/>

 

                <!-- X 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    Duration="00:00:05"                   

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Left)"

                        From="0" To="100"/>

 

            </Storyboard>

        </Canvas.Resources>

 

        <!-- 사각형 -->

        <Rectangle x:Name="rect" Fill="Red"

                   Width="100" Height="100"

                   Canvas.Left="0" Canvas.Top="0"/>

    </Canvas>

</UserControl> 




반응형
posted by Magic_kit
2009. 12. 7. 17:48 .Net Project/SilverLight 3.0
반응형
  BeginTimeExample
- 언제 수행될 것인지 결정하기 위하여 사용한다.
- 에니메이션에 BeginTime을 명시하지 않으면 디폴트 값인 "00:00:00" 으로 설정되어 스토리보드가
  수행됨과 동시에 애니메이션 수행

  BeginTimeExample.Xamls

<UserControl x:Class="AnimationExample.MainPage"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

    mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480">

    <Canvas x:Name="LayoutRoot">

        <Canvas.Resources>

 

       !-- 사각형을 이동 시키는 스토리 보드 -->

            <Storyboard x:Name="rectAnimation">

 

                <!-- Y 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Top)"

                        From="0" To="100"/>

 

                <!-- X 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    BeginTime="00:00:01"

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Left)"

                        From="0" To="100"/>

 

            </Storyboard>

        </Canvas.Resources>

 

        <!-- 사각형 -->

        <Rectangle x:Name="rect" Fill="Red"

                   Width="100" Height="100"

                   Canvas.Left="0" Canvas.Top="0"/>

    </Canvas>

</UserControl>



반응형
posted by Magic_kit
2009. 12. 7. 17:31 .Net Project/SilverLight 3.0
반응형
  TimeLine
- TimeLine속성에는 다음과 같이 존재
- Coloranimation :  Color 타입의 프로퍼티를 변경시키기 위한 에니메이션
- DoubleAnimation : Double 타입의 프로퍼티를 변경시키기 위한 애니메이션
- PointAnimation :  Point 타입의 프로퍼티를 변경시키기 위한 애니메이션
 (AutoReverse, BeginTime, Duration,  FillBehavior,  SpeedRatio,  RepeatBehavior )
  AutoReverseExample
- AutoReverse는 수행된 애니메이션 역방향으로 다시 수행하고자 할 경우 사용 가능
- AutoReverse 다음과 같이 예제 확인

<UserControl x:Class="AnimationExample.MainPage"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
    xmlns
:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

    mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480">

    <Canvas x:Name="LayoutRoot">

        <Canvas.Resources>

 

            <!-- 사각형을 이동 시키는 스토리 보드-->

            <Storyboard x:Name="rectAnimation">

 

                <!-- Y 좌표 이동 애니메이션-->

                <DoubleAnimation

                    AutoReverse="True"

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Top)"

                        From="0" To="100"/>

 

                <!-- X 좌표 이동 애니메이션 -->

                <DoubleAnimation

                    AutoReverse="True"

                    Storyboard.TargetName="rect"

                    Storyboard.TargetProperty="(Canvas.Left)"

                        From="0" To="100"/>

 

            </Storyboard>

        </Canvas.Resources>

 

        <!-- 사각형 -->

        <Rectangle x:Name="rect" Fill="Red"

                   Width="100" Height="100"

                   Canvas.Left="0" Canvas.Top="0"/>

    </Canvas>

</UserControl> 




반응형
posted by Magic_kit