Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
2e3b61c
Change Window to Resizable
onesounds May 14, 2024
a628bc5
- Add Theme Editor
onesounds May 14, 2024
3659399
Remove Hand Cursor Style
onesounds May 14, 2024
68f34fa
Merge Dev
onesounds May 25, 2024
8d566d0
Merge Dev
onesounds May 25, 2024
d31c9a0
Adjust Toggle Style
onesounds May 25, 2024
37ab4aa
Change Edit Button to Icon
onesounds May 25, 2024
d7272d9
Fix Scroll for bottom margin in theme
onesounds May 25, 2024
5e5c9ae
Add Strings
onesounds May 25, 2024
4acbb7a
Removed MaxResult/Width item in settings
onesounds May 25, 2024
a88f165
Adjust Quick Resize Logic
onesounds May 25, 2024
7b106c5
Fix Sidebar Color
onesounds May 25, 2024
acde180
Merge branch 'dev' into 240514ResizableWindow
onesounds May 25, 2024
cedf0c6
- Add Reset Button Function
onesounds May 25, 2024
5a0f4ac
Adjust Default Value
onesounds May 25, 2024
de94f39
Fix window height reset issue
VictoriousRaptor May 25, 2024
0a52d71
Fix binding problem
VictoriousRaptor May 25, 2024
4fd05f5
- RollBack reset logic and Adjust naming
onesounds May 26, 2024
188c409
Adjust Reset Logic
onesounds May 26, 2024
ea4578f
Add Keep Height (old behaiver) function
onesounds May 26, 2024
3f710f2
Adjust Layout for Long Label (language)
onesounds May 26, 2024
ba3d262
MaxResult Item to Theme from General
onesounds May 26, 2024
a6de6c7
Adjust Width Logic
onesounds May 26, 2024
94df8d9
Merge branch 'dev' into 240514ResizableWindow
onesounds May 26, 2024
83bc664
Fix memory leak in ResultViewModel
Yusyuriv May 27, 2024
2893487
Appearance pane in settings: fix custom animation length TextBox not …
Yusyuriv May 27, 2024
8c3ef71
Resizeable window: fixes after review
Yusyuriv May 27, 2024
990f932
Resizeable window PR: remove GridSplitter
Yusyuriv May 27, 2024
218685d
Resizeable window PR: en.xaml correction
Yusyuriv May 27, 2024
e39a7ed
Merge branch 'dev' into 240514ResizableWindow
onesounds May 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions Flow.Launcher.Core/Resource/Theme.cs
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,6 @@ public ResourceDictionary GetResourceDictionary(string theme)
}

if (dict["ItemTitleStyle"] is Style resultItemStyle &&
dict["ItemSubTitleStyle"] is Style resultSubItemStyle &&
dict["ItemSubTitleSelectedStyle"] is Style resultSubItemSelectedStyle &&
dict["ItemTitleSelectedStyle"] is Style resultItemSelectedStyle &&
dict["ItemHotkeyStyle"] is Style resultHotkeyItemStyle &&
dict["ItemHotkeySelectedStyle"] is Style resultHotkeyItemSelectedStyle)
Expand All @@ -189,9 +187,25 @@ public ResourceDictionary GetResourceDictionary(string theme)

Setter[] setters = { fontFamily, fontStyle, fontWeight, fontStretch };
Array.ForEach(
new[] { resultItemStyle, resultSubItemStyle, resultItemSelectedStyle, resultSubItemSelectedStyle, resultHotkeyItemStyle, resultHotkeyItemSelectedStyle }, o
new[] { resultItemStyle, resultItemSelectedStyle, resultHotkeyItemStyle, resultHotkeyItemSelectedStyle }, o
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Separating / And adding Subtitle Styles.

=> Array.ForEach(setters, p => o.Setters.Add(p)));
}

if (
dict["ItemSubTitleStyle"] is Style resultSubItemStyle &&
dict["ItemSubTitleSelectedStyle"] is Style resultSubItemSelectedStyle)
{
Setter fontFamily = new Setter(TextBlock.FontFamilyProperty, new FontFamily(Settings.ResultSubFont));
Setter fontStyle = new Setter(TextBlock.FontStyleProperty, FontHelper.GetFontStyleFromInvariantStringOrNormal(Settings.ResultSubFontStyle));
Setter fontWeight = new Setter(TextBlock.FontWeightProperty, FontHelper.GetFontWeightFromInvariantStringOrNormal(Settings.ResultSubFontWeight));
Setter fontStretch = new Setter(TextBlock.FontStretchProperty, FontHelper.GetFontStretchFromInvariantStringOrNormal(Settings.ResultSubFontStretch));

Setter[] setters = { fontFamily, fontStyle, fontWeight, fontStretch };
Array.ForEach(
new[] { resultSubItemStyle,resultSubItemSelectedStyle}, o
=> Array.ForEach(setters, p => o.Setters.Add(p)));
}

/* Ignore Theme Window Width and use setting */
var windowStyle = dict["WindowStyle"] as Style;
var width = Settings.WindowSize;
Expand Down
12 changes: 12 additions & 0 deletions Flow.Launcher.Infrastructure/UserSettings/Settings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,13 @@ public string Theme
}
}
public bool UseDropShadowEffect { get; set; } = false;

/* Appearance Settings. It should be separated from the setting later.*/
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Settings for Customize

public double WindowHeightSize { get; set; } = 42;
public double ItemHeightSize { get; set; } = 58;
public double QueryBoxFontSize { get; set; } = 20;
public double ResultItemFontSize { get; set; } = 16;
public double ResultSubItemFontSize { get; set; } = 13;
public string QueryBoxFont { get; set; } = FontFamily.GenericSansSerif.Name;
public string QueryBoxFontStyle { get; set; }
public string QueryBoxFontWeight { get; set; }
Expand All @@ -64,6 +71,10 @@ public string Theme
public string ResultFontStyle { get; set; }
public string ResultFontWeight { get; set; }
public string ResultFontStretch { get; set; }
public string ResultSubFont { get; set; } = FontFamily.GenericSansSerif.Name;
public string ResultSubFontStyle { get; set; }
public string ResultSubFontWeight { get; set; }
public string ResultSubFontStretch { get; set; }
public bool UseGlyphIcons { get; set; } = true;
public bool UseAnimation { get; set; } = true;
public bool UseSound { get; set; } = true;
Expand Down Expand Up @@ -205,6 +216,7 @@ public SearchPrecisionScore QuerySearchPrecision
/// </summary>
public double CustomWindowTop { get; set; } = 0;

public bool KeepMaxResults { get; set; } = false;
public int MaxResultsToShow { get; set; } = 5;
public int ActivateTimes { get; set; }

Expand Down
10 changes: 9 additions & 1 deletion Flow.Launcher/Languages/en.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@
<system:String x:Key="LastQueryPreserved">Preserve Last Query</system:String>
<system:String x:Key="LastQuerySelected">Select last Query</system:String>
<system:String x:Key="LastQueryEmpty">Empty last Query</system:String>
<system:String x:Key="KeepMaxResults">Fixed Window Height</system:String>
<system:String x:Key="KeepMaxResultsToolTip">The window height will not be resizeable by dragging</system:String>
<system:String x:Key="maxShowResults">Maximum results shown</system:String>
<system:String x:Key="maxShowResultsToolTip">You can also quickly adjust this by using CTRL+Plus and CTRL+Minus.</system:String>
<system:String x:Key="ignoreHotkeysOnFullscreen">Ignore hotkeys in fullscreen mode</system:String>
Expand Down Expand Up @@ -145,8 +147,13 @@
<system:String x:Key="SampleSubTitleProgram">Launch programs as admin or a different user</system:String>
<system:String x:Key="SampleTitleProcessKiller">ProcessKiller</system:String>
<system:String x:Key="SampleSubTitleProcessKiller">Terminate unwanted processes</system:String>
<system:String x:Key="SearchBarHeight">Search Bar Height</system:String>
<system:String x:Key="ItemHeight">Item Height</system:String>
<system:String x:Key="queryBoxFont">Query Box Font</system:String>
<system:String x:Key="resultItemFont">Result Item Font</system:String>
<system:String x:Key="resultItemFont">Result Title Font</system:String>
<system:String x:Key="resultSubItemFont">Result Subtitle Font</system:String>
<system:String x:Key="resetCustomize">Reset</system:String>
<system:String x:Key="CustomizeToolTip">Customize</system:String>
<system:String x:Key="windowMode">Window Mode</system:String>
<system:String x:Key="opacity">Opacity</system:String>
<system:String x:Key="theme_load_failure_path_not_exists">Theme {0} not exists, fallback to default theme</system:String>
Expand All @@ -173,6 +180,7 @@
<system:String x:Key="Clock">Clock</system:String>
<system:String x:Key="Date">Date</system:String>


<!-- Setting Hotkey -->
<system:String x:Key="hotkey">Hotkey</system:String>
<system:String x:Key="hotkeys">Hotkeys</system:String>
Expand Down
Loading