From 0d610abfc6c1c76296950951df3957bb1bee4795 Mon Sep 17 00:00:00 2001 From: DB p Date: Wed, 2 Nov 2022 17:34:07 +0900 Subject: [PATCH] Adjust Images Quality --- Flow.Launcher/SettingWindow.xaml | 13 ++++++++----- Flow.Launcher/ViewModel/SettingWindowViewModel.cs | 2 ++ 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/Flow.Launcher/SettingWindow.xaml b/Flow.Launcher/SettingWindow.xaml index 97aad7878..53f277294 100644 --- a/Flow.Launcher/SettingWindow.xaml +++ b/Flow.Launcher/SettingWindow.xaml @@ -484,7 +484,6 @@ Width="16" Height="16" Margin="10,4,4,4" - RenderOptions.BitmapScalingMode="HighQuality" Source="/Images/app.png" /> + Style="{DynamicResource PluginListStyle}" + VirtualizingStackPanel.IsVirtualizing="True" + VirtualizingStackPanel.VirtualizationMode="Recycling"> @@ -1477,7 +1478,9 @@ ItemsSource="{Binding ExternalPlugins}" ScrollViewer.HorizontalScrollBarVisibility="Disabled" SelectionMode="Single" - Style="{DynamicResource StoreListStyle}"> + Style="{DynamicResource StoreListStyle}" + VirtualizingStackPanel.IsVirtualizing="True" + VirtualizingStackPanel.VirtualizationMode="Recycling"> @@ -1587,7 +1590,6 @@ Margin="20,20,6,0" HorizontalAlignment="Left" VerticalAlignment="Top" - RenderOptions.BitmapScalingMode="HighQuality" Source="{Binding IcoPath, IsAsync=True}" Stretch="Uniform" /> @@ -1756,7 +1758,8 @@ + ScrollViewer.CanContentScroll="False" + VirtualizingStackPanel.IsVirtualizing="True"> diff --git a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs index e382c207d..8920b9b6f 100644 --- a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs +++ b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs @@ -519,6 +519,8 @@ namespace Flow.Launcher.ViewModel var bitmap = new BitmapImage(); bitmap.BeginInit(); bitmap.StreamSource = memStream; + bitmap.DecodePixelWidth = 800; + bitmap.DecodePixelHeight = 600; bitmap.EndInit(); var brush = new ImageBrush(bitmap) { Stretch = Stretch.UniformToFill }; return brush;