<Page
	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:System="clr-namespace:System;assembly=mscorlib"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
    xmlns:local="clr-namespace:ForzaUI"
    xmlns:ed="http://schemas.microsoft.com/expression/2010/drawing"
    mc:Ignorable="d"
	x:Class="DigitalGauge.FOR_F450DRW_20"
	 >

    <Page.Resources>
        <Style x:Key="TextBlockStyle" TargetType="{x:Type local:FastTextBlock}">
            <Setter Property="FontFamily" Value="Moire"/>
            <Setter Property="Foreground" Value="White"/>
             
            <Setter Property="TextAlignment" Value="Right"/>
        </Style>

        <local:DigitalGaugeConfig x:Key="Config" HasClock="True" HasExternalTemp="True" UseDegreesF="False" UseMPH="True" UsePsi="True" MaxBoost="40" MinBoost="1" MaxSpeed="100" HasAbsLight="False" HasStmLight="False" HasTcsLight="False" HasGAccelX="False" HasGAccelY="False"  HasShiftLights="False" HasTextTach="False" HasLapPlaceInfo="False" HasTextBoost="False" HasTextGAccel="False" HasTextOdometer="True" HasTextFuel="False" MaxFuel="20" MinGear="-1" MaxGear="1" MaxRpm="5000"/>

        <Storyboard x:Key="Gear Analog">
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_FOR_F250Deberti_19_GearN_png">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.5" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Hidden}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_FOR_F250Deberti_19_GearD_png">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Visible}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_FOR_F250Deberti_19_GearR_png">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.5" Value="{x:Static Visibility.Hidden}"/>
            </ObjectAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Start Up Animation">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Start_Up_Mask">
                <EasingDoubleKeyFrame KeyTime="0" Value="1"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Fuel Gauge">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="Textures_FOR_F250Deberti_19_Fuel_Fill_png">
                <EasingDoubleKeyFrame KeyTime="0" Value="-123.56"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="-58.735"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Boost Gauge">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="Textures_FOR_F250Deberti_19_Boost_Fill_png">
                <EasingDoubleKeyFrame KeyTime="0" Value="-123.56"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="-58.846"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
    </Page.Resources>
    <Page.Triggers>
        <EventTrigger RoutedEvent="FrameworkElement.Loaded">
            <BeginStoryboard Storyboard="{StaticResource Fuel Gauge}"/>
            <BeginStoryboard x:Name="Boost_Gauge_BeginStoryboard" Storyboard="{StaticResource Boost Gauge}"/>
        </EventTrigger>
    </Page.Triggers>


    <Canvas x:Name="LayoutRoot" Background="Transparent" Width="1280" Height="720">
        <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="NightDaySplit">
                <VisualState x:Name="Day"/>
                <VisualState x:Name="Night"/>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>
        <Rectangle x:Name="BlackBG" Fill="Black" Height="720.5" Stroke="Black" Width="1281.049"/>
        <Rectangle x:Name="GrayBG" Fill="#FF292929" Height="105" Width="413" Canvas.Top="165.75" Canvas.Left="413.45" RenderTransformOrigin="0.5,0.5">
            <Rectangle.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.7" ScaleX="0.7"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </Rectangle.RenderTransform>
        </Rectangle>
        <Image x:Name="Textures_FOR_F250Deberti_19_Fuel_Fill_png" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19_gaugeFill.png" Stretch="Fill" RenderTransformOrigin="0.015,1.012" Canvas.Top="183.275" Canvas.Left="399.881" Width="127.033" Height="117.875">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.7" ScaleX="0.7"/>
                    <SkewTransform/>
                    <RotateTransform Angle="-123.56"/>
                    <TranslateTransform X="139.019" Y="-15.594"/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Image x:Name="Textures_FOR_F250Deberti_19_Boost_Fill_png" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19_gaugeFill.png" Stretch="Fill" RenderTransformOrigin="0.015,1.012" Canvas.Top="183.275" Canvas.Left="557.881" Width="127.033" Height="117.875">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.7" ScaleX="0.7"/>
                    <SkewTransform/>
                    <RotateTransform Angle="-123.56"/>
                    <TranslateTransform X="139.019" Y="-15.594"/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Image x:Name="Textures_FOR_F250Deberti_19_Center_png" Height="498.572" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19_Center.png" Stretch="Fill" Width="851.73" RenderTransformOrigin="0.5,0.5" Canvas.Top="110.714" Canvas.Left="667.24">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.7" ScaleX="0.7"/>
                    <SkewTransform/>
                    <RotateTransform Angle="-90"/>
                    <TranslateTransform/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Image x:Name="Textures_FOR_F250Deberti_19_png" Height="720" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19.png" Stretch="Fill" Width="1280" Canvas.Left="-180" RenderTransformOrigin="0.5,0.5">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.7" ScaleX="0.7"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Canvas x:Name="Gear" Height="37" Width="95" Canvas.Top="511.95" Canvas.Left="394.65" RenderTransformOrigin="0.5,0.5">
            <Canvas.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.7" ScaleX="0.7"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </Canvas.RenderTransform>
            <Image x:Name="Textures_FOR_F250Deberti_19_GearR_png" Height="37" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19_GearR.png" Stretch="Fill" Width="32"/>
            <Image x:Name="Textures_FOR_F250Deberti_19_GearN_png" Height="37" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19_GearN.png" Stretch="Fill" Width="32" Canvas.Left="31"/>
            <Image x:Name="Textures_FOR_F250Deberti_19_GearD_png" Height="37" Source="game:/media/cars/FOR_F250Deberti_19/UI/Textures/FOR_F250Deberti_19_GearD.png" Stretch="Fill" Width="32" Canvas.Left="63"/>
        </Canvas>
        <local:FastTextBlock x:Name="Text_Speed" Height="80"   Width="190" FontFamily="DG1_ArialBold" FontSize="72" Foreground="White" TextAlignment="Center" RenderTransformOrigin="0.5,0.5" Canvas.Top="337.5" Canvas.Left="354.5" Text="{Binding Speed}">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.84" ScaleX="0.84"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Clock" Text="{Binding Time}" Height="20"   Width="55" FontFamily="DG1_ArialBold" FontSize="18" TextAlignment="Right" Canvas.Left="914.334" RenderTransformOrigin="0.5,0.5" Canvas.Top="383.334" Foreground="Black">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform/>
                    <SkewTransform/>
                    <RotateTransform Angle="-90"/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_External_Temp" Text="{Binding ExternalTemp}" Height="20"   Width="55" FontFamily="DG1_ArialBold" FontSize="18" Canvas.Left="914.334" RenderTransformOrigin="0.5,0.5" Canvas.Top="316.666" Foreground="Black">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform/>
                    <SkewTransform/>
                    <RotateTransform Angle="-90"/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Odometer" Height="38.73"   Width="190" FontFamily="DG1_ArialBold" FontSize="24" Foreground="White" TextAlignment="Right" RenderTransformOrigin="0.5,0.5" Canvas.Top="514.801" Canvas.Left="150.501" Text="{Binding Odometer}">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.84" ScaleX="0.84"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <Rectangle x:Name="Start_Up_Mask" Fill="Black" Height="720" Stroke="Black" Width="1280" Canvas.Left="0" Canvas.Top="0" Opacity="0"/>

        <!-- Storyboard binding controllers -->
        <local:StoryboardController SeekPct="{Binding Fuel}" Target="{StaticResource Fuel Gauge}"/>
        <local:StoryboardController SeekPct="{Binding BoostAnim}" Target="{StaticResource Boost Gauge}"/>
        <local:StoryboardController SeekPct="{Binding AnalogGear}" Target="{StaticResource Gear Analog}"/>
    </Canvas>
</Page>