<flyctrllib:WindowBigClose x:Class="MultiLayout.MainEdit.WdGraphConfig"
        xmlns:flyctrllib="clr-namespace:FLY.ControlLibrary;assembly=FLY.ControlLibrary"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
                           xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
                           mc:Ignorable="d" 
      SizeToContent="WidthAndHeight"  >
    <Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="WdGraphConfigStyle.xaml"/>
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Window.Resources>

    <Grid TextBlock.FontSize="{StaticResource FontSize.FieldContent.Middle}" >
        <StackPanel Margin="5,20">
            <TextBlock Text="{Binding Header}" FontSize="40" HorizontalAlignment="Center" Margin="5"/>

            <StackPanel Orientation="Horizontal">
                <StackPanel Orientation="Horizontal">
                    <StackPanel Margin="{StaticResource ControlMargin}">
                        <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.MainEdit.PgMainEdit.Service}"/>
                        <ComboBox x:Name="cbServiceNames" MinWidth="100" MinHeight="40" HorizontalAlignment="Left" SelectedItem="{Binding ServiceContainerName}"/>
                    </StackPanel>
                </StackPanel>
                <GroupBox >
                    <GroupBox.Header>
                        <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.MainEdit.PgMainEdit.Location}"/>
                    </GroupBox.Header>
                    <StackPanel Orientation="Horizontal">
                        <StackPanel Margin="{StaticResource ControlMargin}">
                            <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="列" />
                            <StackPanel Orientation="Horizontal">
                                <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding X}" />
                            </StackPanel>
                        </StackPanel>
                        <TextBlock Text="x" VerticalAlignment="Center"/>
                        <StackPanel Margin="{StaticResource ControlMargin}">
                            <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="行" />
                            <StackPanel Orientation="Horizontal">
                                <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding Y}" />
                            </StackPanel>
                        </StackPanel>

                    </StackPanel>

                </GroupBox>
                <GroupBox >
                <GroupBox.Header>
                        <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.MainEdit.PgMainEdit.Size}"/>
                </GroupBox.Header>
                <StackPanel Orientation="Horizontal">
                        <StackPanel Margin="{StaticResource ControlMargin}">
                            <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.MainEdit.PgMainEdit.Width}" />
                        <StackPanel Orientation="Horizontal">
                                <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding Width}" />
                                <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="{StaticResource str.MainEdit.PgMainEdit.Col}"/>
                        </StackPanel>
                    </StackPanel>
                    <TextBlock Text="x" VerticalAlignment="Center"/>
                        <StackPanel Margin="{StaticResource ControlMargin}">
                            <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.MainEdit.PgMainEdit.Height}" />
                        <StackPanel Orientation="Horizontal">
                                <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding Height}" />
                                <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="{StaticResource str.MainEdit.PgMainEdit.Row}"/>
                        </StackPanel>
                    </StackPanel>

                </StackPanel>

            </GroupBox>
                <Button Style="{StaticResource Styles.Button.Icon}" HorizontalAlignment="Right" VerticalAlignment="Bottom" Click="button_apply_Click" Margin="{StaticResource ControlMargin}">
                    <iconPacks:PackIconMaterial Kind="CheckCircle" />
                </Button>
            </StackPanel>
        </StackPanel>
    </Grid>

    </flyctrllib:WindowBigClose>
