|
- <Window x:Class="BPASmart.RecipeManagement.MainWindow"
- 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"
- xmlns:local="clr-namespace:BPASmart.RecipeManagement"
- xmlns:view="clr-namespace:BPASmart.RecipeManagement.View"
- xmlns:vm="clr-namespace:BPASmart.RecipeManagement.ViewModel"
- mc:Ignorable="d"
- Title="MainWindow" Height="800" Width="1400" WindowStyle="None" WindowStartupLocation="CenterScreen" Background="#01003B" AllowsTransparency="True">
- <Window.DataContext>
- <vm:MainWindowViewModel/>
- </Window.DataContext>
- <Window.Resources>
- <Style x:Key="fonticon" TargetType="{x:Type TextBlock}">
- <Setter Property="FontFamily" Value="pack://application:,,,/Font/#iconfont"/>
- <Setter Property="FontSize" Value="24"/>
- <Setter Property="Foreground" Value="White"/>
- <Setter Property="HorizontalAlignment" Value="Center"/>
- <Setter Property="VerticalAlignment" Value="Center"/>
- <Setter Property="Margin" Value="0,0,20,0"/>
-
-
- </Style>
- <Style x:Key="RadioNavigation" TargetType="RadioButton">
- <Setter Property="Margin" Value="-4,0"/>
- <Setter Property="Background" Value="Transparent"/>
- <Setter Property="GroupName" Value="Navigation"/>
- <Setter Property="VerticalAlignment" Value="Center"/>
- <Setter Property="HorizontalAlignment" Value="Center"/>
- <Setter Property="Template">
- <Setter.Value>
- <ControlTemplate TargetType="RadioButton">
- <Border x:Name="_borderOver" Background="Transparent" Width="200" BorderBrush="Transparent" BorderThickness="0,1">
- <Grid Background="{TemplateBinding Background}" Margin="{TemplateBinding Margin}">
-
- <TextBlock Foreground="White" Text="{TemplateBinding Content}" FontSize="24" Background="Transparent"
- VerticalAlignment="Center" HorizontalAlignment="Center"/>
-
- </Grid>
- </Border>
- <ControlTemplate.Triggers>
- <Trigger Property="IsMouseOver" Value="True">
- <Setter Property="BorderBrush" TargetName="_borderOver" Value="#1971B6"/>
- <Setter Property="Background" TargetName="_borderOver">
- <Setter.Value>
- <LinearGradientBrush StartPoint="0,1" EndPoint="1,1">
- <GradientStop Color="#104E8B" Offset="0"/>
- <GradientStop Color="#1874CD" Offset="0.4"/>
- <GradientStop Color="#1874CD" Offset="0.6"/>
- <GradientStop Color="#27408B" Offset="1"/>
- </LinearGradientBrush>
- </Setter.Value>
- </Setter>
- </Trigger>
- <Trigger Property="IsChecked" Value="True">
-
- <Setter Property="Background" TargetName="_borderOver" >
- <Setter.Value>
- <ImageBrush ImageSource="../Image/leftImage.png"/>
- </Setter.Value>
- </Setter>
- </Trigger>
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- </Style>
- <ControlTemplate x:Key="butonTempalte" TargetType="RadioButton">
- <Border x:Name="_borderOver" Background="Transparent" Width="200" Height="60" BorderBrush="Transparent" BorderThickness="0,1">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" />
- </Border>
- <ControlTemplate.Triggers>
- <Trigger Property="IsMouseOver" Value="True">
- <Setter Property="BorderBrush" TargetName="_borderOver" Value="#1971B6"/>
- <Setter Property="Background" TargetName="_borderOver">
- <Setter.Value>
- <LinearGradientBrush StartPoint="0,1" EndPoint="1,1">
- <GradientStop Color="#104E8B" Offset="0"/>
- <GradientStop Color="#1874CD" Offset="0.4"/>
- <GradientStop Color="#1874CD" Offset="0.6"/>
- <GradientStop Color="#27408B" Offset="1"/>
- </LinearGradientBrush>
- </Setter.Value>
- </Setter>
- </Trigger>
- <Trigger Property="IsChecked" Value="True">
-
- <Setter Property="Background" TargetName="_borderOver" >
- <Setter.Value>
- <ImageBrush ImageSource="../Image/leftImage.png"/>
- </Setter.Value>
- </Setter>
- </Trigger>
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </Window.Resources>
- <Grid >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="200"/>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="2"/>
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="50"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <Border x:Name="br" Grid.ColumnSpan="3 " MouseLeftButtonDown="Border_MouseLeftButtonDown" BorderBrush="#4682B4" BorderThickness="0,0,0,1">
- <Border.Background>
- <LinearGradientBrush StartPoint="0,0" EndPoint="1,1">
- <GradientStop Color="#0C2349" Offset="0.2"/>
- <GradientStop Color="#6495ED" Offset="0.4"/>
- <GradientStop Color="#0C2349" Offset="1"/>
- </LinearGradientBrush>
- </Border.Background>
- <StackPanel Orientation="Horizontal" Margin="60,0,0,0" VerticalAlignment="Center">
- <Image Source="../image/recipe.png" Width="20" Height="20"/>
- <TextBlock Text="配方集成管理" Foreground="#E8E8E8" FontSize="30" FontFamily="楷体"
- HorizontalAlignment="Center" VerticalAlignment="Center" Margin="5,0">
- <TextBlock.Effect>
- <DropShadowEffect Direction="70" Color="Black" />
- </TextBlock.Effect>
- </TextBlock>
-
- </StackPanel>
-
- </Border>
- <Button Grid.Column="1" HorizontalAlignment="Right" VerticalAlignment="Top" Background="Transparent"
- Height="45" Width="45" Click="Button_Click" BorderBrush="Transparent" >
- <Button.Style>
- <Style TargetType="Button" >
- <Style.Setters>
- <Setter Property="Template">
- <Setter.Value>
- <ControlTemplate TargetType="Button">
- <Border x:Name="border" BorderThickness="1" Background="Transparent" Padding="0" >
- <Image x:Name="image" Source="../image/Exit.png" Stretch="UniformToFill"
- VerticalAlignment="Center" HorizontalAlignment="Center" />
- </Border>
- <ControlTemplate.Triggers>
- <Trigger Property="IsMouseOver" Value="True">
- <Setter TargetName="image" Property="Margin" Value="-3"/>
- </Trigger>
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- </Style.Setters>
-
- </Style>
- </Button.Style>
- </Button>
-
-
- <Border Grid.Row="1" Grid.RowSpan="2" BorderBrush="#1E90FF" BorderThickness="0,0,2,0">
- <Border.Background>
- <LinearGradientBrush StartPoint="0,1" EndPoint="1,1">
- <GradientStop Color="#01003B" Offset="0.2"/>
-
- <GradientStop Color="#010050" Offset="1"/>
- </LinearGradientBrush>
- </Border.Background>
- </Border>
- <StackPanel x:Name="mylistview" Background="Transparent" Grid.RowSpan="1" Grid.Row="1"
- ScrollViewer.VerticalScrollBarVisibility="Hidden" ScrollViewer.HorizontalScrollBarVisibility="Hidden"
- MouseLeftButtonDown="mylistview_MouseDown" >
- <RadioButton Style="{DynamicResource RadioNavigation}" IsChecked="True" Template="{DynamicResource butonTempalte }"
- Click="NavButton_Click" Tag="OrderManager">
- <Grid Background="Transparent" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="auto"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="" Style="{DynamicResource fonticon}"/>
- <TextBlock Grid.Column="1" Foreground="White" Text="订单管理" FontSize="24" Background="Transparent"
- VerticalAlignment="Center" HorizontalAlignment="Center" FontFamily="楷体"/>
-
- </Grid>
- </RadioButton>
- <RadioButton Style="{DynamicResource RadioNavigation}" Template="{DynamicResource butonTempalte }"
- Click="NavButton_Click" Tag="RecipeManager">
- <Grid Background="Transparent" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="auto"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="" Style="{DynamicResource fonticon}"/>
- <TextBlock Grid.Column="1" Foreground="White" Text="配方管理" FontSize="24" Background="Transparent"
- VerticalAlignment="Center" HorizontalAlignment="Center" FontFamily="楷体"/>
-
- </Grid>
- </RadioButton>
- <RadioButton Style="{DynamicResource RadioNavigation}" Template="{DynamicResource butonTempalte }"
- Click="NavButton_Click" Tag="MaterialManager">
- <Grid Background="Transparent" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="auto"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="" Style="{DynamicResource fonticon}"/>
- <TextBlock Grid.Column="1" Foreground="White" Text="原料管理" FontSize="24" Background="Transparent"
- VerticalAlignment="Center" HorizontalAlignment="Center" FontFamily="楷体"/>
-
- </Grid>
- </RadioButton>
- <!--<RadioButton Style="{DynamicResource RadioNavigation}" Template="{DynamicResource butonTempalte }"
- Click="NavButton_Click" Tag="TechnologySetting">
- <Grid Background="Transparent" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="auto"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="" Style="{DynamicResource fonticon}"/>
- <TextBlock Grid.Column="1" Foreground="White" Text="工艺参数" FontSize="24" Background="Transparent"
- VerticalAlignment="Center" HorizontalAlignment="Center" FontFamily="楷体"/>
-
- </Grid>
- </RadioButton>-->
- <RadioButton Style="{DynamicResource RadioNavigation}" Template="{DynamicResource butonTempalte }"
- Click="NavButton_Click" Tag="PowerManager">
- <Grid Background="Transparent" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="auto"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="" Style="{DynamicResource fonticon}"/>
- <TextBlock Grid.Column="1" Foreground="White" Text="权限分配" FontSize="24" Background="Transparent"
- VerticalAlignment="Center" HorizontalAlignment="Center" FontFamily="楷体"/>
-
- </Grid>
- </RadioButton>
- </StackPanel>
-
-
-
- <ContentControl x:Name="contentRegion" Grid.Column="1" Grid.Row="1" Background="#01003B" BorderBrush="Transparent">
- <view:OrderManager/>
- </ContentControl>
- </Grid>
- </Window>
|