| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398 | <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">    <!--按钮通用样式(原MiddleButton)-->    <SolidColorBrush x:Key="buttonNormal" Color="#FFDFF1FF"/>    <SolidColorBrush x:Key="buttonForground" Color="White"></SolidColorBrush>    <SolidColorBrush x:Key="buttonBorder" Color="#FF00518F"></SolidColorBrush>    <SolidColorBrush x:Key="buttonHover" Color="White"/>    <SolidColorBrush x:Key="buttonPressed" Color="#FFD8F5DE"></SolidColorBrush>    <LinearGradientBrush x:Key="Button_InnerBG" EndPoint="0.5,1" StartPoint="0.5,0">        <GradientStop Color="#FF65B4F1" Offset="0"/>        <GradientStop Color="#FF276EA5" Offset="1"/>    </LinearGradientBrush>    <LinearGradientBrush x:Key="Button_InnerBG_MouseOver" EndPoint="0.5,1" StartPoint="0.5,0">        <GradientStop Color="#FF00F37E" Offset="0"/>        <GradientStop Color="#FF008B48" Offset="1"/>    </LinearGradientBrush>    <LinearGradientBrush x:Key="Button_InnerBG_Press" EndPoint="0.5,1" StartPoint="0.5,0">        <GradientStop Color="#FF00C868" Offset="0"/>        <GradientStop Color="#FF00582E" Offset="1"/>    </LinearGradientBrush>    <SolidColorBrush x:Key="buttonNormal_Unable" Color="#FFD2D2D2"/>    <SolidColorBrush x:Key="buttonBorder_Unable" Color="#FF9D9D9D"/>    <LinearGradientBrush x:Key="Button_InnerBG_Unable" EndPoint="0.5,1" StartPoint="0.5,0">        <GradientStop Color="#FFD2D2D2" Offset="0"/>        <GradientStop Color="#FFB2B2B2" Offset="1"/>    </LinearGradientBrush>    <Style TargetType="Button">        <Setter Property="SnapsToDevicePixels" Value="True"/>        <Setter Property="Background" Value="{StaticResource buttonNormal}"></Setter>        <Setter Property="Foreground" Value="{StaticResource buttonForground}"></Setter>        <Setter Property="BorderBrush" Value="{StaticResource buttonBorder}"></Setter>        <Setter Property="BorderThickness" Value="1"/>        <Setter Property="Cursor" Value="Hand"/>        <Setter Property="Margin" Value="5"/>        <Setter Property="FontFamily" Value="Arial,SimSun" />        <Setter Property="FontSize" Value="16"/>        <Setter Property="Height" Value="40"></Setter>        <Setter Property="Width" Value="100"></Setter>        <Setter Property="VerticalAlignment" Value="Top"></Setter>        <Setter Property="Template">            <Setter.Value>                <ControlTemplate TargetType="{x:Type Button}">                    <Border x:Name="border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}"                                 SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" CornerRadius="6">                        <Grid>                            <Border x:Name="Inner_BG" Margin="2" CornerRadius="4" Background="{StaticResource Button_InnerBG}">                            </Border>                            <ContentPresenter x:Name="contentPresenter"                                               Focusable="False"                                               HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"                                               Margin="{TemplateBinding Padding}"                                               RecognizesAccessKey="True"                                               SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"                                              VerticalAlignment="{TemplateBinding VerticalContentAlignment}">                                <ContentPresenter.Effect>                                    <DropShadowEffect BlurRadius="0" ShadowDepth="1" Color="Black" Direction="135"/>                                </ContentPresenter.Effect>                            </ContentPresenter>                        </Grid>                    </Border>                    <ControlTemplate.Triggers>                        <Trigger Property="IsMouseOver" Value="true">                            <Setter Property="Background" TargetName="border" Value="{StaticResource buttonHover}"/>                            <Setter TargetName="Inner_BG" Property="Background" Value="{StaticResource Button_InnerBG_MouseOver}"/>                        </Trigger>                        <Trigger Property="IsPressed" Value="true">                            <Setter Property="Background" TargetName="border" Value="{StaticResource buttonPressed}"/>                            <Setter TargetName="Inner_BG" Property="Background" Value="{StaticResource Button_InnerBG_Press}"/>                        </Trigger>                        <Trigger Property="IsEnabled" Value="false">                            <Setter Property="Background" TargetName="border" Value="{StaticResource buttonNormal_Unable}"/>                            <Setter Property="BorderBrush" TargetName="border" Value="{StaticResource buttonBorder_Unable}"/>                            <Setter TargetName="Inner_BG" Property="Background" Value="{StaticResource Button_InnerBG_Unable}"/>                            <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>                            <Setter Property="Effect" TargetName="contentPresenter">                                <Setter.Value>                                    <DropShadowEffect BlurRadius="0" Color="Black" Direction="135" Opacity="0" ShadowDepth="1"/>                                </Setter.Value>                            </Setter>						</Trigger>                    </ControlTemplate.Triggers>                </ControlTemplate>            </Setter.Value>        </Setter>    </Style>    <!--<Style TargetType="Button">        <Setter Property="FontWeight" Value="Bold"/>        <Setter Property="Cursor" Value="Hand"/>        <Setter Property="Foreground" Value="#FF181C1F" />        <Setter Property="Background" Value="CadetBlue" />        <Setter Property="BorderBrush" Value="Blue" />        <Setter Property="Margin" Value="5"/>        <Setter Property="FontFamily" Value="Arial,SimSun" />        <Setter Property="FontSize" Value="15"/>        <Setter Property="VerticalAlignment" Value="Top" />        <Setter Property="Height" Value="40"></Setter>        <Setter Property="Width" Value="100"></Setter>        <Setter Property="BitmapEffect" >            <Setter.Value>                <BevelBitmapEffect BevelWidth="2" />            </Setter.Value>        </Setter>        <Style.Triggers>            <Trigger Property="IsMouseOver" Value="True">                <Setter Property="Foreground" Value="Green" />            </Trigger>            --><!-- When the mouse is pressed, apply a bevel with a narrower BevelWidth to make the button appear to get pressed. --><!--            <Trigger Property="IsPressed" Value="true">                <Setter Property="Background" Value="#FFEEFDFC" />                <Setter Property="BitmapEffect" >                    <Setter.Value>                        <BevelBitmapEffect BevelWidth="3" />                    </Setter.Value>                </Setter>            </Trigger>        </Style.Triggers>    </Style>-->    <!--主窗口样式-->       <!--右下角-->    <Style TargetType="Button" x:Key="NavUpButton">        <Setter Property="Height" Value="37"></Setter>        <Setter Property="Width" Value="34"></Setter>        <Setter Property="Cursor" Value="Hand"></Setter>        <Setter Property="HorizontalAlignment" Value="Left"></Setter>        <Setter Property="VerticalAlignment" Value="Top"></Setter>        <Setter Property="Template">            <Setter.Value>                <ControlTemplate TargetType="ButtonBase">                    <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}">                        <ContentPresenter Content="{TemplateBinding ContentControl.Content}" ContentStringFormat="{TemplateBinding ContentControl.ContentStringFormat}" ContentTemplate="{TemplateBinding ContentControl.ContentTemplate}" HorizontalAlignment="{TemplateBinding Control.HorizontalContentAlignment}" Margin="{TemplateBinding Control.Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding Control.VerticalContentAlignment}" />                    </Border>                </ControlTemplate>            </Setter.Value>        </Setter>        <Setter Property="Background"  >            <Setter.Value>                <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/上一个.png">                </ImageBrush>            </Setter.Value>        </Setter>        <Style.Triggers>            <Trigger Property="IsMouseOver" Value="True">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/上一个_悬停.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>            <Trigger Property="IsPressed" Value="True">                <Setter Property="Background">                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/上一个_点击.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>        </Style.Triggers>    </Style>    <Style TargetType="Button" x:Key="NavBackButton">        <Setter Property="Height" Value="37"></Setter>        <Setter Property="Width" Value="34"></Setter>        <Setter Property="Cursor" Value="Hand"></Setter>        <Setter Property="HorizontalAlignment" Value="Right"></Setter>        <Setter Property="VerticalAlignment" Value="Top"></Setter>        <Setter Property="Template">            <Setter.Value>                <ControlTemplate TargetType="ButtonBase">                    <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}">                        <ContentPresenter Content="{TemplateBinding ContentControl.Content}" ContentStringFormat="{TemplateBinding ContentControl.ContentStringFormat}" ContentTemplate="{TemplateBinding ContentControl.ContentTemplate}" HorizontalAlignment="{TemplateBinding Control.HorizontalContentAlignment}" Margin="{TemplateBinding Control.Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding Control.VerticalContentAlignment}" />                    </Border>                </ControlTemplate>            </Setter.Value>        </Setter>        <Setter Property="Background" >            <Setter.Value>                <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/下一个.png">                </ImageBrush>            </Setter.Value>        </Setter>        <Style.Triggers>            <Trigger Property="IsMouseOver" Value="True">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/下一个_悬停.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>            <Trigger Property="IsPressed" Value="true">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/下一个_点击.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>        </Style.Triggers>    </Style>    <Style TargetType="Button" x:Key="MainButton">        <Setter Property="Cursor" Value="Hand"/>        <Setter Property="Foreground" Value="#FF004294" />        <Setter Property="BorderBrush" Value="Blue" />        <Setter Property="Margin" Value="5"/>        <Setter Property="FontFamily" Value="Arial,SimSun" />        <Setter Property="FontSize" Value="22"/>        <Setter Property="Height" Value="45"></Setter>        <Setter Property="Width" Value="160"></Setter>        <Setter Property="HorizontalAlignment" Value="Right"></Setter>        <Setter Property="VerticalAlignment" Value="Top"></Setter>        <Setter Property="Template">            <Setter.Value>                <ControlTemplate TargetType="ButtonBase">                    <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}">                        <ContentPresenter Content="{TemplateBinding ContentControl.Content}" ContentStringFormat="{TemplateBinding ContentControl.ContentStringFormat}" ContentTemplate="{TemplateBinding ContentControl.ContentTemplate}" HorizontalAlignment="{TemplateBinding Control.HorizontalContentAlignment}" Margin="{TemplateBinding Control.Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding Control.VerticalContentAlignment}" />                    </Border>                </ControlTemplate>            </Setter.Value>        </Setter>        <Setter Property="Background" >            <Setter.Value>                <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/主菜单按钮.png">                </ImageBrush>            </Setter.Value>        </Setter>        <Style.Triggers>            <Trigger Property="IsMouseOver" Value="True">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/主菜单按钮_悬停.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>            <Trigger Property="IsPressed" Value="true">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/主菜单按钮_点击.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>        </Style.Triggers>    </Style>    <!--右上角-->    <Style TargetType="Button" x:Key="MainMiddleButton">        <Setter Property="FontWeight" Value="Bold"/>        <Setter Property="Cursor" Value="Hand"/>        <Setter Property="Foreground" Value="#FF004294" />        <Setter Property="BorderBrush" Value="Blue" />        <Setter Property="Margin" Value="5"/>        <Setter Property="FontFamily" Value="Arial,SimSun" />        <Setter Property="FontSize" Value="15"/>        <Setter Property="VerticalAlignment" Value="Top" />        <Setter Property="Height" Value="28"></Setter>        <Setter Property="Width" Value="83"></Setter>        <Setter Property="Background" >            <Setter.Value>                <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/事件按钮.png">                </ImageBrush>            </Setter.Value>        </Setter>        <Style.Triggers>            <Trigger Property="IsMouseOver" Value="True">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/事件按钮_悬停.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>            <Trigger Property="IsPressed" Value="true">                <Setter Property="Background" >                    <Setter.Value>                        <ImageBrush ImageSource="pack://application:,,,/MECF.Framework.Common;component/Resources/Main/事件按钮_点击.png">                        </ImageBrush>                    </Setter.Value>                </Setter>            </Trigger>        </Style.Triggers>    </Style>    <!--按钮缩放,多用于PM气流图等界面-->    <Style TargetType="Button" x:Key="SmallButton">        <Setter Property="FontWeight" Value="Bold"/>        <Setter Property="Cursor" Value="Hand"/>        <Setter Property="Foreground" Value="#FF181C1F" />        <Setter Property="Background" Value="CadetBlue" />        <Setter Property="BorderBrush" Value="Blue" />        <Setter Property="Margin" Value="5"/>        <Setter Property="FontFamily" Value="Arial,SimSun" />        <Setter Property="FontSize" Value="14"/>        <Setter Property="VerticalAlignment" Value="Top" />        <Setter Property="Height" Value="23"></Setter>        <Setter Property="Width" Value="65"></Setter>        <Setter Property="BitmapEffect" >            <Setter.Value>                <BevelBitmapEffect BevelWidth="2" />            </Setter.Value>        </Setter>        <Style.Triggers>            <Trigger Property="IsMouseOver" Value="True">                <Setter Property="Foreground" Value="Green" />            </Trigger>            <Trigger Property="IsPressed" Value="true">                <Setter Property="BitmapEffect" >                    <Setter.Value>                        <BevelBitmapEffect BevelWidth="3" />                    </Setter.Value>                </Setter>            </Trigger>        </Style.Triggers>    </Style>        <!--反应腔盖-->    <Style TargetType="Button" x:Key="ReactorMiniButtonStyle">        <Setter Property="FontSize" Value="15" />        <Setter Property="Focusable" Value="False" />        <Setter Property="Cursor" Value="Hand" />    </Style>    <!--Main Menu Button-->    <SolidColorBrush x:Key="Menu_Main_BD" Color="#FFcacaca"/>    <SolidColorBrush x:Key="Menu_Main_BG" Color="#FF0C1F6B"/>    <SolidColorBrush x:Key="Menu_Main_BG_Highlight" Color="#FF2DACCB"/>    <SolidColorBrush x:Key="Menu_Main_BG_Outer" Color="#FFCACACA"/>    <SolidColorBrush x:Key="Menu_Main_BG_Inner" Color="#FF346294"/>    <SolidColorBrush x:Key="Menu_Main_FG" Color="White"/>    <SolidColorBrush x:Key="Menu_Main_Selected_FG" Color="#FF0b1f74"/>        <!--Login Button-->    <SolidColorBrush x:Key="LoginButton_Outer_BD" Color="#FF064081"/>    <SolidColorBrush x:Key="LoginButton_Outer_BG" Color="#FFD0F5FF"/>    <SolidColorBrush x:Key="LoginButton_Inner_BD" Color="#FF0D315A"/>    <LinearGradientBrush x:Key="LoginButton_Inner_BG" EndPoint="0.5,1" StartPoint="0.5,0">        <GradientStop Color="#FF1358A3" Offset="1"/>        <GradientStop Color="#FF003C7E" Offset="0.5"/>        <GradientStop Color="#FF458DDC"/>    </LinearGradientBrush>    <SolidColorBrush x:Key="LoginButton_Inner_BD_Highlight" Color="#FF006032"/>    <LinearGradientBrush x:Key="LoginButton_Inner_BG_Highlight" EndPoint="0.5,1" StartPoint="0.5,0">        <GradientStop Color="#FF00C481" Offset="1"/>        <GradientStop Color="#FF00B46E" Offset="0.5"/>        <GradientStop Color="#FF00FF84"/>    </LinearGradientBrush>    <Style TargetType="Button" x:Key="LoginButton">        <Setter Property="Cursor" Value="Hand"/>        <Setter Property="BorderThickness" Value="1"/>        <Setter Property="Foreground" Value="{DynamicResource FG_White}"/>        <Setter Property="BorderBrush" Value="{StaticResource LoginButton_Inner_BD}"/>        <Setter Property="Background" Value="{DynamicResource LoginButton_Inner_BG}"/>        <Setter Property="Border.CornerRadius" Value="6"/>        <Setter Property="FontFamily" Value="Arial,SimSun" />        <Setter Property="FontSize" Value="18"/>        <Setter Property="VerticalAlignment" Value="Center" />        <Setter Property="Height" Value="40"></Setter>        <Setter Property="Width" Value="120"></Setter>        <Setter Property="Template">            <Setter.Value>                <ControlTemplate TargetType="ButtonBase">                    <Border BorderBrush="{DynamicResource LoginButton_Outer_BD}" BorderThickness="1" CornerRadius="8" Background="{DynamicResource LoginButton_Outer_BG}" Padding="3">                        <Border x:Name="InnerBG" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" CornerRadius="{TemplateBinding Border.CornerRadius}">                            <ContentPresenter Content="{TemplateBinding ContentControl.Content}" ContentStringFormat="{TemplateBinding ContentControl.ContentStringFormat}" ContentTemplate="{TemplateBinding ContentControl.ContentTemplate}" HorizontalAlignment="{TemplateBinding Control.HorizontalContentAlignment}" Margin="{TemplateBinding Control.Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding Control.VerticalContentAlignment}">                                <ContentPresenter.Effect>                                    <DropShadowEffect ShadowDepth="0" BlurRadius="10"/>                                </ContentPresenter.Effect>                            </ContentPresenter>                        </Border>                    </Border>                    <ControlTemplate.Triggers>                        <Trigger Property="IsMouseOver" Value="True">                            <Setter Property="BorderBrush" TargetName="InnerBG" Value="{DynamicResource LoginButton_Inner_BD_Highlight}"/>                            <Setter Property="Background" TargetName="InnerBG" Value="{DynamicResource LoginButton_Inner_BG_Highlight}"/>                        </Trigger>                        <!-- When the mouse is pressed, apply a bevel with a narrower BevelWidth to make the button appear to get pressed. -->                        <Trigger Property="IsPressed" Value="true">                            <Setter Property="BorderBrush" TargetName="InnerBG" Value="{DynamicResource LoginButton_Inner_BD_Highlight}"/>                            <Setter Property="Background" TargetName="InnerBG" Value="{DynamicResource LoginButton_Inner_BG_Highlight}"/>                        </Trigger>                    </ControlTemplate.Triggers>                </ControlTemplate>            </Setter.Value>        </Setter>    </Style></ResourceDictionary>
 |