Skip to content

Feature: Reword 'add pane' to 'split pane' #17387

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public string Description
=> Strings.ArrangePanesHorizontallyDescription.GetLocalizedResource();

public RichGlyph Glyph
=> new(themedIconStyle: "App.ThemedIcons.Panes.Vertical");
=> new(themedIconStyle: "App.ThemedIcons.Panes.Horizontal");

public bool IsOn
=> MultiPanesContext.ShellPaneArrangement is ShellPaneArrangement.Horizontal;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public string Description
=> Strings.ArrangePanesVerticallyDescription.GetLocalizedResource();

public RichGlyph Glyph
=> new(themedIconStyle: "App.ThemedIcons.Panes.Horizontal");
=> new(themedIconStyle: "App.ThemedIcons.Panes.Vertical");

public bool IsOn
=> MultiPanesContext.ShellPaneArrangement is ShellPaneArrangement.Vertical;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,28 +3,28 @@

namespace Files.App.Actions
{
internal sealed partial class AddHorizontalPaneAction : ObservableObject, IAction
internal sealed partial class SplitPaneHorizontallyAction : ObservableObject, IAction
{
private readonly IContentPageContext ContentPageContext = Ioc.Default.GetRequiredService<IContentPageContext>();
private readonly IGeneralSettingsService GeneralSettingsService = Ioc.Default.GetRequiredService<IGeneralSettingsService>();

public string Label
=> Strings.AddHorizontalPane.GetLocalizedResource();
=> Strings.SplitPaneHorizontally.GetLocalizedResource();

public string Description
=> Strings.AddHorizontalPaneDescription.GetLocalizedResource();
=> Strings.SplitPaneHorizontallyDescription.GetLocalizedResource();

public HotKey HotKey
=> new(Keys.H, KeyModifiers.AltShift);

public RichGlyph Glyph
=> new(themedIconStyle: "App.ThemedIcons.Panes.Vertical");
=> new(themedIconStyle: "App.ThemedIcons.Panes.Horizontal");

public bool IsExecutable =>
ContentPageContext.IsMultiPaneAvailable &&
!ContentPageContext.IsMultiPaneActive;

public AddHorizontalPaneAction()
public SplitPaneHorizontallyAction()
{
ContentPageContext.PropertyChanged += ContentPageContext_PropertyChanged;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@

namespace Files.App.Actions
{
internal sealed partial class AddVerticalPaneAction : ObservableObject, IAction
internal sealed partial class SplitPaneVerticallyAction : ObservableObject, IAction
{
private readonly IContentPageContext ContentPageContext = Ioc.Default.GetRequiredService<IContentPageContext>();
private readonly IGeneralSettingsService GeneralSettingsService = Ioc.Default.GetRequiredService<IGeneralSettingsService>();

public string Label
=> Strings.AddVerticalPane.GetLocalizedResource();
=> Strings.SplitPaneVertically.GetLocalizedResource();

public string Description
=> Strings.AddVerticalPaneDescription.GetLocalizedResource();
Expand All @@ -18,13 +18,13 @@ public HotKey HotKey
=> new(Keys.V, KeyModifiers.AltShift);

public RichGlyph Glyph
=> new(themedIconStyle: "App.ThemedIcons.Panes.Horizontal");
=> new(themedIconStyle: "App.ThemedIcons.Panes.Vertical");

public bool IsExecutable =>
ContentPageContext.IsMultiPaneAvailable &&
!ContentPageContext.IsMultiPaneActive;

public AddVerticalPaneAction()
public SplitPaneVerticallyAction()
{
ContentPageContext.PropertyChanged += ContentPageContext_PropertyChanged;
}
Expand Down
4 changes: 2 additions & 2 deletions src/Files.App/Data/Commands/Manager/CommandCodes.cs
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,8 @@ public enum CommandCodes
// Shell Panes
CloseActivePane,
FocusOtherPane,
AddVerticalPane,
AddHorizontalPane,
SplitPaneVertically,
SplitPaneHorizontally,
ArrangePanesVertically,
ArrangePanesHorizontally,

Expand Down
8 changes: 4 additions & 4 deletions src/Files.App/Data/Commands/Manager/CommandManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -213,8 +213,8 @@ public IRichCommand this[HotKey hotKey]
public IRichCommand CloseSelectedTab => commands[CommandCodes.CloseSelectedTab];
public IRichCommand CloseActivePane => commands[CommandCodes.CloseActivePane];
public IRichCommand FocusOtherPane => commands[CommandCodes.FocusOtherPane];
public IRichCommand AddVerticalPane => commands[CommandCodes.AddVerticalPane];
public IRichCommand AddHorizontalPane => commands[CommandCodes.AddHorizontalPane];
public IRichCommand SplitPaneVertically => commands[CommandCodes.SplitPaneVertically];
public IRichCommand SplitPaneHorizontally => commands[CommandCodes.SplitPaneHorizontally];
public IRichCommand ArrangePanesVertically => commands[CommandCodes.ArrangePanesVertically];
public IRichCommand ArrangePanesHorizontally => commands[CommandCodes.ArrangePanesHorizontally];
public IRichCommand OpenFileLocation => commands[CommandCodes.OpenFileLocation];
Expand Down Expand Up @@ -420,8 +420,8 @@ public IEnumerator<IRichCommand> GetEnumerator() =>
[CommandCodes.CloseSelectedTab] = new CloseSelectedTabAction(),
[CommandCodes.CloseActivePane] = new CloseActivePaneAction(),
[CommandCodes.FocusOtherPane] = new FocusOtherPaneAction(),
[CommandCodes.AddVerticalPane] = new AddVerticalPaneAction(),
[CommandCodes.AddHorizontalPane] = new AddHorizontalPaneAction(),
[CommandCodes.SplitPaneVertically] = new SplitPaneVerticallyAction(),
[CommandCodes.SplitPaneHorizontally] = new SplitPaneHorizontallyAction(),
[CommandCodes.ArrangePanesVertically] = new ArrangePanesVerticallyAction(),
[CommandCodes.ArrangePanesHorizontally] = new ArrangePanesHorizontallyAction(),
[CommandCodes.OpenFileLocation] = new OpenFileLocationAction(),
Expand Down
4 changes: 2 additions & 2 deletions src/Files.App/Data/Commands/Manager/ICommandManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,8 @@ public interface ICommandManager : IEnumerable<IRichCommand>

IRichCommand CloseActivePane { get; }
IRichCommand FocusOtherPane { get; }
IRichCommand AddVerticalPane { get; }
IRichCommand AddHorizontalPane { get; }
IRichCommand SplitPaneVertically { get; }
IRichCommand SplitPaneHorizontally { get; }
IRichCommand ArrangePanesVertically { get; }
IRichCommand ArrangePanesHorizontally { get; }

Expand Down
2 changes: 1 addition & 1 deletion src/Files.App/Services/Settings/GeneralSettingsService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ public string UserId

public ShellPaneArrangement ShellPaneArrangementOption
{
get => (ShellPaneArrangement)Get((long)ShellPaneArrangement.Horizontal);
get => (ShellPaneArrangement)Get((long)ShellPaneArrangement.Vertical);
set => Set((long)value);
}

Expand Down
25 changes: 14 additions & 11 deletions src/Files.App/Strings/en-US/Resources.resw
Original file line number Diff line number Diff line change
Expand Up @@ -4033,17 +4033,17 @@
<data name="TabActions" xml:space="preserve">
<value>Tab actions menu</value>
</data>
<data name="AddVerticalPane" xml:space="preserve">
<value>Vertical pane</value>
<data name="SplitPaneVertically" xml:space="preserve">
<value>Split vertically</value>
</data>
<data name="AddVerticalPaneDescription" xml:space="preserve">
<value>Add vertical pane</value>
<value>Split pane vertically</value>
</data>
<data name="AddHorizontalPane" xml:space="preserve">
<value>Horizontal pane</value>
<data name="SplitPaneHorizontally" xml:space="preserve">
<value>Split horizontally</value>
</data>
<data name="AddHorizontalPaneDescription" xml:space="preserve">
<value>Add horizontal pane</value>
<data name="SplitPaneHorizontallyDescription" xml:space="preserve">
<value>Split pane horizontally</value>
</data>
<data name="ArrangePanesVertically" xml:space="preserve">
<value>Arrange vertically</value>
Expand All @@ -4057,17 +4057,20 @@
<data name="ArrangePanesHorizontallyDescription" xml:space="preserve">
<value>Arrange panes horizontally</value>
</data>
<data name="AddPane" xml:space="preserve">
<value>Add pane</value>
<data name="SplitPane" xml:space="preserve">
<value>Split pane</value>
</data>
<data name="ShowTabActions" xml:space="preserve">
<value>Show tab actions button in the title bar</value>
</data>
<data name="ArrangePanes" xml:space="preserve">
<value>Arrange panes</value>
</data>
<data name="DefaultPaneArrangement" xml:space="preserve">
<value>Default pane arrangement</value>
<data name="DualPaneSplitDirection" xml:space="preserve">
<value>Default dual pane split direction</value>
</data>
<data name="DualPane" xml:space="preserve">
<value>Dual pane mode</value>
</data>
<data name="Horizontal" xml:space="preserve">
<value>Horizontal</value>
Expand Down
48 changes: 24 additions & 24 deletions src/Files.App/UserControls/TabBar/TabBar.xaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<!-- Copyright (c) Files Community. Licensed under the MIT License. -->
<local:BaseTabBar
x:Class="Files.App.UserControls.TabBar.TabBar"
Expand Down Expand Up @@ -143,24 +143,24 @@
<!-- Add Pane -->
<MenuFlyoutSubItem
x:Name="SplitPaneMenuItem"
x:Load="{x:Bind Commands.AddHorizontalPane.IsExecutable, Mode=OneWay}"
Text="{helpers:ResourceString Name=AddPane}">
<MenuFlyoutSubItem.Items>
<!-- Horizontal -->
<uc:MenuFlyoutItemWithThemedIcon
x:Name="AddHorizontalPaneTabActionButton"
Command="{x:Bind Commands.AddHorizontalPane, Mode=OneWay}"
KeyboardAcceleratorTextOverride="{x:Bind Commands.AddHorizontalPane.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.AddHorizontalPane.Label}"
ThemedIconStyle="{x:Bind Commands.AddHorizontalPane.ThemedIconStyle}" />

x:Load="{x:Bind Commands.SplitPaneHorizontally.IsExecutable, Mode=OneWay}"
Text="{helpers:ResourceString Name=SplitPane}">
<MenuFlyoutSubItem.Items>
<!-- Vertical -->
<uc:MenuFlyoutItemWithThemedIcon
x:Name="AddVerticalPaneTabActionButton"
Command="{x:Bind Commands.AddVerticalPane, Mode=OneWay}"
KeyboardAcceleratorTextOverride="{x:Bind Commands.AddVerticalPane.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.AddVerticalPane.Label}"
ThemedIconStyle="{x:Bind Commands.AddVerticalPane.ThemedIconStyle}" />
Command="{x:Bind Commands.SplitPaneVertically, Mode=OneWay}"
KeyboardAcceleratorTextOverride="{x:Bind Commands.SplitPaneVertically.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.SplitPaneVertically.Label}"
ThemedIconStyle="{x:Bind Commands.SplitPaneVertically.ThemedIconStyle}" />

<!-- Horizontal -->
<uc:MenuFlyoutItemWithThemedIcon
x:Name="SplitPaneHorizontalTabActionButton"
Command="{x:Bind Commands.SplitPaneHorizontally, Mode=OneWay}"
KeyboardAcceleratorTextOverride="{x:Bind Commands.SplitPaneHorizontally.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.SplitPaneHorizontally.Label}"
ThemedIconStyle="{x:Bind Commands.SplitPaneHorizontally.ThemedIconStyle}" />
</MenuFlyoutSubItem.Items>
</MenuFlyoutSubItem>

Expand All @@ -170,15 +170,6 @@
x:Load="{x:Bind Commands.CloseActivePane.IsExecutable, Mode=OneWay}"
Text="{helpers:ResourceString Name=ArrangePanes}">
<MenuFlyoutSubItem.Items>
<!-- Horizontal -->
<uc:ToggleMenuFlyoutItemWithThemedIcon
x:Name="ArrangePanesHorizontallyTabActionButton"
Command="{x:Bind Commands.ArrangePanesHorizontally, Mode=OneWay}"
IsChecked="{x:Bind Commands.ArrangePanesHorizontally.IsOn, Mode=OneWay}"
KeyboardAcceleratorTextOverride="{x:Bind Commands.ArrangePanesHorizontally.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.ArrangePanesHorizontally.Label}"
ThemedIconStyle="{x:Bind Commands.ArrangePanesHorizontally.ThemedIconStyle}" />

<!-- Vertical -->
<uc:ToggleMenuFlyoutItemWithThemedIcon
x:Name="ArrangePanesVerticallyTabActionButton"
Expand All @@ -187,6 +178,15 @@
KeyboardAcceleratorTextOverride="{x:Bind Commands.ArrangePanesVertically.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.ArrangePanesVertically.Label}"
ThemedIconStyle="{x:Bind Commands.ArrangePanesVertically.ThemedIconStyle}" />

<!-- Horizontal -->
<uc:ToggleMenuFlyoutItemWithThemedIcon
x:Name="ArrangePanesHorizontallyTabActionButton"
Command="{x:Bind Commands.ArrangePanesHorizontally, Mode=OneWay}"
IsChecked="{x:Bind Commands.ArrangePanesHorizontally.IsOn, Mode=OneWay}"
KeyboardAcceleratorTextOverride="{x:Bind Commands.ArrangePanesHorizontally.HotKeyText, Mode=OneWay}"
Text="{x:Bind Commands.ArrangePanesHorizontally.Label}"
ThemedIconStyle="{x:Bind Commands.ArrangePanesHorizontally.ThemedIconStyle}" />
</MenuFlyoutSubItem.Items>
</MenuFlyoutSubItem>

Expand Down
2 changes: 1 addition & 1 deletion src/Files.App/ViewModels/Settings/GeneralViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,8 @@ public GeneralViewModel()
PagesOnStartupList.CollectionChanged += PagesOnStartupList_CollectionChanged;

// ShellPaneArrangement
ShellPaneArrangementTypes.Add(ShellPaneArrangement.Horizontal, Strings.Horizontal.GetLocalizedResource());
ShellPaneArrangementTypes.Add(ShellPaneArrangement.Vertical, Strings.Vertical.GetLocalizedResource());
ShellPaneArrangementTypes.Add(ShellPaneArrangement.Horizontal, Strings.Horizontal.GetLocalizedResource());
SelectedShellPaneArrangementType = ShellPaneArrangementTypes[UserSettingsService.GeneralSettingsService.ShellPaneArrangementOption];

InitStartupSettingsRecentFoldersFlyout();
Expand Down
41 changes: 25 additions & 16 deletions src/Files.App/Views/Settings/GeneralPage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -177,22 +177,6 @@
</wctcontrols:SettingsExpander.Items>
</wctcontrols:SettingsExpander>

<!-- Dual Pane -->
<wctcontrols:SettingsExpander Header="{helpers:ResourceString Name=SettingsMultitaskingAlwaysOpenDualPane}">
<wctcontrols:SettingsExpander.HeaderIcon>
<FontIcon Glyph="&#xE89F;" />
</wctcontrols:SettingsExpander.HeaderIcon>
<ToggleSwitch AutomationProperties.Name="{helpers:ResourceString Name=SettingsMultitaskingAlwaysOpenDualPane}" IsOn="{x:Bind ViewModel.AlwaysOpenDualPaneInNewTab, Mode=TwoWay}" />
<wctcontrols:SettingsExpander.Items>
<wctcontrols:SettingsCard Header="{helpers:ResourceString Name=DefaultPaneArrangement}">
<uc:ComboBoxEx
AutomationProperties.Name="{helpers:ResourceString Name=DefaultPaneArrangement}"
ItemsSource="{x:Bind ViewModel.ShellPaneArrangementTypes.Values}"
SelectedItem="{x:Bind ViewModel.SelectedShellPaneArrangementType, Mode=TwoWay}" />
</wctcontrols:SettingsCard>
</wctcontrols:SettingsExpander.Items>
</wctcontrols:SettingsExpander>

<!-- Switch to new tab -->
<wctcontrols:SettingsCard Header="{helpers:ResourceString Name=AlwaysSwitchToNewlyOpenedTab}">
<wctcontrols:SettingsCard.HeaderIcon>
Expand Down Expand Up @@ -232,6 +216,31 @@
</wctcontrols:SettingsExpander.Items>
</wctcontrols:SettingsExpander>

<!-- Dual Pane -->
<TextBlock
Padding="0,16,0,4"
FontSize="16"
FontWeight="Medium"
Text="{helpers:ResourceString Name=DualPane}" />

<!-- Open tabs in Dual Pane mode -->
<wctcontrols:SettingsCard Header="{helpers:ResourceString Name=SettingsMultitaskingAlwaysOpenDualPane}">
<wctcontrols:SettingsCard.HeaderIcon>
<FontIcon Glyph="&#xE89F;" />
</wctcontrols:SettingsCard.HeaderIcon>
<ToggleSwitch AutomationProperties.Name="{helpers:ResourceString Name=SettingsMultitaskingAlwaysOpenDualPane}" IsOn="{x:Bind ViewModel.AlwaysOpenDualPaneInNewTab, Mode=TwoWay}" />
</wctcontrols:SettingsCard>

<!-- Dual Pane split direction -->
<wctcontrols:SettingsCard Header="{helpers:ResourceString Name=DualPaneSplitDirection}">
<wctcontrols:SettingsCard.HeaderIcon>
<FontIcon Glyph="&#xE784;" />
</wctcontrols:SettingsCard.HeaderIcon>
<uc:ComboBoxEx
AutomationProperties.Name="{helpers:ResourceString Name=DualPaneSplitDirection}"
ItemsSource="{x:Bind ViewModel.ShellPaneArrangementTypes.Values}"
SelectedItem="{x:Bind ViewModel.SelectedShellPaneArrangementType, Mode=TwoWay}" />
</wctcontrols:SettingsCard>

<!-- Right Click Menu -->
<TextBlock
Expand Down
Loading
Loading