diff --git a/Flow.Launcher.Core/Resource/Theme.cs b/Flow.Launcher.Core/Resource/Theme.cs
index 5eb5772b6..b12ddb13a 100644
--- a/Flow.Launcher.Core/Resource/Theme.cs
+++ b/Flow.Launcher.Core/Resource/Theme.cs
@@ -145,11 +145,9 @@ namespace Flow.Launcher.Core.Resource
public ResourceDictionary GetResourceDictionary()
{
var dict = CurrentThemeResourceDictionary();
-
- Style queryBoxStyle = dict["QueryBoxStyle"] as Style;
- Style querySuggestionBoxStyle = dict["QuerySuggestionBoxStyle"] as Style;
-
- if (queryBoxStyle != null && querySuggestionBoxStyle != null)
+
+ if (dict["QueryBoxStyle"] is Style queryBoxStyle &&
+ dict["QuerySuggestionBoxStyle"] is Style querySuggestionBoxStyle)
{
var fontFamily = new FontFamily(Settings.QueryBoxFont);
var fontStyle = FontHelper.GetFontStyleFromInvariantStringOrNormal(Settings.QueryBoxFontStyle);
@@ -174,14 +172,11 @@ namespace Flow.Launcher.Core.Resource
querySuggestionBoxStyle.Setters.Add(new Setter(TextBox.FontStretchProperty, fontStretch));
}
- Style resultItemStyle = dict["ItemTitleStyle"] as Style;
- Style resultSubItemStyle = dict["ItemSubTitleStyle"] as Style;
- Style resultHotkeyItemStyle = dict["ItemHotkeyStyle"] as Style;
- Style resultItemSelectedStyle = dict["ItemTitleSelectedStyle"] as Style;
- Style resultSubItemSelectedStyle = dict["ItemSubTitleSelectedStyle"] as Style;
- Style resultHotkeyItemSelectedStyle = dict["ItemHotkeySelectedStyle"] as Style;
-
- if (resultItemStyle != null && resultSubItemStyle != null && resultSubItemSelectedStyle != null && resultItemSelectedStyle != null)
+ if (dict["ItemTitleStyle"] is Style resultItemStyle &&
+ dict["ItemSubTitleStyle"] is Style resultSubItemStyle &&
+ dict["ItemSubTitleSelectedStyle"] is Style resultSubItemSelectedStyle &&
+ dict["ItemTitleSelectedStyle"] is Style resultItemSelectedStyle &&
+ dict["ItemHotkeySelectedStyle"] is Style resultHotkeyItemSelectedStyle)
{
Setter fontFamily = new Setter(TextBlock.FontFamilyProperty, new FontFamily(Settings.ResultFont));
Setter fontStyle = new Setter(TextBlock.FontStyleProperty, FontHelper.GetFontStyleFromInvariantStringOrNormal(Settings.ResultFontStyle));
@@ -189,7 +184,7 @@ namespace Flow.Launcher.Core.Resource
Setter fontStretch = new Setter(TextBlock.FontStretchProperty, FontHelper.GetFontStretchFromInvariantStringOrNormal(Settings.ResultFontStretch));
Setter[] setters = { fontFamily, fontStyle, fontWeight, fontStretch };
- Array.ForEach(new[] { resultItemStyle, resultSubItemStyle, resultItemSelectedStyle, resultSubItemSelectedStyle, resultHotkeyItemStyle, resultHotkeyItemSelectedStyle }, o => Array.ForEach(setters, p => o.Setters.Add(p)));
+ Array.ForEach(new[] { resultItemStyle, resultSubItemStyle, resultItemSelectedStyle, resultSubItemSelectedStyle, resultHotkeyItemSelectedStyle }, o => Array.ForEach(setters, p => o.Setters.Add(p)));
}
var windowStyle = dict["WindowStyle"] as Style;
@@ -239,17 +234,19 @@ namespace Flow.Launcher.Core.Resource
public void AddDropShadowEffectToCurrentTheme()
{
- var dict = CurrentThemeResourceDictionary();
+ var dict = GetResourceDictionary();
var windowBorderStyle = dict["WindowBorderStyle"] as Style;
- var effectSetter = new Setter();
- effectSetter.Property = Border.EffectProperty;
- effectSetter.Value = new DropShadowEffect
+ var effectSetter = new Setter
{
- Opacity = 0.4,
- ShadowDepth = 2,
- BlurRadius = 15
+ Property = Border.EffectProperty,
+ Value = new DropShadowEffect
+ {
+ Opacity = 0.9,
+ ShadowDepth = 2,
+ BlurRadius = 15
+ }
};
var marginSetter = windowBorderStyle.Setters.FirstOrDefault(setterBase => setterBase is Setter setter && setter.Property == Border.MarginProperty) as Setter;
diff --git a/Flow.Launcher/SettingWindow.xaml b/Flow.Launcher/SettingWindow.xaml
index 3a9f67f2c..5533c8b91 100644
--- a/Flow.Launcher/SettingWindow.xaml
+++ b/Flow.Launcher/SettingWindow.xaml
@@ -16,9 +16,9 @@
Title="{DynamicResource flowlauncher_settings}"
ResizeMode="CanResizeWithGrip"
WindowStartupLocation="CenterScreen"
- Height="800" Width="1280"
- MinWidth="1280"
- MinHeight="700"
+ Height="700" Width="900"
+ MinWidth="850"
+ MinHeight="600"
Loaded="OnLoaded"
Closed="OnClosed"
d:DataContext="{d:DesignInstance vm:SettingWindowViewModel}">
diff --git a/Flow.Launcher/Themes/Base.xaml b/Flow.Launcher/Themes/Base.xaml
index 3bfe79386..871e24abc 100644
--- a/Flow.Launcher/Themes/Base.xaml
+++ b/Flow.Launcher/Themes/Base.xaml
@@ -7,11 +7,11 @@
-
-
+
+
@@ -40,9 +40,9 @@
diff --git a/Flow.Launcher/Themes/Discord Dark.xaml b/Flow.Launcher/Themes/Discord Dark.xaml
index 17af0c413..0b2ac4d43 100644
--- a/Flow.Launcher/Themes/Discord Dark.xaml
+++ b/Flow.Launcher/Themes/Discord Dark.xaml
@@ -10,11 +10,15 @@
+
+
diff --git a/Flow.Launcher/Themes/League.xaml b/Flow.Launcher/Themes/League.xaml
index 04ab02907..374fddb71 100644
--- a/Flow.Launcher/Themes/League.xaml
+++ b/Flow.Launcher/Themes/League.xaml
@@ -6,11 +6,15 @@
+
+
diff --git a/Flow.Launcher/Themes/Sublime.xaml b/Flow.Launcher/Themes/Sublime.xaml
index 89c1035e4..259af947e 100644
--- a/Flow.Launcher/Themes/Sublime.xaml
+++ b/Flow.Launcher/Themes/Sublime.xaml
@@ -11,12 +11,16 @@
+
+
-
+
+
+
+