<Page x:Class="BoFilTest.UI.RunningPage"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:oxy="http://oxyplot.org/wpf"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:BoFilTest"
        mc:Ignorable="d"
        Title="Versuch läuft..." d:DesignHeight="700" d:DesignWidth="900">
    <Page.Resources>
        <Style TargetType="TextBox">
            <Setter Property="Margin" Value="2,2,2,2"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
        </Style>
        <Style TargetType="TextBlock">
            <Setter Property="Margin" Value="5,2,5,2"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
        </Style>
        <Style TargetType="Rectangle">
            <Setter Property="Width" Value="22"/>
            <Setter Property="Height" Value="4"/>
        </Style>
    </Page.Resources>
    <Grid x:Name="grid">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*"/>
            <ColumnDefinition Width="*"/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="auto"/>
        </Grid.RowDefinitions>
        <TextBlock Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="2" x:Name="stateDisplay" Text="TEST_RUNNING" FontSize="48" HorizontalAlignment="Center"/>
        <oxy:PlotView Grid.Column="0" Grid.Row="1" Grid.ColumnSpan="2" Model="{Binding PlotModel}" MinWidth="800" MinHeight="400" Margin="10"/>

        <Grid Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="2" Margin="0,0,0,20">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="22"/>
                <ColumnDefinition Width="300"/>
                <ColumnDefinition Width="22"/>
                <ColumnDefinition Width="300"/>
                <ColumnDefinition Width="22"/>
                <ColumnDefinition Width="300"/>
                <ColumnDefinition Width="22"/>
                <ColumnDefinition Width="300"/>
                <ColumnDefinition Width="*"/>
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition Height="auto"/>
                <RowDefinition Height="30"/> <!-- For spacing only -->
            </Grid.RowDefinitions>
            <Rectangle Grid.Column="1" Fill="{Binding WeightBrush}"/>
            <TextBlock Grid.Column="2" Grid.Row="0" x:Name="currentWeight" HorizontalAlignment="Left" FontSize="28"/>
            <Rectangle Grid.Column="3" Fill="{Binding PressureBrush}"/>
            <TextBlock Grid.Column="4" Grid.Row="0" x:Name="currentPressure" HorizontalAlignment="Left" FontSize="28"/>
            <Rectangle Grid.Column="5" Fill="{Binding FlowBrush}"/>
            <TextBlock Grid.Column="6" Grid.Row="0" x:Name="currentGasFlow" HorizontalAlignment="Left" FontSize="28"/>
            <Rectangle Grid.Column="7" Fill="{Binding ExtraBrush}" Visibility="{Binding ExtraEnabled}"/>
            <TextBlock Grid.Column="8" Grid.Row="0" x:Name="currentExtra" Visibility="{Binding ExtraEnabled}" HorizontalAlignment="Left" FontSize="28"/>
        </Grid>

        <Grid x:Name="processStatus" Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="3" MinHeight="20" HorizontalAlignment="Center">
            <Grid.RowDefinitions>
                <RowDefinition Height="auto"/>
            </Grid.RowDefinitions>
        </Grid>
        <TextBlock Grid.Column="0" Grid.Row="4" Text="PROCESS_STEP" HorizontalAlignment="Right" FontSize="24"/>
        <TextBlock x:Name="stepDescription" Grid.Column="1" Grid.Row="4" Text="" HorizontalAlignment="Left" FontSize="24" Margin="10,0,0,0"/>
        <TextBlock Grid.Column="0" Grid.Row="5" Text="RECORDING_STATE" HorizontalAlignment="Right" FontSize="16"/>
        <TextBlock x:Name="recordState" Grid.Column="1" Grid.Row="5" Text="deaktiviert" HorizontalAlignment="Left" FontSize="16" Margin="10,0,0,0"/>
        <TextBlock x:Name="timeDisplay" Grid.Column="0" Grid.Row="6" Grid.ColumnSpan="2" Text="00:00.0" HorizontalAlignment="Center" FontSize="48"/>
    </Grid>
</Page>
