diff --git a/doc/images/overview/ColorPicker_large.png b/doc/images/overview/ColorPicker_large.png index eb776f776d..2e0b272b68 100644 Binary files a/doc/images/overview/ColorPicker_large.png and b/doc/images/overview/ColorPicker_large.png differ diff --git a/doc/images/overview/ColorPicker_small.png b/doc/images/overview/ColorPicker_small.png index b7fb99d430..9c6d0a2017 100644 Binary files a/doc/images/overview/ColorPicker_small.png and b/doc/images/overview/ColorPicker_small.png differ diff --git a/doc/images/overview/Original/ColorPicker.png b/doc/images/overview/Original/ColorPicker.png index 38822f2bc2..ef12fdf072 100644 Binary files a/doc/images/overview/Original/ColorPicker.png and b/doc/images/overview/Original/ColorPicker.png differ diff --git a/src/core/Microsoft.PowerToys.Settings.UI/App.xaml b/src/core/Microsoft.PowerToys.Settings.UI/App.xaml index 13e116b83c..6d94ab97eb 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/App.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/App.xaml @@ -2,7 +2,8 @@ x:Class="Microsoft.PowerToys.Settings.UI.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" - xmlns:xaml="using:Microsoft.Toolkit.Win32.UI.XamlHost"> + xmlns:xaml="using:Microsoft.Toolkit.Win32.UI.XamlHost" + xmlns:converters="using:Microsoft.PowerToys.Settings.UI.Converters"> @@ -15,6 +16,7 @@ + \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Controls/BodyTextBlock.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Controls/BodyTextBlock.xaml deleted file mode 100644 index 0f9d06c6a1..0000000000 --- a/src/core/Microsoft.PowerToys.Settings.UI/Controls/BodyTextBlock.xaml +++ /dev/null @@ -1,28 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Controls/BodyTextBlock.xaml.cs b/src/core/Microsoft.PowerToys.Settings.UI/Controls/BodyTextBlock.xaml.cs deleted file mode 100644 index 4b03dab750..0000000000 --- a/src/core/Microsoft.PowerToys.Settings.UI/Controls/BodyTextBlock.xaml.cs +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright (c) Microsoft Corporation -// The Microsoft Corporation licenses this file to you under the MIT license. -// See the LICENSE file in the project root for more information. - -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Runtime.InteropServices.WindowsRuntime; -using Windows.Foundation; -using Windows.Foundation.Collections; -using Windows.UI.Xaml; -using Windows.UI.Xaml.Controls; -using Windows.UI.Xaml.Controls.Primitives; -using Windows.UI.Xaml.Data; -using Windows.UI.Xaml.Input; -using Windows.UI.Xaml.Media; -using Windows.UI.Xaml.Navigation; - -// The User Control item template is documented at https://go.microsoft.com/fwlink/?LinkId=234236 -namespace Microsoft.PowerToys.Settings.UI.Controls -{ - public sealed partial class BodyTextBlock : UserControl - { - public static readonly DependencyProperty TextProperty = - DependencyProperty.Register( - "Text", - typeof(string), - typeof(GroupTitleTextBlock), - null); - - public string _text; - - public string Text - { - get - { - return _text; - } - - set - { - _text = value; - CustomTextBlock.Text = value; - SetValue(TextProperty, value); - } - } - - public static readonly DependencyProperty IsActiveProperty = - DependencyProperty.Register( - "IsActive", - typeof(string), - typeof(GroupTitleTextBlock), - null); - - private string _isActive = "False"; - - public string IsActive - { - get - { - return _isActive; - } - - set - { - SetValue(IsActiveProperty, value); - _isActive = value; - CustomTextBlock.Tag = value; - } - } - - private Windows.UI.Text.FontWeight _fontWeight; - - public Windows.UI.Text.FontWeight FontWeight - { - get - { - return _fontWeight; - } - - set - { - _fontWeight = value; - CustomTextBlock.FontWeight = value; - } - } - - public BodyTextBlock() - { - this.InitializeComponent(); - CustomTextBlock.Tag = "False"; - } - } -} diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Controls/GroupTitleTextBlock.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Controls/GroupTitleTextBlock.xaml deleted file mode 100644 index b204c67a72..0000000000 --- a/src/core/Microsoft.PowerToys.Settings.UI/Controls/GroupTitleTextBlock.xaml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Controls/GroupTitleTextBlock.xaml.cs b/src/core/Microsoft.PowerToys.Settings.UI/Controls/GroupTitleTextBlock.xaml.cs deleted file mode 100644 index 4015f04cd7..0000000000 --- a/src/core/Microsoft.PowerToys.Settings.UI/Controls/GroupTitleTextBlock.xaml.cs +++ /dev/null @@ -1,73 +0,0 @@ -// Copyright (c) Microsoft Corporation -// The Microsoft Corporation licenses this file to you under the MIT license. -// See the LICENSE file in the project root for more information. - -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Runtime.InteropServices.WindowsRuntime; -using Windows.Foundation; -using Windows.Foundation.Collections; -using Windows.UI.Popups; -using Windows.UI.Xaml; -using Windows.UI.Xaml.Controls; -using Windows.UI.Xaml.Controls.Primitives; -using Windows.UI.Xaml.Data; -using Windows.UI.Xaml.Input; -using Windows.UI.Xaml.Media; -using Windows.UI.Xaml.Navigation; - -// The User Control item template is documented at https://go.microsoft.com/fwlink/?LinkId=234236 -namespace Microsoft.PowerToys.Settings.UI.Controls -{ - public sealed partial class GroupTitleTextBlock : UserControl - { - public string _text; - - public string Text - { - get - { - return _text; - } - - set - { - _text = value; - CustomTextBlock.Text = value; - } - } - - public static readonly DependencyProperty IsActiveProperty = - DependencyProperty.Register( - "IsActive", - typeof(string), - typeof(GroupTitleTextBlock), - null); - - private string _isActive = "False"; - - public string IsActive - { - get - { - return _isActive; - } - - set - { - SetValue(IsActiveProperty, value.ToString()); - _isActive = value.ToString(); - CustomTextBlock.Tag = value.ToString(); - } - } - - public GroupTitleTextBlock() - { - this.InitializeComponent(); - DataContext = this; - CustomTextBlock.Tag = "False"; - } - } -} diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml index 08cb0d604e..aff5abfe53 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml @@ -8,7 +8,32 @@ mc:Ignorable="d" d:DesignHeight="300" d:DesignWidth="400"> - - + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml.cs b/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml.cs index b1615e6130..d129a57a82 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml.cs +++ b/src/core/Microsoft.PowerToys.Settings.UI/Controls/HotkeySettingsControl.xaml.cs @@ -3,30 +3,29 @@ // See the LICENSE file in the project root for more information. using Microsoft.PowerToys.Settings.UI.Lib; +using System; using Windows.UI.Core; using Windows.UI.Xaml; using Windows.UI.Xaml.Controls; using Windows.UI.Xaml.Input; -using System; -using System.Data; -// The User Control item template is documented at https://go.microsoft.com/fwlink/?LinkId=234236 namespace Microsoft.PowerToys.Settings.UI.Controls { public sealed partial class HotkeySettingsControl : UserControl { public string Header { get; set; } + public string Keys { get; set; } public static readonly DependencyProperty IsActiveProperty = DependencyProperty.Register( "Enabled", - typeof(string), + typeof(bool), typeof(HotkeySettingsControl), null); - private string _enabled = "False"; + private bool _enabled = false; - public string Enabled + public bool Enabled { get { @@ -38,13 +37,17 @@ namespace Microsoft.PowerToys.Settings.UI.Controls SetValue(IsActiveProperty, value); _enabled = value; - if (value.ToString().ToLower() == "true") + if (value) { HotkeyTextBox.IsEnabled = true; + //TitleText.IsActive = "True"; + //TitleGlyph.IsActive = "True"; } else { HotkeyTextBox.IsEnabled = false; + //TitleText.IsActive = "False"; + //TitleGlyph.IsActive = "False"; } } } diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Converters/ModuleEnabledToForegroundConverter.cs b/src/core/Microsoft.PowerToys.Settings.UI/Converters/ModuleEnabledToForegroundConverter.cs new file mode 100644 index 0000000000..1fea50367a --- /dev/null +++ b/src/core/Microsoft.PowerToys.Settings.UI/Converters/ModuleEnabledToForegroundConverter.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Windows.UI; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Data; +using Windows.UI.Xaml.Media; + +namespace Microsoft.PowerToys.Settings.UI.Converters +{ + public sealed class ModuleEnabledToForegroundConverter : IValueConverter + { + public object Convert(object value, Type targetType, object parameter, string language) + { + bool isEnabled = (bool)value; + if (isEnabled) + { + return new SolidColorBrush((Color)Application.Current.Resources["SystemBaseHighColor"]); + } + else + { + return (SolidColorBrush)Application.Current.Resources["SystemControlDisabledBaseMediumLowBrush"]; + } + } + + public object ConvertBack(object value, Type targetType, object parameter, string language) + { + return value; + } + } +} \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Microsoft.PowerToys.Settings.UI.csproj b/src/core/Microsoft.PowerToys.Settings.UI/Microsoft.PowerToys.Settings.UI.csproj index 7db8bf0de5..4b66fae735 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Microsoft.PowerToys.Settings.UI.csproj +++ b/src/core/Microsoft.PowerToys.Settings.UI/Microsoft.PowerToys.Settings.UI.csproj @@ -93,15 +93,10 @@ - - BodyTextBlock.xaml - - - GroupTitleTextBlock.xaml - HotkeySettingsControl.xaml + Code @@ -207,14 +202,6 @@ - - Designer - MSBuild:Compile - - - Designer - MSBuild:Compile - MSBuild:Compile Designer diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw b/src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw index 06b545f1a7..0db953140b 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw +++ b/src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw @@ -170,7 +170,7 @@ Keyboard Manager current configuration header - Reconfigure your keyboard by remapping keys and shortcuts + Reconfigure your keyboard by remapping keys and shortcuts. Keyboard Manager page description @@ -198,19 +198,19 @@ Keyboard Manager remap shortcuts header - Quick and simple system-wide color picker + Quick and simple system-wide color picker. Enable Color Picker - + Change cursor when picking a color Copied color representation - Activation shortcut + Open Color Picker A quick launcher that has additional capabilities without sacrificing performance. @@ -264,13 +264,13 @@ Open console - Override Win+R key + Override Win+R shortcut - Override Win+S key + Override Win+S shortcut - Ignore hotkeys in fullscreen mode + Ignore shortcuts in fullscreen mode Disable drive detection warning for the indexer plugin @@ -306,8 +306,8 @@ Zone highlight opacity - - Edit hotkey / shortcut + + Open zones editor Launch zones editor @@ -322,10 +322,7 @@ Move windows between zones across all monitors when snapping with (Win + Arrow) - Override Windows Snap hotkeys (Win + Arrow) to move windows between zones - - - Save Zone Highlight Color Choice + Override Windows Snap shortcut (Win + Arrow) to move windows between zones Hold Shift key to activate zones while dragging @@ -390,9 +387,6 @@ Run at startup - - Miscellaneous - A Windows Shell extension for more advanced bulk renaming using search and replace or regular expressions. @@ -414,7 +408,7 @@ Maximum number of items - + Show values from last use @@ -435,7 +429,7 @@ Open-source notice - + Enable autocomplete for the search and replace fields @@ -444,12 +438,6 @@ Zone inactive color (Default: #F5FCFF) - - Save Zone Border Color Choice - - - Save Zone Inactive Color Choice - Shows a help overlay with Windows shortcuts when the Windows key is pressed. @@ -624,14 +612,8 @@ You need to run as administrator to use this setting - - Only shortcuts with the following hotkeys are valid: Win, Ctrl, Alt, Shift. - - - Only shortcuts with the following hotkeys are valid: Win, Ctrl, Alt, Shift. - - - Only shortcuts with the following hotkeys are valid: Win, Ctrl, Alt, Shift. + + Only shortcuts with the following hotkeys are valid: Restore the original size of windows when unsnapping @@ -642,7 +624,7 @@ The following parameters can be used: - + Filename format @@ -651,4 +633,13 @@ Encoding + + Remap keys to other keys or shortcuts. + + + Remap shortcuts to other shortcuts or keys. Additionally, mappings can be targeted to specific applications as well. + + + Microsoft PowerToys is a set of utilities for power users to tune and streamline their Windows experience for greater productivity + \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Styles/TextBlock.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Styles/TextBlock.xaml index 64d9e2d665..96147892a6 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Styles/TextBlock.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Styles/TextBlock.xaml @@ -20,7 +20,7 @@ - - + \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Colors.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Colors.xaml index de12eaa874..572145daf8 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Colors.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Colors.xaml @@ -1,5 +1,5 @@  - + diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Sizes.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Sizes.xaml index ec5eaec72c..b1962a77aa 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Sizes.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Styles/_Sizes.xaml @@ -3,7 +3,7 @@ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:Microsoft.PowerToys.Settings.UI.Styles"> - 180 + 240 1100 diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Views/ColorPickerPage.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Views/ColorPickerPage.xaml index 6aac1b867d..f7b0543a99 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Views/ColorPickerPage.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Views/ColorPickerPage.xaml @@ -19,9 +19,11 @@ - - - + + + + + @@ -29,9 +31,13 @@ - - - + + + + + + + @@ -45,68 +51,84 @@ - - - + + IsOn="{Binding IsEnabled, Mode=TwoWay}"/> + Keys="Win, Ctrl, Alt, Shift" + Enabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}" + /> + + - + + + --> - - + + + + + - - - + + + + + + + + + + - - - - - - - - - + + + + + - + \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Views/FancyZonesPage.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Views/FancyZonesPage.xaml index aa4c66acc0..f309a1657a 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Views/FancyZonesPage.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Views/FancyZonesPage.xaml @@ -19,7 +19,9 @@ - + @@ -27,9 +29,11 @@ - - - + + + + + @@ -37,9 +41,13 @@ - - - + + + + + + + @@ -53,15 +61,10 @@ - - - + - + x:Uid="FancyZones_EnableToggleControl_HeaderText" + IsOn="{x:Bind Mode=TwoWay, Path=ViewModel.IsEnabled}"/> - - - - - - - - - - - - - - - - - + @@ -175,9 +155,9 @@ Margin="{StaticResource SmallTopMargin}" IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsEnabled}"/> - + - + + + - + - - + + @@ -224,11 +211,13 @@ - + - + @@ -250,11 +239,13 @@ - + - + @@ -277,11 +268,10 @@ - - + + - - - - + + + - + + + - - - - - - - - - - + + + + + + + + + \ No newline at end of file diff --git a/src/core/Microsoft.PowerToys.Settings.UI/Views/GeneralPage.xaml b/src/core/Microsoft.PowerToys.Settings.UI/Views/GeneralPage.xaml index 26913c7ea0..67a8f8be98 100644 --- a/src/core/Microsoft.PowerToys.Settings.UI/Views/GeneralPage.xaml +++ b/src/core/Microsoft.PowerToys.Settings.UI/Views/GeneralPage.xaml @@ -26,9 +26,11 @@ - - - + + + + + @@ -36,9 +38,13 @@ - - - + + + + + + + @@ -54,7 +60,7 @@ - - + @@ -85,7 +91,8 @@ - + @@ -98,27 +105,26 @@ Content="System default" IsChecked="{ Binding Mode=TwoWay, Path=IsSystemThemeRadioButtonChecked, Source={StaticResource eventViewModel}}"/> - + - - + + - + Style="{StaticResource SettingsGroupTitleStyle}"/> + - - + +