Skip to content
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

Keybinds: Inconsistent Direction Parameters for new_split and goto_split #3237

Closed
KomisarzRyba opened this issue Dec 27, 2024 · 2 comments · Fixed by #3427
Closed

Keybinds: Inconsistent Direction Parameters for new_split and goto_split #3237

KomisarzRyba opened this issue Dec 27, 2024 · 2 comments · Fixed by #3427
Milestone

Comments

@KomisarzRyba
Copy link

KomisarzRyba commented Dec 27, 2024

Description

When configuring keybinds, the direction parameters for new_split and goto_split are inconsistent:

  • new_split uses: up | down | left | right
  • goto_split uses: previous | next | top | left | bottom | right

The goto_split direction parameters include top and bottom, which can be misleading as they might imply focusing on the topmost or bottommost split in the layout, rather than simply moving to an adjacent split. This inconsistency with new_split (up and down) may confuse users and create ambiguity in the configuration.

Steps to Reproduce

  1. Configure new_split keybinds:
    keybind = ctrl+s>h=new_split:left
    keybind = ctrl+s>j=new_split:down
    keybind = ctrl+s>k=new_split:up
    keybind = ctrl+s>l=new_split:right
    
  2. Configure goto_split keybinds:
    keybind = ctrl+h=goto_split:left
    keybind = ctrl+j=goto_split:bottom
    keybind = ctrl+k=goto_split:top
    keybind = ctrl+l=goto_split:right
    

Expected Behavior

The direction parameters should be consistent across both actions.

Actual Behavior

new_split and goto_split use different sets of direction parameters.

Suggested Change

Standardize the direction parameters to a single set, such as previous | next | up | left | down | right.

This would improve clarity and ease of configuration.

@mitchellh
Copy link
Contributor

Approved as suggested.

@pioz
Copy link

pioz commented Dec 27, 2024

Totally agree!

mitchellh added a commit that referenced this issue Jan 2, 2025
Renames the top/bottom directions of `goto_split` to up/down. I have
tested this on linux (nixos) but given that `goto_split` is broken on
linux anyway (#2866) there's not a whole lot to test.

I have no way to build on macOS so I can't verify that I've changed
everything correctly for that.

Closes #3237
@github-actions github-actions bot added this to the 1.0.2 milestone Jan 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants