84 lines
4.2 KiB
XML

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Style TargetType="TextBox">
<Setter Property="Background" Value="White" />
<Setter Property="Foreground" Value="{StaticResource GrayBrush1}" />
<Setter Property="CaretBrush" Value="{StaticResource GrayBrush1}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type TextBox}">
<Border BorderBrush="{StaticResource GrayBrush1}" BorderThickness="1">
<Grid Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
<ScrollViewer x:Name="PART_ContentHost" Margin="1" />
</Grid>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="true">
<Setter Property="Background" Value="{StaticResource GrayBrush7}" />
</Trigger>
<Trigger Property="IsFocused" Value="true">
<Setter Property="Background" Value="White" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!--<Style TargetType="TextBox"
x:Key="SearchTextBox">
<Setter Property="Background"
Value="{StaticResource TextBoxBackground}" />
<Setter Property="Foreground"
Value="{StaticResource Foreground}" />
<Setter Property="CaretBrush"
Value="{StaticResource Foreground}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type TextBox}">
<Grid Background="{TemplateBinding Background}"
SnapsToDevicePixels="true">
<TextBlock Foreground="{StaticResource SearchTextForeground}"
Margin="5,0,0,0"
VerticalAlignment="Center"
Name="search"
Text="Search ..."
Visibility="Hidden" />
<ScrollViewer x:Name="PART_ContentHost"
Margin="1" />
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="TextBox.Text"
Value="">
<Setter TargetName="search"
Property="Visibility"
Value="Visible" />
</Trigger>
<Trigger Property="TextBox.Text"
Value="{x:Null}">
<Setter TargetName="search"
Property="Visibility"
Value="Visible" />
</Trigger>
<Trigger Property="IsMouseOver"
Value="true">
<Setter Property="Background"
Value="{StaticResource TextBoxBackgroundSelected}" />
<Setter TargetName="search"
Property="Foreground"
Value="{StaticResource GrayBrush6}" />
</Trigger>
<Trigger Property="IsFocused"
Value="true">
<Setter Property="Background"
Value="{StaticResource TextBoxBackgroundSelected}" />
<Setter TargetName="search"
Property="Visibility"
Value="Hidden" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>-->
</ResourceDictionary>