You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
458 lines
31 KiB
Plaintext
458 lines
31 KiB
Plaintext
1 year ago
|
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||
|
<ResourceDictionary.MergedDictionaries>
|
||
|
<ResourceDictionary Source="pack://application:,,,/Philisense.Congress;component/Resources/Styles/Button.xaml"></ResourceDictionary>
|
||
|
<ResourceDictionary Source="pack://application:,,,/Philisense.Congress;component/Resources/Styles/Label.xaml"></ResourceDictionary>
|
||
|
</ResourceDictionary.MergedDictionaries>
|
||
|
<!--按钮-->
|
||
|
<Style x:Key="InputGroupButtonBaseStyle" BasedOn="{StaticResource ButtonBaseBaseStyle}" TargetType="{x:Type Button}">
|
||
|
<Setter Property="Background">
|
||
|
<Setter.Value>
|
||
|
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
|
||
|
<GradientStop Offset="0" Color="#fff"></GradientStop>
|
||
|
<GradientStop Offset="1" Color="#E0E0E0"></GradientStop>
|
||
|
</LinearGradientBrush>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
<Setter Property="BorderBrush" Value="{DynamicResource BorderBrush-Default1}"/>
|
||
|
<Setter Property="Foreground" Value="{DynamicResource Foreground-Default}"/>
|
||
|
</Style>
|
||
|
<Style x:Key="InputGroupButtonLeftStyle" BasedOn="{StaticResource InputGroupButtonBaseStyle}" TargetType="{x:Type Button}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Button}">
|
||
|
<Grid>
|
||
|
<Border x:Name="border" CornerRadius="4,0,0,4" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="0" SnapsToDevicePixels="true">
|
||
|
<Border.Effect>
|
||
|
<DropShadowEffect x:Name="dse" BlurRadius="8" ShadowDepth="0" Color="#9966afe9" Opacity="0"/>
|
||
|
</Border.Effect>
|
||
|
<!--点击时显示-->
|
||
|
<Grid x:Name="PressedLayer" Visibility="Collapsed">
|
||
|
<Rectangle Height="3" VerticalAlignment="Top" Fill="#1F000000" RadiusX="4" RadiusY="4">
|
||
|
<Rectangle.Effect>
|
||
|
<BlurEffect Radius="5"></BlurEffect>
|
||
|
</Rectangle.Effect>
|
||
|
</Rectangle>
|
||
|
<Border CornerRadius="4" BorderBrush="#1F000000" BorderThickness="1,0">
|
||
|
<Border.Effect>
|
||
|
<BlurEffect Radius="3"></BlurEffect>
|
||
|
</Border.Effect>
|
||
|
</Border>
|
||
|
</Grid>
|
||
|
</Border>
|
||
|
<Border BorderThickness="{TemplateBinding BorderThickness}">
|
||
|
<ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Border>
|
||
|
<!--禁用时显示-->
|
||
|
<Rectangle x:Name="EnabledLayer" Fill="#4CFFFFFF" RadiusX="4" RadiusY="4" Visibility="Collapsed"/>
|
||
|
</Grid>
|
||
|
<ControlTemplate.Triggers>
|
||
|
<Trigger Property="IsMouseOver" Value="True">
|
||
|
<Setter Property="Background" Value="#e6e6e6"/>
|
||
|
<Setter Property="BorderBrush" Value="#adadad"/>
|
||
|
</Trigger>
|
||
|
<Trigger Property="IsPressed" Value="true">
|
||
|
<Setter Property="Panel.ZIndex" Value="1"/>
|
||
|
<Setter TargetName="PressedLayer" Property="Visibility" Value="Visible"/>
|
||
|
<Setter TargetName="border" Property="BorderBrush" Value="#66afe9"/>
|
||
|
<Trigger.EnterActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="1" Duration="0:0:0">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.EnterActions>
|
||
|
<Trigger.ExitActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="0" Duration="0:0:0">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.ExitActions>
|
||
|
</Trigger>
|
||
|
<Trigger Property="IsEnabled" Value="false">
|
||
|
<Setter TargetName="EnabledLayer" Property="Visibility" Value="Visible"/>
|
||
|
</Trigger>
|
||
|
</ControlTemplate.Triggers>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<Style x:Key="InputGroupButtonRightStyle" BasedOn="{StaticResource InputGroupButtonBaseStyle}" TargetType="{x:Type Button}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Button}">
|
||
|
<Grid>
|
||
|
<Border x:Name="border" CornerRadius="0,4,4,0" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="0" SnapsToDevicePixels="true">
|
||
|
<Border.Effect>
|
||
|
<DropShadowEffect x:Name="dse" BlurRadius="8" ShadowDepth="0" Color="#9966afe9" Opacity="0"/>
|
||
|
</Border.Effect>
|
||
|
<!--点击时显示-->
|
||
|
<Grid x:Name="PressedLayer" Visibility="Collapsed">
|
||
|
<Rectangle Height="3" VerticalAlignment="Top" Fill="#1F000000" RadiusX="4" RadiusY="4">
|
||
|
<Rectangle.Effect>
|
||
|
<BlurEffect Radius="5"></BlurEffect>
|
||
|
</Rectangle.Effect>
|
||
|
</Rectangle>
|
||
|
<Border CornerRadius="4" BorderBrush="#1F000000" BorderThickness="1,0">
|
||
|
<Border.Effect>
|
||
|
<BlurEffect Radius="3"></BlurEffect>
|
||
|
</Border.Effect>
|
||
|
</Border>
|
||
|
</Grid>
|
||
|
</Border>
|
||
|
<Border BorderThickness="{TemplateBinding BorderThickness}">
|
||
|
<ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Border>
|
||
|
<!--禁用时显示-->
|
||
|
<Rectangle x:Name="EnabledLayer" Fill="#4CFFFFFF" RadiusX="4" RadiusY="4" Visibility="Collapsed"/>
|
||
|
</Grid>
|
||
|
<ControlTemplate.Triggers>
|
||
|
<Trigger Property="IsMouseOver" Value="True">
|
||
|
<Setter Property="Background" Value="#e6e6e6"/>
|
||
|
<Setter Property="BorderBrush" Value="#adadad"/>
|
||
|
</Trigger>
|
||
|
<Trigger Property="IsPressed" Value="true">
|
||
|
<Setter Property="Panel.ZIndex" Value="1"/>
|
||
|
<Setter TargetName="PressedLayer" Property="Visibility" Value="Visible"/>
|
||
|
<Setter TargetName="border" Property="BorderBrush" Value="#66afe9"/>
|
||
|
<Trigger.EnterActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="1" Duration="0:0:0">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.EnterActions>
|
||
|
<Trigger.ExitActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="0" Duration="0:0:0">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.ExitActions>
|
||
|
</Trigger>
|
||
|
<Trigger Property="IsEnabled" Value="false">
|
||
|
<Setter TargetName="EnabledLayer" Property="Visibility" Value="Visible"/>
|
||
|
</Trigger>
|
||
|
</ControlTemplate.Triggers>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<!--按钮里的路径-->
|
||
|
<Style x:Key="InputGroupPathStyle" BasedOn="{x:Null}" TargetType="{x:Type Path}">
|
||
|
<Setter Property="Width" Value="20"/>
|
||
|
<Setter Property="Height" Value="20"/>
|
||
|
<Setter Property="Fill" Value="#777"/>
|
||
|
<Setter Property="Stretch" Value="Fill"/>
|
||
|
</Style>
|
||
|
<!--输入组 按钮-->
|
||
|
<Style x:Key="InputGroupBtnBaseStyle" BasedOn="{StaticResource BaseStyle}" TargetType="{x:Type Control}">
|
||
|
<Setter Property="Height" Value="{DynamicResource DefaultControlHeight}"/>
|
||
|
<Setter Property="Padding" Value="{DynamicResource DefaultControlPadding}"/>
|
||
|
<Setter Property="Background" Value="{DynamicResource FormControlBackground}"/>
|
||
|
<Setter Property="BorderBrush" Value="{DynamicResource FormControlBorderBrush}"/>
|
||
|
<Setter Property="Foreground" Value="{DynamicResource FormControlForeground}"/>
|
||
|
<Setter Property="BorderThickness" Value="1"/>
|
||
|
<Setter Property="HorizontalContentAlignment" Value="Left"/>
|
||
|
<Setter Property="VerticalContentAlignment" Value="Center"/>
|
||
|
<Style.Triggers>
|
||
|
<Trigger Property="IsEnabled" Value="False">
|
||
|
<Setter Property="Background" Value="#eee"/>
|
||
|
<Setter Property="Cursor" Value="No"/>
|
||
|
</Trigger>
|
||
|
</Style.Triggers>
|
||
|
</Style>
|
||
|
<Style x:Key="input-group-btn left" BasedOn="{StaticResource InputGroupBtnBaseStyle}" TargetType="{x:Type Control}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Control}">
|
||
|
<Grid>
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||
|
<ColumnDefinition></ColumnDefinition>
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<Button Grid.Column="0" Content="{TemplateBinding Tag}" Style="{DynamicResource InputGroupButtonLeftStyle}"></Button>
|
||
|
<Border Grid.Column="1" x:Name="border" CornerRadius="0,4,4,0" Margin="-1,0,0,0" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
||
|
<Border.Effect>
|
||
|
<DropShadowEffect x:Name="dse" BlurRadius="8" ShadowDepth="0" Color="#9966afe9" Opacity="0"/>
|
||
|
</Border.Effect>
|
||
|
<Rectangle Height="1" VerticalAlignment="Top" Stroke="#000000" Opacity="0.1">
|
||
|
<Rectangle.Effect>
|
||
|
<BlurEffect Radius="1"/>
|
||
|
</Rectangle.Effect>
|
||
|
</Rectangle>
|
||
|
</Border>
|
||
|
<!--内容放在外面 因为阴影会对内容产生影响 Margin绑定BorderThickness是为了让padding没有误差-->
|
||
|
<ScrollViewer Grid.Column="1" x:Name="PART_ContentHost" Margin="-1,0,0,0" Padding="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Grid>
|
||
|
<ControlTemplate.Triggers>
|
||
|
<Trigger Property="IsFocused" Value="True">
|
||
|
<Setter Property="BorderBrush" Value="#66afe9"/>
|
||
|
<Trigger.EnterActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="1" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.EnterActions>
|
||
|
<Trigger.ExitActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="0" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.ExitActions>
|
||
|
</Trigger>
|
||
|
</ControlTemplate.Triggers>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<Style x:Key="input-group-btn right" BasedOn="{StaticResource InputGroupBtnBaseStyle}" TargetType="{x:Type Control}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Control}">
|
||
|
<Grid>
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition></ColumnDefinition>
|
||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<Button Grid.Column="1" Content="{TemplateBinding Tag}" Style="{DynamicResource InputGroupButtonRightStyle}" Margin="-1,0,0,0"></Button>
|
||
|
<Border Grid.Column="0" x:Name="border" CornerRadius="4,0,0,4" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
||
|
<Border.Effect>
|
||
|
<DropShadowEffect x:Name="dse" BlurRadius="8" ShadowDepth="0" Color="#9966afe9" Opacity="0"/>
|
||
|
</Border.Effect>
|
||
|
<Rectangle Height="1" VerticalAlignment="Top" Stroke="#000000" Opacity="0.1">
|
||
|
<Rectangle.Effect>
|
||
|
<BlurEffect Radius="1"/>
|
||
|
</Rectangle.Effect>
|
||
|
</Rectangle>
|
||
|
</Border>
|
||
|
<!--内容放在外面 因为阴影会对内容产生影响 Margin绑定BorderThickness是为了让padding没有误差-->
|
||
|
<ScrollViewer Grid.Column="0" x:Name="PART_ContentHost" Margin="0" Padding="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Grid>
|
||
|
<ControlTemplate.Triggers>
|
||
|
<Trigger Property="IsFocused" Value="True">
|
||
|
<Setter Property="BorderBrush" Value="#66afe9"/>
|
||
|
<Trigger.EnterActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="1" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.EnterActions>
|
||
|
<Trigger.ExitActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="0" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.ExitActions>
|
||
|
</Trigger>
|
||
|
</ControlTemplate.Triggers>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
|
||
|
<!--标签-->
|
||
|
<Style x:Key="InputGroupLabelBaseStyle" BasedOn="{StaticResource LabelBaseStyle}" TargetType="{x:Type Label}">
|
||
|
<Setter Property="Background" Value="#eee"/>
|
||
|
<Setter Property="BorderBrush" Value="{DynamicResource FormControlBorderBrush}"/>
|
||
|
<Setter Property="Foreground" Value="{DynamicResource FormControlForeground}"/>
|
||
|
<Setter Property="BorderThickness" Value="1"/>
|
||
|
<Setter Property="HorizontalAlignment" Value="Stretch"/>
|
||
|
<Setter Property="VerticalAlignment" Value="Stretch"/>
|
||
|
<Setter Property="VerticalContentAlignment" Value="Center"/>
|
||
|
<Setter Property="Padding" Value="{DynamicResource DefaultControlPadding}"/>
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Label}">
|
||
|
<Border CornerRadius="4,0,0,4" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="True">
|
||
|
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" ContentStringFormat="{TemplateBinding ContentStringFormat}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Border>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<Style x:Key="InputGroupLabelLeftStyle" BasedOn="{StaticResource InputGroupLabelBaseStyle}" TargetType="{x:Type Label}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Label}">
|
||
|
<Border CornerRadius="4,0,0,4" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="True">
|
||
|
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" ContentStringFormat="{TemplateBinding ContentStringFormat}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Border>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<Style x:Key="InputGroupLabelRightStyle" BasedOn="{StaticResource InputGroupLabelBaseStyle}" TargetType="{x:Type Label}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Label}">
|
||
|
<Border CornerRadius="0,4,4,0" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="True">
|
||
|
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" ContentStringFormat="{TemplateBinding ContentStringFormat}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Border>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<!--输入组 插件-->
|
||
|
<Style x:Key="InputGroupAddonBaseStyle" BasedOn="{StaticResource BaseStyle}" TargetType="{x:Type Control}">
|
||
|
<Setter Property="Height" Value="{DynamicResource DefaultControlHeight}"/>
|
||
|
<Setter Property="Padding" Value="{DynamicResource DefaultControlPadding}"/>
|
||
|
<Setter Property="Background" Value="{DynamicResource FormControlBackground}"/>
|
||
|
<Setter Property="BorderBrush" Value="{DynamicResource FormControlBorderBrush}"/>
|
||
|
<Setter Property="Foreground" Value="{DynamicResource FormControlForeground}"/>
|
||
|
<Setter Property="BorderThickness" Value="1"/>
|
||
|
<Setter Property="HorizontalContentAlignment" Value="Left"/>
|
||
|
<Setter Property="VerticalContentAlignment" Value="Center"/>
|
||
|
<Style.Triggers>
|
||
|
<Trigger Property="IsEnabled" Value="False">
|
||
|
<Setter Property="Background" Value="#eee"/>
|
||
|
<Setter Property="Cursor" Value="No"/>
|
||
|
</Trigger>
|
||
|
</Style.Triggers>
|
||
|
</Style>
|
||
|
<Style x:Key="input-group-addon left" BasedOn="{StaticResource InputGroupAddonBaseStyle}" TargetType="{x:Type Control}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Control}">
|
||
|
<Grid>
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||
|
<ColumnDefinition></ColumnDefinition>
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<Label Grid.Column="0" Content="{TemplateBinding Tag}" Style="{DynamicResource InputGroupLabelLeftStyle}"></Label>
|
||
|
<Border Grid.Column="1" x:Name="border" CornerRadius="0,4,4,0" Margin="-1,0,0,0" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
||
|
<Border.Effect>
|
||
|
<DropShadowEffect x:Name="dse" BlurRadius="8" ShadowDepth="0" Color="#9966afe9" Opacity="0"/>
|
||
|
</Border.Effect>
|
||
|
<Rectangle Height="1" VerticalAlignment="Top" Stroke="#000000" Opacity="0.1">
|
||
|
<Rectangle.Effect>
|
||
|
<BlurEffect Radius="1"/>
|
||
|
</Rectangle.Effect>
|
||
|
</Rectangle>
|
||
|
</Border>
|
||
|
<!--内容放在外面 因为阴影会对内容产生影响 Margin绑定BorderThickness是为了让padding没有误差-->
|
||
|
<ScrollViewer Grid.Column="1" x:Name="PART_ContentHost" Margin="-1,0,0,0" Padding="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Grid>
|
||
|
<ControlTemplate.Triggers>
|
||
|
<Trigger Property="IsFocused" Value="True">
|
||
|
<Setter Property="BorderBrush" Value="#66afe9"/>
|
||
|
<Trigger.EnterActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="1" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.EnterActions>
|
||
|
<Trigger.ExitActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="0" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.ExitActions>
|
||
|
</Trigger>
|
||
|
</ControlTemplate.Triggers>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
<Style x:Key="input-group-addon right" BasedOn="{StaticResource InputGroupAddonBaseStyle}" TargetType="{x:Type Control}">
|
||
|
<Setter Property="Template">
|
||
|
<Setter.Value>
|
||
|
<ControlTemplate TargetType="{x:Type Control}">
|
||
|
<Grid>
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition></ColumnDefinition>
|
||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<Label Grid.Column="1" Content="{TemplateBinding Tag}" Style="{DynamicResource InputGroupLabelRightStyle}" Margin="-1,0,0,0"></Label>
|
||
|
<Border Grid.Column="0" x:Name="border" CornerRadius="4,0,0,4" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
||
|
<Border.Effect>
|
||
|
<DropShadowEffect x:Name="dse" BlurRadius="8" ShadowDepth="0" Color="#9966afe9" Opacity="0"/>
|
||
|
</Border.Effect>
|
||
|
<Rectangle Height="0" VerticalAlignment="Top" Stroke="#000000" Opacity="0.1">
|
||
|
<Rectangle.Effect>
|
||
|
<BlurEffect Radius="1"/>
|
||
|
</Rectangle.Effect>
|
||
|
</Rectangle>
|
||
|
</Border>
|
||
|
<!--内容放在外面 因为阴影会对内容产生影响 Margin绑定BorderThickness是为了让padding没有误差-->
|
||
|
<ScrollViewer Grid.Column="0" x:Name="PART_ContentHost" Margin="0" Padding="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||
|
</Grid>
|
||
|
<ControlTemplate.Triggers>
|
||
|
<Trigger Property="IsFocused" Value="True">
|
||
|
<Setter Property="BorderBrush" Value="#66afe9"/>
|
||
|
<Trigger.EnterActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="1" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.EnterActions>
|
||
|
<Trigger.ExitActions>
|
||
|
<BeginStoryboard>
|
||
|
<Storyboard>
|
||
|
<DoubleAnimation Storyboard.TargetName="dse" Storyboard.TargetProperty="Opacity" To="0" Duration="0:0:0.15">
|
||
|
<DoubleAnimation.EasingFunction>
|
||
|
<BackEase EasingMode="EaseInOut" />
|
||
|
</DoubleAnimation.EasingFunction>
|
||
|
</DoubleAnimation>
|
||
|
</Storyboard>
|
||
|
</BeginStoryboard>
|
||
|
</Trigger.ExitActions>
|
||
|
</Trigger>
|
||
|
</ControlTemplate.Triggers>
|
||
|
</ControlTemplate>
|
||
|
</Setter.Value>
|
||
|
</Setter>
|
||
|
</Style>
|
||
|
</ResourceDictionary>
|