<Canvas xmlns="http://schemas.microsoft.com/client/2007"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Width="640" Height="200">

	<Canvas.Triggers>
		<EventTrigger RoutedEvent="Canvas.Loaded">
			<BeginStoryboard>
				<Storyboard>
					<DoubleAnimationUsingKeyFrames Storyboard.TargetName="rect" Storyboard.TargetProperty="(Canvas.Left)">
						<LinearDoubleKeyFrame Value="500" KeyTime="00:00:05" />
					</DoubleAnimationUsingKeyFrames>					
				</Storyboard>
			</BeginStoryboard>
			<BeginStoryboard>
				<Storyboard>
					<ColorAnimationUsingKeyFrames Storyboard.TargetName="rectFill" Storyboard.TargetProperty="(Color)">
						<DiscreteColorKeyFrame Value="Red" KeyTime="00:00:00" />
						<DiscreteColorKeyFrame Value="Black" KeyTime="00:00:02.5" />
						<DiscreteColorKeyFrame Value="Red" KeyTime="00:00:05" />
					</ColorAnimationUsingKeyFrames>					
				</Storyboard>
			</BeginStoryboard>
		</EventTrigger>
	</Canvas.Triggers>

		<Rectangle x:Name="measure1" Canvas.Left="10" Canvas.Top="7" Width="590" Height="3" Fill="Black" />
		<Rectangle x:Name="measure2" Canvas.Left="10" Canvas.Top="110" Width="590" Height="3" Fill="Black" />
		<Rectangle x:Name="rect" Canvas.Left="10" Canvas.Top="10" Width="100" Height="100">
			<Rectangle.Fill>
				<SolidColorBrush x:Name="rectFill" Color="Red" />
			</Rectangle.Fill>
		</Rectangle>

	<TextBlock x:Name="description" Canvas.Left="20" Canvas.Top="140" Width="600" Height="50">
		<Run Text="The red block should take 5 seconds to move to the right,"/>
		<LineBreak/>
		<Run Text="when it's halfway across it should turn black,"/>
		<LineBreak/>
		<Run Text="and when it reaches the right side it will turn red again."/>
	</TextBlock>
</Canvas>
