Files
FileConverter/Application/FileConverter/Controls/EncodingQualitySliderControl.xaml
T

31 lines
1.8 KiB
XML

<UserControl
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:valueConverters="clr-namespace:FileConverter.ValueConverters"
xmlns:project="clr-namespace:FileConverter.Properties"
x:Class="FileConverter.Controls.EncodingQualitySliderControl"
mc:Ignorable="d" d:DesignWidth="300" Height="50">
<UserControl.Resources>
<valueConverters:BitrateToString x:Key="BitrateToString"/>
</UserControl.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="65"/>
</Grid.ColumnDefinitions>
<Slider x:Name="slider" Grid.Column="0" Margin="0,2,0,0" VerticalAlignment="Top"
AutoToolTipPlacement="TopLeft" IsSnapToTickEnabled="True" IsSelectionRangeEnabled="True" Minimum="65" Maximum="245" SelectionStart="115" SelectionEnd="245" SmallChange="8" LargeChange="32" TickPlacement="BottomRight" TickFrequency="8" Ticks="65 85 100 115 130 165 175 190 225 245"
Foreground="{DynamicResource MainDarkBrush}" />
<Label Grid.Row="0" Grid.Column="1" Content="{Binding Value, Converter={StaticResource BitrateToString}, ElementName=slider, Mode=OneWay}" Width="65" />
<Label Grid.Column="0" Grid.Row="1" Content="{x:Static project:Resources.RecommendedBitrateRangeInBlue}" Foreground="{DynamicResource MainDarkBrush}" FontSize="11" />
</Grid>
</UserControl>