2020-08-25 01:47:59 +08:00
|
|
|
<Page
|
2020-03-31 20:32:22 +08:00
|
|
|
x:Class="Microsoft.PowerToys.Settings.UI.Views.ImageResizerPage"
|
|
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
2020-07-18 02:01:46 +08:00
|
|
|
xmlns:CustomControls="using:Microsoft.PowerToys.Settings.UI.Controls"
|
2020-10-23 00:45:48 +08:00
|
|
|
xmlns:models="using:Microsoft.PowerToys.Settings.UI.Library"
|
|
|
|
xmlns:viewModels="using:Microsoft.PowerToys.Settings.UI.Library.ViewModels"
|
2020-03-31 20:32:22 +08:00
|
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
2020-08-19 04:43:58 +08:00
|
|
|
xmlns:muxc="using:Microsoft.UI.Xaml.Controls"
|
2020-03-31 20:32:22 +08:00
|
|
|
mc:Ignorable="d"
|
2020-10-29 02:10:08 +08:00
|
|
|
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"
|
|
|
|
AutomationProperties.LandmarkType="Main">
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-04-27 08:34:03 +08:00
|
|
|
<Page.Resources>
|
2020-08-19 04:43:58 +08:00
|
|
|
<!--<viewModel:ImageResizerViewModel x:Key="ViewModel"/>-->
|
2020-04-27 08:34:03 +08:00
|
|
|
</Page.Resources>
|
|
|
|
|
2020-08-08 03:00:48 +08:00
|
|
|
<Grid RowSpacing="{StaticResource DefaultRowSpacing}">
|
2020-03-31 20:32:22 +08:00
|
|
|
<VisualStateManager.VisualStateGroups>
|
|
|
|
<VisualStateGroup x:Name="LayoutVisualStates">
|
|
|
|
<VisualState x:Name="WideLayout">
|
|
|
|
<VisualState.StateTriggers>
|
|
|
|
<AdaptiveTrigger MinWindowWidth="{StaticResource WideLayoutMinWidth}" />
|
|
|
|
</VisualState.StateTriggers>
|
|
|
|
</VisualState>
|
|
|
|
<VisualState x:Name="SmallLayout">
|
|
|
|
<VisualState.StateTriggers>
|
|
|
|
<AdaptiveTrigger MinWindowWidth="{StaticResource SmallLayoutMinWidth}" />
|
2020-08-08 03:00:48 +08:00
|
|
|
<AdaptiveTrigger MinWindowWidth="0" />
|
2020-03-31 20:32:22 +08:00
|
|
|
</VisualState.StateTriggers>
|
|
|
|
<VisualState.Setters>
|
2020-07-25 03:02:56 +08:00
|
|
|
<Setter Target="SidePanel.(Grid.Column)" Value="0"/>
|
2020-08-08 03:00:48 +08:00
|
|
|
<Setter Target="SidePanel.Width" Value="Auto"/>
|
2020-07-25 03:02:56 +08:00
|
|
|
<Setter Target="ImageResizerView.(Grid.Row)" Value="1" />
|
2021-01-06 00:24:14 +08:00
|
|
|
<Setter Target="ImageResizerView.Margin" Value="0" />
|
2020-07-25 03:02:56 +08:00
|
|
|
<Setter Target="LinksPanel.(RelativePanel.RightOf)" Value="AboutImage"/>
|
|
|
|
<Setter Target="LinksPanel.(RelativePanel.AlignTopWith)" Value="AboutImage"/>
|
|
|
|
<Setter Target="AboutImage.Margin" Value="0,12,12,0"/>
|
|
|
|
<Setter Target="AboutTitle.Visibility" Value="Collapsed" />
|
2020-03-31 20:32:22 +08:00
|
|
|
</VisualState.Setters>
|
|
|
|
</VisualState>
|
|
|
|
</VisualStateGroup>
|
|
|
|
</VisualStateManager.VisualStateGroups>
|
|
|
|
<Grid.ColumnDefinitions>
|
|
|
|
<ColumnDefinition Width="*"/>
|
|
|
|
<ColumnDefinition Width="Auto"/>
|
|
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<Grid.RowDefinitions>
|
|
|
|
<RowDefinition Height="Auto"/>
|
|
|
|
<RowDefinition Height="Auto" />
|
|
|
|
</Grid.RowDefinitions>
|
2021-01-06 00:24:14 +08:00
|
|
|
<StackPanel Orientation="Vertical" x:Name="ImageResizerView"
|
|
|
|
Margin="0,0,48,0">
|
2020-04-27 08:34:03 +08:00
|
|
|
|
2020-05-06 04:58:48 +08:00
|
|
|
<ToggleSwitch x:Uid="ImageResizer_EnableToggle"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsOn="{x:Bind Mode=TwoWay, Path=ViewModel.IsEnabled}"/>
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBlock x:Uid="ImageResizer_CustomSizes"
|
|
|
|
Style="{StaticResource SettingsGroupTitleStyle}"
|
|
|
|
Foreground="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled, Converter={StaticResource ModuleEnabledToForegroundConverter}}"/>
|
2020-04-27 08:34:03 +08:00
|
|
|
|
|
|
|
<ListView x:Name="ImagesSizesListView"
|
2020-08-25 01:47:59 +08:00
|
|
|
x:Uid="ImagesSizesListView"
|
2020-08-19 04:43:58 +08:00
|
|
|
ItemsSource="{x:Bind ViewModel.Sizes, Mode=TwoWay}"
|
2021-01-06 00:24:14 +08:00
|
|
|
Padding="0,0,0,24"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}"
|
2020-09-24 04:20:58 +08:00
|
|
|
SelectionMode="None"
|
|
|
|
ScrollViewer.HorizontalScrollMode="Enabled"
|
|
|
|
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
2020-10-27 02:06:35 +08:00
|
|
|
ScrollViewer.IsHorizontalRailEnabled="True"
|
|
|
|
ContainerContentChanging="ImagesSizesListView_ContainerContentChanging">
|
2020-04-27 08:34:03 +08:00
|
|
|
|
|
|
|
<ListView.ItemContainerStyle>
|
|
|
|
<Style TargetType="ListViewItem">
|
|
|
|
<Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}"/>
|
|
|
|
<Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}"/>
|
|
|
|
<Setter Property="Background" Value="{ThemeResource ListViewItemBackground}"/>
|
|
|
|
<Setter Property="Foreground" Value="{ThemeResource ListViewItemForeground}"/>
|
|
|
|
<Setter Property="TabNavigation" Value="Local"/>
|
|
|
|
<Setter Property="IsHoldingEnabled" Value="True"/>
|
|
|
|
<Setter Property="Padding" Value="0"/>
|
|
|
|
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
|
|
|
|
<Setter Property="VerticalContentAlignment" Value="Center"/>
|
|
|
|
<Setter Property="MinWidth" Value="{ThemeResource ListViewItemMinWidth}"/>
|
|
|
|
<Setter Property="MinHeight" Value="0"/>
|
|
|
|
<Setter Property="AllowDrop" Value="False"/>
|
|
|
|
<Setter Property="UseSystemFocusVisuals" Value="True"/>
|
|
|
|
<Setter Property="FocusVisualMargin" Value="0"/>
|
|
|
|
<Setter Property="FocusVisualPrimaryBrush" Value="{ThemeResource ListViewItemFocusVisualPrimaryBrush}"/>
|
|
|
|
<Setter Property="FocusVisualPrimaryThickness" Value="2"/>
|
|
|
|
<Setter Property="FocusVisualSecondaryBrush" Value="{ThemeResource ListViewItemFocusVisualSecondaryBrush}"/>
|
|
|
|
<Setter Property="FocusVisualSecondaryThickness" Value="1"/>
|
|
|
|
<Setter Property="Template">
|
|
|
|
<Setter.Value>
|
|
|
|
<ControlTemplate TargetType="ListViewItem">
|
2020-10-23 05:37:10 +08:00
|
|
|
<ListViewItemPresenter
|
|
|
|
CheckBrush="{ThemeResource ListViewItemCheckBrush}"
|
|
|
|
ContentMargin="{TemplateBinding Padding}"
|
|
|
|
CheckMode="{ThemeResource ListViewItemCheckMode}"
|
|
|
|
ContentTransitions="{TemplateBinding ContentTransitions}"
|
|
|
|
CheckBoxBrush="{ThemeResource ListViewItemCheckBoxBrush}"
|
|
|
|
DragForeground="{ThemeResource ListViewItemDragForeground}"
|
|
|
|
DragOpacity="{ThemeResource ListViewItemDragThemeOpacity}"
|
|
|
|
DragBackground="{ThemeResource ListViewItemDragBackground}"
|
|
|
|
DisabledOpacity="{ThemeResource ListViewItemDisabledThemeOpacity}"
|
|
|
|
FocusVisualPrimaryBrush="{TemplateBinding FocusVisualPrimaryBrush}"
|
|
|
|
FocusVisualSecondaryThickness="{TemplateBinding FocusVisualSecondaryThickness}"
|
|
|
|
FocusBorderBrush="{ThemeResource ListViewItemFocusBorderBrush}"
|
|
|
|
FocusVisualMargin="{TemplateBinding FocusVisualMargin}"
|
|
|
|
FocusVisualPrimaryThickness="{TemplateBinding FocusVisualPrimaryThickness}"
|
|
|
|
FocusSecondaryBorderBrush="{ThemeResource ListViewItemFocusSecondaryBorderBrush}"
|
|
|
|
FocusVisualSecondaryBrush="{TemplateBinding FocusVisualSecondaryBrush}"
|
|
|
|
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
|
|
|
|
Control.IsTemplateFocusTarget="True"
|
|
|
|
PointerOverForeground="{ThemeResource ListViewItemForegroundPointerOver}"
|
|
|
|
PressedBackground="{ThemeResource ListViewItemBackgroundPressed}"
|
|
|
|
PlaceholderBackground="{ThemeResource ListViewItemPlaceholderBackground}"
|
|
|
|
PointerOverBackground="{ThemeResource ListViewItemBackgroundPointerOver}" ReorderHintOffset="{ThemeResource ListViewItemReorderHintThemeOffset}"
|
|
|
|
SelectedPressedBackground="{ThemeResource ListViewItemBackgroundSelectedPressed}"
|
|
|
|
SelectionCheckMarkVisualEnabled="{ThemeResource ListViewItemSelectionCheckMarkVisualEnabled}"
|
|
|
|
SelectedForeground="{ThemeResource ListViewItemForegroundSelected}"
|
|
|
|
SelectedPointerOverBackground="{ThemeResource ListViewItemBackgroundSelectedPointerOver}"
|
|
|
|
SelectedBackground="{ThemeResource ListViewItemBackgroundSelected}"
|
|
|
|
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
2020-04-27 08:34:03 +08:00
|
|
|
</ControlTemplate>
|
|
|
|
</Setter.Value>
|
|
|
|
</Setter>
|
|
|
|
</Style>
|
|
|
|
|
|
|
|
</ListView.ItemContainerStyle>
|
2020-03-31 20:32:22 +08:00
|
|
|
<ListView.ItemTemplate>
|
2020-04-27 08:34:03 +08:00
|
|
|
<DataTemplate x:Name="SingleLineDataTemplate" x:DataType="models:ImageSize" >
|
2020-10-23 05:37:10 +08:00
|
|
|
<StackPanel Name="ImageResizer_Configurations" x:Uid="ImageResizer_Configurations" Orientation="Horizontal" Padding="0" Spacing="4">
|
2020-08-25 01:47:59 +08:00
|
|
|
<TextBox Name="ImageResizer_Name"
|
|
|
|
x:Uid="ImageResizer_Name"
|
|
|
|
Text="{x:Bind Path=Name, Mode=TwoWay}"
|
2020-05-06 04:47:59 +08:00
|
|
|
Width="90"
|
|
|
|
VerticalAlignment="Center"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"/>
|
|
|
|
|
2020-08-25 01:47:59 +08:00
|
|
|
<ComboBox Name="ImageResizer_Fit_Property"
|
|
|
|
x:Uid="ImageResizer_Fit_Property"
|
|
|
|
SelectedIndex="{x:Bind Path=Fit, Mode=TwoWay}"
|
2020-05-06 04:47:59 +08:00
|
|
|
Width="90"
|
|
|
|
VerticalAlignment="Center"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}">
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Fit_Fill" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Fit_Fit" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Fit_Stretch" />
|
2020-03-31 20:32:22 +08:00
|
|
|
</ComboBox>
|
2020-04-27 08:34:03 +08:00
|
|
|
|
2020-08-25 01:47:59 +08:00
|
|
|
<muxc:NumberBox Name="ImageResizer_Width_Property"
|
|
|
|
x:Uid="ImageResizer_Width_Property"
|
|
|
|
Value="{x:Bind Path=Width, Mode=TwoWay}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="68"
|
2020-05-25 23:58:29 +08:00
|
|
|
SpinButtonPlacementMode="Compact"
|
2020-05-06 04:47:59 +08:00
|
|
|
VerticalAlignment="Center"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"/>
|
|
|
|
|
2020-08-25 01:47:59 +08:00
|
|
|
<TextBlock Name="ImageResizer_Times_Symbol"
|
|
|
|
x:Uid="ImageResizer_Times_Symbol"
|
|
|
|
Text=""
|
2020-05-06 04:47:59 +08:00
|
|
|
FontFamily="Segoe MDL2 Assets"
|
|
|
|
TextAlignment="Center"
|
|
|
|
VerticalAlignment="Center"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-06-20 04:18:37 +08:00
|
|
|
Opacity="{x:Bind Path=ExtraBoxOpacity, Mode=OneWay}"
|
2020-05-06 04:47:59 +08:00
|
|
|
Width="25"/>
|
2020-04-27 08:34:03 +08:00
|
|
|
|
2020-08-25 01:47:59 +08:00
|
|
|
<muxc:NumberBox Name="ImageResizer_Height_Property"
|
|
|
|
x:Uid="ImageResizer_Height_Property"
|
|
|
|
Value="{x:Bind Path=Height, Mode=TwoWay}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="68"
|
2020-05-06 04:47:59 +08:00
|
|
|
VerticalAlignment="Center"
|
2020-05-25 23:58:29 +08:00
|
|
|
SpinButtonPlacementMode="Compact"
|
2020-06-20 04:18:37 +08:00
|
|
|
Opacity="{x:Bind Path=ExtraBoxOpacity, Mode=OneWay}"
|
|
|
|
IsEnabled="{x:Bind Path=EnableEtraBoxes, Mode=OneWay}"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"/>
|
|
|
|
|
2020-08-25 01:47:59 +08:00
|
|
|
<ComboBox Name="ImageResizer_Size_Property"
|
|
|
|
x:Uid="ImageResizer_Size_Property"
|
|
|
|
SelectedIndex="{Binding Path=Unit, Mode=TwoWay}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="120"
|
2020-05-06 04:47:59 +08:00
|
|
|
VerticalAlignment="Center"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}">
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Units_CM" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Units_Inches" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Units_Percent" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_Sizes_Units_Pixels" />
|
2020-03-31 20:32:22 +08:00
|
|
|
</ComboBox>
|
2020-08-19 04:43:58 +08:00
|
|
|
<Button x:Name="RemoveButton"
|
2020-08-25 01:47:59 +08:00
|
|
|
x:Uid="RemoveButton"
|
2020-08-19 04:43:58 +08:00
|
|
|
Background="Transparent"
|
|
|
|
FontFamily="Segoe MDL2 Assets"
|
|
|
|
Width="34"
|
|
|
|
Content=""
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
|
|
|
UseLayoutRounding="False"
|
|
|
|
Click="DeleteCustomSize"
|
2020-11-05 16:02:31 +08:00
|
|
|
CommandParameter="{Binding Id}">
|
|
|
|
<ToolTipService.ToolTip>
|
|
|
|
<TextBlock x:Uid="RemoveTooltip"/>
|
|
|
|
</ToolTipService.ToolTip>
|
|
|
|
</Button>
|
2020-03-31 20:32:22 +08:00
|
|
|
</StackPanel>
|
|
|
|
</DataTemplate>
|
|
|
|
</ListView.ItemTemplate>
|
2020-04-27 08:34:03 +08:00
|
|
|
</ListView>
|
|
|
|
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-04-27 08:34:03 +08:00
|
|
|
<StackPanel Orientation="Horizontal">
|
|
|
|
<AppBarButton Icon="Add"
|
|
|
|
x:Name="AddSizeButton"
|
2020-05-12 03:36:55 +08:00
|
|
|
Style="{StaticResource AddItemAppBarButtonStyle}"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=TwoWay, Path=ViewModel.IsEnabled}"
|
|
|
|
x:Uid="ImageResizer_AddSizeButton"
|
2020-08-19 04:43:58 +08:00
|
|
|
Click="AddSizeButton_Click"
|
2020-05-12 03:36:55 +08:00
|
|
|
Margin="{StaticResource AddItemButtonMargin}"
|
2020-08-19 04:43:58 +08:00
|
|
|
|
2020-04-27 08:34:03 +08:00
|
|
|
/>
|
|
|
|
</StackPanel>
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBlock x:Uid="Encoding"
|
|
|
|
Style="{StaticResource SettingsGroupTitleStyle}"
|
|
|
|
Foreground="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled, Converter={StaticResource ModuleEnabledToForegroundConverter}}"/>
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-07-18 02:01:46 +08:00
|
|
|
<ComboBox x:Uid="ImageResizer_FallBackEncoderText"
|
2020-08-19 04:43:58 +08:00
|
|
|
SelectedIndex="{x:Bind Path=ViewModel.Encoder, Mode=TwoWay}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="240"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}">
|
2020-04-27 08:34:03 +08:00
|
|
|
<ComboBoxItem x:Uid="ImageResizer_FallbackEncoder_PNG" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_FallbackEncoder_BMP" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_FallbackEncoder_JPEG" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_FallbackEncoder_TIFF" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_FallbackEncoder_WMPhoto" />
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_FallbackEncoder_GIF" />
|
2020-03-31 20:32:22 +08:00
|
|
|
</ComboBox>
|
|
|
|
|
2020-09-09 06:28:57 +08:00
|
|
|
<muxc:NumberBox x:Uid="ImageResizer_Encoding"
|
|
|
|
Minimum="0"
|
2020-03-31 20:32:22 +08:00
|
|
|
Maximum="100"
|
2020-08-19 04:43:58 +08:00
|
|
|
Value="{x:Bind Mode=TwoWay, Path=ViewModel.JPEGQualityLevel}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="240"
|
2020-09-09 06:28:57 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-05-25 23:58:29 +08:00
|
|
|
SpinButtonPlacementMode="Compact"
|
2020-03-31 20:32:22 +08:00
|
|
|
HorizontalAlignment="Left"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}"
|
2020-08-25 01:47:59 +08:00
|
|
|
AutomationProperties.LabeledBy="{Binding ElementName=ImageResizer_Encoding}"
|
2020-07-18 02:01:46 +08:00
|
|
|
/>
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-07-18 02:01:46 +08:00
|
|
|
<ComboBox x:Uid="ImageResizer_PNGInterlacing"
|
2020-08-19 04:43:58 +08:00
|
|
|
SelectedIndex="{x:Bind Mode=TwoWay, Path=ViewModel.PngInterlaceOption}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="240"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}">
|
2020-04-27 08:34:03 +08:00
|
|
|
<ComboBoxItem x:Uid="Default"/>
|
|
|
|
<ComboBoxItem x:Uid="On"/>
|
|
|
|
<ComboBoxItem x:Uid="Off"/>
|
2020-03-31 20:32:22 +08:00
|
|
|
</ComboBox>
|
|
|
|
|
2020-07-18 02:01:46 +08:00
|
|
|
<ComboBox x:Uid="ImageResizer_TIFFCompression"
|
2020-08-19 04:43:58 +08:00
|
|
|
SelectedIndex="{x:Bind Mode=TwoWay, Path=ViewModel.TiffCompressOption}"
|
2020-10-23 05:37:10 +08:00
|
|
|
MinWidth="240"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}">
|
2020-04-27 08:34:03 +08:00
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_Default"/>
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_None"/>
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_CCITT3"/>
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_CCITT4"/>
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_LZW"/>
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_RLE"/>
|
|
|
|
<ComboBoxItem x:Uid="ImageResizer_ENCODER_TIFF_Zip"/>
|
2020-03-31 20:32:22 +08:00
|
|
|
</ComboBox>
|
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBlock x:Uid="File"
|
|
|
|
Style="{StaticResource SettingsGroupTitleStyle}"
|
|
|
|
Foreground="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled, Converter={StaticResource ModuleEnabledToForegroundConverter}}"/>
|
2020-07-18 02:01:46 +08:00
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBox Text="{x:Bind Mode=TwoWay, Path=ViewModel.FileName}"
|
2020-04-27 08:34:03 +08:00
|
|
|
HorizontalAlignment="Left"
|
|
|
|
MinWidth="240"
|
2020-10-14 03:30:57 +08:00
|
|
|
x:Uid="ImageResizer_FilenameFormatPlaceholder"
|
2020-07-18 02:01:46 +08:00
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}"
|
2020-08-25 01:47:59 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-10-23 22:10:16 +08:00
|
|
|
AutomationProperties.LabeledBy="{Binding ElementName=ImageResizer_FilenameFormatHeader}"
|
|
|
|
AutomationProperties.HelpText="{Binding ElementName=FileFormatTextBlock, Path=Text}"
|
|
|
|
>
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBox.Header>
|
|
|
|
<StackPanel Orientation="Horizontal">
|
2020-08-25 01:47:59 +08:00
|
|
|
<TextBlock Name="ImageResizer_FilenameFormatHeader"
|
|
|
|
x:Uid="ImageResizer_FilenameFormatHeader"
|
2020-07-25 03:02:56 +08:00
|
|
|
Margin="0,0,0,0"
|
|
|
|
Foreground="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled, Converter={StaticResource ModuleEnabledToForegroundConverter}}"/>
|
|
|
|
<TextBlock Text=""
|
|
|
|
FontFamily="Segoe MDL2 Assets"
|
|
|
|
Margin="4,4,0,0"/>
|
|
|
|
</StackPanel>
|
|
|
|
</TextBox.Header>
|
|
|
|
<ToolTipService.ToolTip>
|
2020-10-23 22:10:16 +08:00
|
|
|
<TextBlock x:Name="FileFormatTextBlock">
|
|
|
|
<Run x:Uid="ImageResizer_FileFormatDescription"/>
|
|
|
|
<LineBreak/>
|
|
|
|
<LineBreak/>
|
|
|
|
<Run Text="%1" FontWeight="Bold" />
|
|
|
|
<Run Text=" - "/>
|
|
|
|
<Run x:Uid="ImageResizer_Formatting_Filename" />
|
|
|
|
<LineBreak/>
|
|
|
|
<Run Text="%2" FontWeight="Bold" />
|
|
|
|
<Run Text=" - "/>
|
|
|
|
<Run x:Uid="ImageResizer_Formatting_Sizename"/>
|
|
|
|
<LineBreak/>
|
|
|
|
<Run Text="%3" FontWeight="Bold" />
|
|
|
|
<Run Text=" - "/>
|
|
|
|
<Run x:Uid="ImageResizer_Formatting_SelectedWidth"/>
|
|
|
|
<LineBreak/>
|
|
|
|
<Run Text="%4" FontWeight="Bold" />
|
|
|
|
<Run Text=" - "/>
|
|
|
|
<Run x:Uid="ImageResizer_Formatting_SelectedHeight"/>
|
|
|
|
<LineBreak/>
|
|
|
|
<Run Text="%5" FontWeight="Bold" />
|
|
|
|
<Run Text=" - "/>
|
|
|
|
<Run x:Uid="ImageResizer_Formatting_ActualWidth"/>
|
|
|
|
<LineBreak/>
|
|
|
|
<Run Text="%6" FontWeight="Bold" />
|
|
|
|
<Run Text=" - "/>
|
|
|
|
<Run x:Uid="ImageResizer_Formatting_ActualHeight"/>
|
|
|
|
</TextBlock>
|
2020-07-25 03:02:56 +08:00
|
|
|
</ToolTipService.ToolTip>
|
|
|
|
</TextBox>
|
2020-04-27 08:34:03 +08:00
|
|
|
|
2020-07-18 02:01:46 +08:00
|
|
|
<CheckBox x:Uid="ImageResizer_UseOriginalDate"
|
|
|
|
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}"
|
2020-04-27 08:34:03 +08:00
|
|
|
Margin="{StaticResource SmallTopMargin}"
|
2020-08-19 04:43:58 +08:00
|
|
|
IsChecked="{x:Bind Mode=TwoWay, Path=ViewModel.KeepDateModified}"/>
|
2020-03-31 20:32:22 +08:00
|
|
|
</StackPanel>
|
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<RelativePanel x:Name="SidePanel"
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
Width="{StaticResource SidePanelWidth}"
|
|
|
|
Grid.Column="1">
|
|
|
|
<StackPanel x:Name="DescriptionPanel">
|
|
|
|
<TextBlock x:Uid="About_ImageResizer" x:Name="AboutTitle" Grid.ColumnSpan="2"
|
|
|
|
Style="{StaticResource SettingsGroupTitleStyle}"
|
|
|
|
Margin="{StaticResource XSmallBottomMargin}"/>
|
|
|
|
<TextBlock x:Uid="ImageResizer_Description"
|
|
|
|
TextWrapping="Wrap"
|
|
|
|
Grid.Row="1" />
|
|
|
|
</StackPanel>
|
2020-03-31 20:32:22 +08:00
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<Border x:Name="AboutImage"
|
|
|
|
CornerRadius="4"
|
|
|
|
Grid.Row="2"
|
|
|
|
MaxWidth="240"
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
Margin="{StaticResource SmallTopBottomMargin}"
|
|
|
|
RelativePanel.Below="DescriptionPanel">
|
2021-01-05 02:51:05 +08:00
|
|
|
<HyperlinkButton x:Uid="ImageResizer_ImageHyperlinkToDocs">
|
|
|
|
<Image x:Uid="ImageResizer_Image" Source="ms-appx:///Assets/Modules/ImageResizer.png" />
|
|
|
|
</HyperlinkButton>
|
2020-07-25 03:02:56 +08:00
|
|
|
</Border>
|
2020-08-19 04:43:58 +08:00
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<StackPanel x:Name="LinksPanel"
|
2020-08-08 03:00:48 +08:00
|
|
|
Margin="0,1,0,0"
|
2020-07-25 03:02:56 +08:00
|
|
|
RelativePanel.Below="AboutImage"
|
|
|
|
Orientation="Vertical" >
|
2021-01-05 02:51:05 +08:00
|
|
|
<HyperlinkButton x:Uid="ImageResizer_ImageHyperlinkToDocs">
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBlock x:Uid="Module_overview" />
|
|
|
|
</HyperlinkButton>
|
2020-08-07 01:09:50 +08:00
|
|
|
<HyperlinkButton NavigateUri="https://aka.ms/powerToysGiveFeedback">
|
2020-07-25 03:02:56 +08:00
|
|
|
<TextBlock x:Uid="Give_Feedback" />
|
|
|
|
</HyperlinkButton>
|
|
|
|
|
|
|
|
<TextBlock
|
2020-04-27 08:34:03 +08:00
|
|
|
x:Uid="AttributionTitle"
|
2020-07-18 02:01:46 +08:00
|
|
|
Style="{StaticResource SettingsGroupTitleStyle}"/>
|
2020-04-27 08:34:03 +08:00
|
|
|
|
2020-07-25 03:02:56 +08:00
|
|
|
<HyperlinkButton Margin="0,-3,0,0"
|
|
|
|
NavigateUri="https://github.com/bricelam/ImageResizer/">
|
|
|
|
<TextBlock Text="Brice Lambson's ImageResizer" TextWrapping="Wrap" />
|
|
|
|
</HyperlinkButton>
|
|
|
|
</StackPanel>
|
|
|
|
</RelativePanel>
|
2020-03-31 20:32:22 +08:00
|
|
|
</Grid>
|
|
|
|
</Page>
|