mirror of
https://github.com/microsoft/PowerToys
synced 2025-08-29 13:37:43 +00:00
Localize CmdPal settings page (#38026)
* Localize CmdPal settings page * Xaml format * Fix it Follow up to #37908
This commit is contained in:
parent
394583fca9
commit
53003b9969
@ -73,17 +73,11 @@
|
|||||||
<!-- Content goes here -->
|
<!-- Content goes here -->
|
||||||
|
|
||||||
<controls:SettingsExpander.Items>
|
<controls:SettingsExpander.Items>
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_ExtensionPage_GlobalHotkey_SettingsCard" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
Description="Directly open Command Palette to this command"
|
|
||||||
Header="Global hotkey"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}">
|
|
||||||
<cpcontrols:ShortcutControl HotkeySettings="{x:Bind Hotkey, Mode=TwoWay}" />
|
<cpcontrols:ShortcutControl HotkeySettings="{x:Bind Hotkey, Mode=TwoWay}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
|
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_ExtensionPage_Alias_SettingsCard" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
Description="Typing this alias will navigate to this command. Direct aliases navigate as soon as you type the alias. Indirect aliases navigate after typing a trailing space"
|
|
||||||
Header="Alias"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}">
|
|
||||||
<StackPanel Orientation="Vertical">
|
<StackPanel Orientation="Vertical">
|
||||||
<TextBox Text="{x:Bind AliasText, Mode=TwoWay}" />
|
<TextBox Text="{x:Bind AliasText, Mode=TwoWay}" />
|
||||||
<ToggleSwitch
|
<ToggleSwitch
|
||||||
@ -121,10 +115,7 @@
|
|||||||
Text="{x:Bind ViewModel.ExtensionVersion}" />
|
Text="{x:Bind ViewModel.ExtensionVersion}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
|
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_ExtensionPage_Builtin_SettingsCard" Visibility="{x:Bind ViewModel.IsFromExtension, Mode=OneWay, Converter={StaticResource BoolToInvertedVisibilityConverter}}" />
|
||||||
Description="These commands are built-in to the Windows Command Palette"
|
|
||||||
Header="Built-in"
|
|
||||||
Visibility="{x:Bind ViewModel.IsFromExtension, Mode=OneWay, Converter={StaticResource BoolToInvertedVisibilityConverter}}" />
|
|
||||||
|
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
@ -34,20 +34,16 @@
|
|||||||
<RepositionThemeTransition IsStaggeringEnabled="False" />
|
<RepositionThemeTransition IsStaggeringEnabled="False" />
|
||||||
</StackPanel.ChildrenTransitions>-->
|
</StackPanel.ChildrenTransitions>-->
|
||||||
<controls:SettingsExpander
|
<controls:SettingsExpander
|
||||||
Description="This key will open the Command Palette"
|
x:Uid="Settings_GeneralPage_ActivationKey_SettingsExpander"
|
||||||
Header="Activation key"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}"
|
HeaderIcon="{ui:FontIcon Glyph=}"
|
||||||
IsExpanded="True">
|
IsExpanded="True">
|
||||||
<ptControls:ShortcutControl HotkeySettings="{x:Bind viewModel.Hotkey, Mode=TwoWay}" />
|
<ptControls:ShortcutControl HotkeySettings="{x:Bind viewModel.Hotkey, Mode=TwoWay}" />
|
||||||
|
|
||||||
<controls:SettingsExpander.Items>
|
<controls:SettingsExpander.Items>
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_GeneralPage_GoHome_SettingsCard" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
Description="If enabled, the Command Palette will return to the home page when activated"
|
|
||||||
Header="Go home when activated"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}">
|
|
||||||
<ToggleSwitch IsOn="{x:Bind viewModel.HotkeyGoesHome, Mode=TwoWay}" />
|
<ToggleSwitch IsOn="{x:Bind viewModel.HotkeyGoesHome, Mode=TwoWay}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
<controls:SettingsCard Description="When enabled, the previous search text will be selected when the app is opened" Header="Highlight search on activate">
|
<controls:SettingsCard x:Uid="Settings_GeneralPage_HighlightSearch_SettingsCard">
|
||||||
<ToggleSwitch IsOn="{x:Bind viewModel.HighlightSearchOnActivate, Mode=TwoWay}" />
|
<ToggleSwitch IsOn="{x:Bind viewModel.HighlightSearchOnActivate, Mode=TwoWay}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
<controls:SettingsCard x:Uid="Run_PositionHeader" HeaderIcon="{ui:FontIcon Glyph=}">
|
<controls:SettingsCard x:Uid="Run_PositionHeader" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
@ -62,34 +58,22 @@
|
|||||||
</controls:SettingsExpander.Items>
|
</controls:SettingsExpander.Items>
|
||||||
</controls:SettingsExpander>
|
</controls:SettingsExpander>
|
||||||
|
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_GeneralPage_ShowAppDetails_SettingsCard" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
Description="Controls if app details are automatically expanded or not"
|
|
||||||
Header="Show app details"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}">
|
|
||||||
<ToggleSwitch IsOn="{x:Bind viewModel.ShowAppDetails, Mode=TwoWay}" />
|
<ToggleSwitch IsOn="{x:Bind viewModel.ShowAppDetails, Mode=TwoWay}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
|
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_GeneralPage_BackspaceGoesBack_SettingsCard" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
Description="When enabled, pressing backspace when the search text is empty will take you back"
|
|
||||||
Header="Backspace goes back"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}">
|
|
||||||
<ToggleSwitch IsOn="{x:Bind viewModel.BackspaceGoesBack, Mode=TwoWay}" />
|
<ToggleSwitch IsOn="{x:Bind viewModel.BackspaceGoesBack, Mode=TwoWay}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
|
|
||||||
<controls:SettingsCard
|
<controls:SettingsCard x:Uid="Settings_GeneralPage_SingleClickActivation_SettingsCard" HeaderIcon="{ui:FontIcon Glyph=}">
|
||||||
Description="When enabled, single click activates list items. When disabled, single click selects and double click activates."
|
|
||||||
Header="Single-click activates"
|
|
||||||
HeaderIcon="{ui:FontIcon Glyph=}">
|
|
||||||
<ToggleSwitch IsOn="{x:Bind viewModel.SingleClickActivates, Mode=TwoWay}" />
|
<ToggleSwitch IsOn="{x:Bind viewModel.SingleClickActivates, Mode=TwoWay}" />
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
|
|
||||||
<!-- Example 'About' section -->
|
<!-- Example 'About' section -->
|
||||||
<TextBlock x:Uid="AboutSettingsHeader" Style="{StaticResource SettingsSectionHeaderTextBlockStyle}" />
|
<TextBlock x:Uid="AboutSettingsHeader" Style="{StaticResource SettingsSectionHeaderTextBlockStyle}" />
|
||||||
|
|
||||||
<controls:SettingsExpander
|
<controls:SettingsExpander x:Uid="Settings_GeneralPage_About_SettingsExpander" HeaderIcon="{ui:BitmapIcon Source=ms-appx:///Assets/StoreLogo.png}">
|
||||||
Description="© 2025. All rights reserved."
|
|
||||||
Header="Windows Command Palette"
|
|
||||||
HeaderIcon="{ui:BitmapIcon Source=ms-appx:///Assets/StoreLogo.png}">
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Foreground="{ThemeResource TextFillColorSecondaryBrush}"
|
Foreground="{ThemeResource TextFillColorSecondaryBrush}"
|
||||||
IsTextSelectionEnabled="True"
|
IsTextSelectionEnabled="True"
|
||||||
@ -97,15 +81,15 @@
|
|||||||
<controls:SettingsExpander.Items>
|
<controls:SettingsExpander.Items>
|
||||||
<controls:SettingsCard HorizontalContentAlignment="Left" ContentAlignment="Left">
|
<controls:SettingsCard HorizontalContentAlignment="Left" ContentAlignment="Left">
|
||||||
<StackPanel Margin="-12,0,0,0" Orientation="Vertical">
|
<StackPanel Margin="-12,0,0,0" Orientation="Vertical">
|
||||||
<HyperlinkButton Content="View GitHub Repo" NavigateUri="https://github.com/zadjii-msft/PowerToys" />
|
<HyperlinkButton x:Uid="Settings_GeneralPage_About_GithubLink_Hyperlink" NavigateUri="https://github.com/zadjii-msft/PowerToys" />
|
||||||
<HyperlinkButton Content="Extension SDK docs" NavigateUri="https://github.com/zadjii-msft/PowerToys/blob/main/src/modules/cmdpal/doc/initial-sdk-spec/initial-sdk-spec.md" />
|
<HyperlinkButton x:Uid="Settings_GeneralPage_About_SDKDocs_Hyperlink" NavigateUri="https://github.com/zadjii-msft/PowerToys/blob/main/src/modules/cmdpal/doc/initial-sdk-spec/initial-sdk-spec.md" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</controls:SettingsCard>
|
</controls:SettingsCard>
|
||||||
</controls:SettingsExpander.Items>
|
</controls:SettingsExpander.Items>
|
||||||
</controls:SettingsExpander>
|
</controls:SettingsExpander>
|
||||||
<HyperlinkButton
|
<HyperlinkButton
|
||||||
|
x:Uid="Settings_GeneralPage_SendFeedback_Hyperlink"
|
||||||
Margin="0,8,0,0"
|
Margin="0,8,0,0"
|
||||||
Content="Send feedback"
|
|
||||||
NavigateUri="https://github.com/zadjii-msft/PowerToys/issues/new" />
|
NavigateUri="https://github.com/zadjii-msft/PowerToys/issues/new" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
@ -45,11 +45,11 @@
|
|||||||
</NavigationView.Resources>
|
</NavigationView.Resources>
|
||||||
<NavigationView.MenuItems>
|
<NavigationView.MenuItems>
|
||||||
<NavigationViewItem
|
<NavigationViewItem
|
||||||
Content="General"
|
x:Uid="Settings_GeneralPage_NavigationViewItem_General"
|
||||||
Icon="{ui:FontIcon Glyph=}"
|
Icon="{ui:FontIcon Glyph=}"
|
||||||
Tag="General" />
|
Tag="General" />
|
||||||
<NavigationViewItem
|
<NavigationViewItem
|
||||||
Content="Extensions"
|
x:Uid="Settings_GeneralPage_NavigationViewItem_Extensions"
|
||||||
Icon="{ui:FontIcon Glyph=}"
|
Icon="{ui:FontIcon Glyph=}"
|
||||||
Tag="Extensions" />
|
Tag="Extensions" />
|
||||||
</NavigationView.MenuItems>
|
</NavigationView.MenuItems>
|
||||||
|
@ -278,4 +278,79 @@ Right-click to remove the key combination, thereby deactivating the shortcut.</v
|
|||||||
<data name="ConfirmationDialog_CancelButtonText" xml:space="preserve">
|
<data name="ConfirmationDialog_CancelButtonText" xml:space="preserve">
|
||||||
<value>Cancel</value>
|
<value>Cancel</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Settings_ExtensionPage_GlobalHotkey_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Global hotkey</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_ExtensionPage_GlobalHotkey_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>Directly open Command Palette to this command.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_ExtensionPage_Alias_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Alias</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_ExtensionPage_Alias_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>Typing this alias will navigate to this command. Direct aliases navigate as soon as you type the alias. Indirect aliases navigate after typing a trailing space.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_ExtensionPage_Builtin_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Built-in</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_ExtensionPage_Builtin_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>These commands are built-in to the Windows Command Palette.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_ActivationKey_SettingsExpander.Header" xml:space="preserve">
|
||||||
|
<value>Activation key</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_ActivationKey_SettingsExpander.Description" xml:space="preserve">
|
||||||
|
<value>This key will open the Command Palette.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_GoHome_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Go home when activated</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_GoHome_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>If enabled, the Command Palette will return to the home page when activated.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_HighlightSearch_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Highlight search on activate</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_HighlightSearch_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>When enabled, the previous search text will be selected when the app is opened.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_ShowAppDetails_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Show app details</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_ShowAppDetails_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>Controls if app details are automatically expanded or not.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_BackspaceGoesBack_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Backspace goes back</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_BackspaceGoesBack_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>When enabled, pressing backspace when the search text is empty will take you back.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_SingleClickActivation_SettingsCard.Header" xml:space="preserve">
|
||||||
|
<value>Single-click activates</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_SingleClickActivation_SettingsCard.Description" xml:space="preserve">
|
||||||
|
<value>When enabled, single click activates list items. When disabled, single click selects and double click activates.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_About_SettingsExpander.Header" xml:space="preserve">
|
||||||
|
<value>Windows Command Palette</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_About_SettingsExpander.Description" xml:space="preserve">
|
||||||
|
<value>© 2025. All rights reserved.</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_About_GithubLink_Hyperlink.Content" xml:space="preserve">
|
||||||
|
<value>View GitHub Repo</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_About_SDKDocs_Hyperlink.Content" xml:space="preserve">
|
||||||
|
<value>Extension SDK docs</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_SendFeedback_Hyperlink.Content" xml:space="preserve">
|
||||||
|
<value>Send feedback</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_NavigationViewItem_General.Content" xml:space="preserve">
|
||||||
|
<value>General</value>
|
||||||
|
</data>
|
||||||
|
<data name="Settings_GeneralPage_NavigationViewItem_Extensions.Content" xml:space="preserve">
|
||||||
|
<value>Extensions</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
@ -1,9 +1,8 @@
|
|||||||
<Application x:Class="FancyZone_HitTest.App"
|
<Application
|
||||||
|
x:Class="FancyZone_HitTest.App"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:local="clr-namespace:FancyZone_HitTest"
|
xmlns:local="clr-namespace:FancyZone_HitTest"
|
||||||
StartupUri="MainWindow.xaml">
|
StartupUri="MainWindow.xaml">
|
||||||
<Application.Resources>
|
<Application.Resources />
|
||||||
|
|
||||||
</Application.Resources>
|
|
||||||
</Application>
|
</Application>
|
||||||
|
@ -1,17 +1,20 @@
|
|||||||
<Window x:Class="FancyZone_HitTest.MainWindow"
|
<Window
|
||||||
|
x:Class="FancyZone_HitTest.MainWindow"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
||||||
xmlns:local="clr-namespace:FancyZone_HitTest"
|
xmlns:local="clr-namespace:FancyZone_HitTest"
|
||||||
mc:Ignorable="d"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
Title="MainWindow" Width="1024" Height="768">
|
Title="MainWindow"
|
||||||
|
Width="1024"
|
||||||
|
Height="768"
|
||||||
|
mc:Ignorable="d">
|
||||||
<Grid>
|
<Grid>
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
<ColumnDefinition />
|
<ColumnDefinition />
|
||||||
<ColumnDefinition Width="200" />
|
<ColumnDefinition Width="200" />
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<Grid MouseMove="Grid_MouseMove" Name="hitTestGrid">
|
<Grid Name="hitTestGrid" MouseMove="Grid_MouseMove">
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
<ColumnDefinition Width="*" />
|
<ColumnDefinition Width="*" />
|
||||||
<ColumnDefinition Width="*" />
|
<ColumnDefinition Width="*" />
|
||||||
@ -19,13 +22,35 @@
|
|||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
|
|
||||||
|
|
||||||
<Rectangle Fill="#ff0000" Grid.Column="0" Name="a" />
|
<Rectangle
|
||||||
<Rectangle Fill="#00ff00" Grid.Column="1" Name="b" />
|
Name="a"
|
||||||
<Rectangle Fill="#0000ff" Grid.Column="2" Name="c" />
|
Grid.Column="0"
|
||||||
<Rectangle Fill="#aabbff" Grid.ColumnSpan="3" Name="d" Width="550" Height="500" />
|
Fill="#ff0000" />
|
||||||
|
<Rectangle
|
||||||
|
Name="b"
|
||||||
|
Grid.Column="1"
|
||||||
|
Fill="#00ff00" />
|
||||||
|
<Rectangle
|
||||||
|
Name="c"
|
||||||
|
Grid.Column="2"
|
||||||
|
Fill="#0000ff" />
|
||||||
|
<Rectangle
|
||||||
|
Name="d"
|
||||||
|
Grid.ColumnSpan="3"
|
||||||
|
Width="550"
|
||||||
|
Height="500"
|
||||||
|
Fill="#aabbff" />
|
||||||
<!-- Height="600" -->
|
<!-- Height="600" -->
|
||||||
<Rectangle Fill="#aabbff" Grid.ColumnSpan="3" Name="f" Height="400" Width="400" />
|
<Rectangle
|
||||||
<Rectangle Fill="Orange" Grid.ColumnSpan="3" Name="e"/>
|
Name="f"
|
||||||
|
Grid.ColumnSpan="3"
|
||||||
|
Width="400"
|
||||||
|
Height="400"
|
||||||
|
Fill="#aabbff" />
|
||||||
|
<Rectangle
|
||||||
|
Name="e"
|
||||||
|
Grid.ColumnSpan="3"
|
||||||
|
Fill="Orange" />
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
<StackPanel Grid.Column="1">
|
<StackPanel Grid.Column="1">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user