diff options
-rw-r--r-- | win/CS/HandBrakeWPF/Themes/Controls/ComboBoxDark.xaml | 10 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Themes/Dark.xaml | 39 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Views/Styles/Styles.xaml | 7 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Views/VideoView.xaml | 15 |
4 files changed, 51 insertions, 20 deletions
diff --git a/win/CS/HandBrakeWPF/Themes/Controls/ComboBoxDark.xaml b/win/CS/HandBrakeWPF/Themes/Controls/ComboBoxDark.xaml index 5e3431a77..2f137f41d 100644 --- a/win/CS/HandBrakeWPF/Themes/Controls/ComboBoxDark.xaml +++ b/win/CS/HandBrakeWPF/Themes/Controls/ComboBoxDark.xaml @@ -144,6 +144,7 @@ </Setter.Value> </Setter> </Style> + <ControlTemplate x:Key="ComboBoxTemplate" TargetType="{x:Type ComboBox}"> <Grid x:Name="templateRoot" SnapsToDevicePixels="true"> <Grid.ColumnDefinitions> @@ -240,7 +241,9 @@ </Trigger> </ControlTemplate.Triggers> </ControlTemplate> + <SolidColorBrush x:Key="TextBox.Static.Background" Color="#FFFFFFFF" /> + <ControlTemplate x:Key="ComboBoxEditableTemplate" TargetType="{x:Type ComboBox}"> <Grid x:Name="templateRoot" SnapsToDevicePixels="true"> <Grid.ColumnDefinitions> @@ -343,6 +346,7 @@ </Trigger> </ControlTemplate.Triggers> </ControlTemplate> + <Style x:Key="ComboBoxBaseStyle" TargetType="ComboBox"> <Setter Property="Background" Value="{StaticResource ComboBox.Static.Background}" /> <Setter Property="BorderBrush" Value="{StaticResource ComboBox.Static.Border}" /> @@ -363,10 +367,6 @@ </Trigger> </Style.Triggers> </Style> - <Style BasedOn="{StaticResource ComboBoxBaseStyle}" TargetType="{x:Type ComboBox}" /> - <Style - x:Key="ButtonStyle1" - BasedOn="{StaticResource ButtonBaseStyle}" - TargetType="{x:Type Button}" /> + </ResourceDictionary>
\ No newline at end of file diff --git a/win/CS/HandBrakeWPF/Themes/Dark.xaml b/win/CS/HandBrakeWPF/Themes/Dark.xaml index a68fba433..627df5c3c 100644 --- a/win/CS/HandBrakeWPF/Themes/Dark.xaml +++ b/win/CS/HandBrakeWPF/Themes/Dark.xaml @@ -20,9 +20,8 @@ <SolidColorBrush x:Key="{x:Static SystemColors.ControlTextBrushKey}" Color="White" /> <SolidColorBrush x:Key="{x:Static SystemColors.HighlightBrushKey}" Color="WhiteSmoke" /> - <!-- Button --> - <Style TargetType="Button"> + <Style TargetType="Button" BasedOn="{StaticResource {x:Type Button}}"> <Setter Property="Background" Value="{DynamicResource Ui.Light}" /> <Setter Property="Foreground" Value="White" /> </Style> @@ -50,6 +49,24 @@ <Setter Property="Foreground" Value="White" /> </Style> + <Style TargetType="{x:Type ContextMenu}"> + <Setter Property="Background" Value="{DynamicResource Ui.Mid}"/> + <Setter Property="Foreground" Value="WhiteSmoke"/> + </Style> + + <Style x:Key="{x:Static MenuItem.SeparatorStyleKey}" TargetType="{x:Type Separator}"> + <Setter Property="FocusVisualStyle" Value="{x:Null}"/> + <Setter Property="Template"> + <Setter.Value> + <ControlTemplate TargetType="{x:Type Separator}"> + <Grid Margin="3,2,3,2" SnapsToDevicePixels="true" UseLayoutRounding="False"> + <Rectangle Fill="WhiteSmoke" Height="1"/> + </Grid> + </ControlTemplate> + </Setter.Value> + </Setter> + </Style> + <!-- StatusBar --> <Style TargetType="StatusBar"> <Setter Property="Background" Value="{DynamicResource Ui.Mid}" /> @@ -57,7 +74,7 @@ </Style> <!-- Text Entry Controls --> - <Style TargetType="TextBox"> + <Style TargetType="TextBox" BasedOn="{StaticResource {x:Type TextBox}}"> <Setter Property="Background" Value="{DynamicResource Ui.Light}" /> </Style> @@ -93,7 +110,21 @@ </Setter> </Style> - <!-- ComboBox --> + <!-- DataGrid --> + <Style TargetType="{x:Type DataGridColumnHeader}" BasedOn="{StaticResource {x:Type DataGridColumnHeader}}"> + <Setter Property="Background" Value="{DynamicResource Ui.Dark}"/> + <Setter Property="BorderBrush" Value="{DynamicResource Ui.Ultralight}"/> + <Setter Property="Height" Value="28" /> + <Setter Property="BorderThickness" Value="0,1,0,1"/> + </Style> + + <!-- ComboBox--> + <Style TargetType="{x:Type ComboBox}" BasedOn="{StaticResource ComboBoxBaseStyle}"> + <Setter Property="MinHeight" Value="22"/> + <Setter Property="Margin" Value="0,2,0,2" /> + <Setter Property="ToolTipService.ShowDuration" Value="20000" /> + </Style> + <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="Controls/ComboBoxDark.xaml" /> </ResourceDictionary.MergedDictionaries> diff --git a/win/CS/HandBrakeWPF/Views/Styles/Styles.xaml b/win/CS/HandBrakeWPF/Views/Styles/Styles.xaml index 9bcca0635..5a061c7e1 100644 --- a/win/CS/HandBrakeWPF/Views/Styles/Styles.xaml +++ b/win/CS/HandBrakeWPF/Views/Styles/Styles.xaml @@ -1,13 +1,18 @@ <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
- <Style x:Key="LongToolTipHolder" TargetType="FrameworkElement">
+ <Style x:Key="LongToolTipHolder" TargetType="FrameworkElement" >
<Setter Property="ToolTipService.ShowDuration" Value="20000" />
</Style>
<Style TargetType="{x:Type ComboBox}" BasedOn="{StaticResource {x:Type ComboBox}}">
<Setter Property="MinHeight" Value="22"/>
<Setter Property="Margin" Value="0,2,0,2" />
+ <Setter Property="ToolTipService.ShowDuration" Value="20000" />
+ </Style>
+
+ <Style TargetType="{x:Type Slider}" BasedOn="{StaticResource {x:Type Slider}}">
+ <Setter Property="ToolTipService.ShowDuration" Value="20000" />
</Style>
<Style TargetType="{x:Type TextBlock}" BasedOn="{StaticResource {x:Type TextBlock}}">
diff --git a/win/CS/HandBrakeWPF/Views/VideoView.xaml b/win/CS/HandBrakeWPF/Views/VideoView.xaml index 77a665c23..3223a4910 100644 --- a/win/CS/HandBrakeWPF/Views/VideoView.xaml +++ b/win/CS/HandBrakeWPF/Views/VideoView.xaml @@ -151,8 +151,7 @@ <TextBlock Text="{x:Static Properties:Resources.VideoView_EncoderPreset}" Grid.Row="1" Grid.Column="0" VerticalAlignment="Center" Visibility="{Binding DisplayOptimiseOptions, Converter={StaticResource boolToVisConverter}}" />
<StackPanel Grid.Row="1" Grid.Column="1" Grid.ColumnSpan="3" Orientation="Horizontal" Visibility="{Binding DisplayOptimiseOptions, Converter={StaticResource boolToVisConverter}}">
<Slider Minimum="0" Maximum="{Binding VideoPresetMaxValue}" Width="150" Value="{Binding VideoPresetValue, Mode=Default, UpdateSourceTrigger=PropertyChanged}"
- IsSnapToTickEnabled="True" TickFrequency="1" TickPlacement="BottomRight" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Presets}"
- Style="{StaticResource LongToolTipHolder}" />
+ IsSnapToTickEnabled="True" TickFrequency="1" TickPlacement="BottomRight" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Presets}" />
<TextBlock Text="{Binding VideoPreset.DisplayName}" Margin="5,0,0,0" />
</StackPanel>
@@ -160,8 +159,7 @@ Visibility="{Binding DisplayTuneControls, Converter={StaticResource boolToVisConverter}}"/>
<ComboBox Width="100" Grid.Row="2" Grid.Column="1" Margin="5,5,5,0" Height="22" AutomationProperties.Name="{x:Static Properties:Resources.VideoView_EncodeTune}"
ItemsSource="{Binding VideoTunes}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoTune}" HorizontalAlignment="Left"
- ToolTip="{x:Static Properties:ResourcesTooltips.Video_EncoderTune}" Visibility="{Binding DisplayTuneControls, Converter={StaticResource boolToVisConverter}}"
- Style="{StaticResource LongToolTipHolder}" />
+ ToolTip="{x:Static Properties:ResourcesTooltips.Video_EncoderTune}" Visibility="{Binding DisplayTuneControls, Converter={StaticResource boolToVisConverter}}" />
<CheckBox IsChecked="{Binding FastDecode}" Content="{x:Static Properties:Resources.VideoView_FastDecode}" Grid.Row="2" Grid.Column="2" Margin="10,5,10,0" VerticalAlignment="Center" VerticalContentAlignment="Center"
ToolTip="{x:Static Properties:ResourcesTooltips.Video_FastDecode}" Visibility="{Binding DisplayFastDecode, Converter={StaticResource boolToVisConverter}}"/>
@@ -169,22 +167,19 @@ <!-- Row 2-->
<TextBlock Text="{x:Static Properties:Resources.VideoView_EncoderProfile}" Grid.Row="3" Grid.Column="0" Margin="0,5,0,0" VerticalAlignment="Center" Visibility="{Binding DisplayProfileControl, Converter={StaticResource boolToVisConverter}}"/>
<ComboBox Width="100" Grid.Row="3" Grid.Column="1" Margin="5,5,5,0" Height="22" VerticalAlignment="Center" Visibility="{Binding DisplayProfileControl, Converter={StaticResource boolToVisConverter}}"
- ItemsSource="{Binding VideoProfiles}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoProfile}" HorizontalAlignment="Left"
- Style="{StaticResource LongToolTipHolder}" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Profile}"
+ ItemsSource="{Binding VideoProfiles}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoProfile}" HorizontalAlignment="Left" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Profile}"
AutomationProperties.Name="{x:Static Properties:Resources.VideoView_EncoderProfile}" />
<TextBlock Text="{x:Static Properties:Resources.VideoView_EncoderLevel}" Grid.Row="3" Grid.Column="2" Margin="10,5,0,0" VerticalAlignment="Center" Visibility="{Binding DisplayLevelControl, Converter={StaticResource boolToVisConverter}}" />
<ComboBox Width="100" Grid.Row="3" Grid.Column="3" Margin="5,5,5,0" Height="22" VerticalAlignment="Center" Visibility="{Binding DisplayLevelControl, Converter={StaticResource boolToVisConverter}}"
- ItemsSource="{Binding VideoLevels}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoLevel}"
- Style="{StaticResource LongToolTipHolder}" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Level}"
+ ItemsSource="{Binding VideoLevels}" DisplayMemberPath="DisplayName" SelectedItem="{Binding VideoLevel}" ToolTip="{x:Static Properties:ResourcesTooltips.Video_Level}"
AutomationProperties.Name="{x:Static Properties:Resources.VideoView_EncoderLevel}" />
<!-- Row 3 -->
<TextBlock Text="{x:Static Properties:Resources.VideoView_ExtraOptions}" Grid.Row="4" Grid.Column="0" Margin="0,5,0,0" VerticalAlignment="Center" HorizontalAlignment="Left" />
<TextBox Text="{Binding ExtraArguments, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" TextWrapping="WrapWithOverflow"
AutomationProperties.Name="{x:Static Properties:Resources.VideoView_ExtraOptions}"
- Grid.Row="4" Grid.Column="1" Grid.ColumnSpan="4" Margin="5,5,5,2" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" VerticalContentAlignment="Stretch"
- ToolTip="{Binding FullOptionsTooltip}" Style="{StaticResource LongToolTipHolder}" >
+ Grid.Row="4" Grid.Column="1" Grid.ColumnSpan="4" Margin="5,5,5,2" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" VerticalContentAlignment="Stretch" >
<TextBox.ContextMenu>
<ContextMenu>
<MenuItem Header="Copy Full Query" cal:Message.Attach="[Event Click] = [Action CopyQuery]" />
|