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

[Linux] Ctrl F followed with keyboard combination to _Select Next Match_ Ctrl Alt G is buggy. #13728

Open
1 task done
krstp opened this issue Jul 2, 2024 · 1 comment
Open
1 task done
Labels
defect [core label] keymap / key binding Feedback for keyboard shortcuts, key mapping, etc linux

Comments

@krstp
Copy link

krstp commented Jul 2, 2024

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

The search of Ctrl Alt G is buggy. When I try to select next instance it takes a few seconds before it jump to the next match. On contrary, when using reverse match with Shift Ctrl Alt G it works instantaneously; which is a clear indicator the bug is present.

Needless to say, I just found out, the Ctrl F also allows be to find next match by pressing Enter (nice!) and reverse match by using Shift Enter, which both work flawlessly. This means, there is mismatch in Ctrl Alt G functionality and Enter in terms of next match.

Environment

Zed: v0.141.1 (Zed Preview)
OS: Linux X11 ubuntu 24.04
Memory: 15.3 GiB
Architecture: x86_64

If applicable, add mockups / screenshots to help explain present your vision of the feature

I would like Ctrl Alt G to work instantaneously similar to Shift Ctrl Alt G. Currently, this is not the case.

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

Sometimes when using the key combination Ctrl Alt G and reverse, the following error shows up, which indicates somewhere under the hood there is hard-coded mapping to MacOS keyboard layout.

Zed.log
2024-07-01T22:34:06-05:00 [INFO] ignoring macOS specific set_edited
2024-07-01T22:34:07-05:00 [INFO] ignoring macOS specific set_edited
@krstp krstp added admin read Pending admin review defect [core label] triage Maintainer needs to classify the issue labels Jul 2, 2024
@notpeter
Copy link
Contributor

notpeter commented Jul 2, 2024

Hi,

Looks like there is a default binds in the linux keymap for:

{
  "context": "Editor",
  "bindings": {
    "ctrl-alt-g b": "editor::ToggleGitBlame"
  }
}

Temporary work around, just paste the above into your keymap and set the value to null.

For context, this keybind is meant to emulate the VSCode GitLens extension keyboard binding for toggling git blame. This is the "chorded" variant of GitLens shortcuts which prefixes half a dozen commands with a common prefix (alt-cmd-g on Mac, ctrl-alt-g on Linux/Windows).

I think our Linux keybind could use some love here. The vscode and jetbrains defaults for find next/previous are F3/shift-F3 on Linux/Windows and cmd-g and cmd-shift-g for MacOS.

The ignoring macOS specific set_edited log line I believe is unrelated and effectively a TODO added in #12514.

@notpeter notpeter added linux keymap / key binding Feedback for keyboard shortcuts, key mapping, etc and removed triage Maintainer needs to classify the issue admin read Pending admin review labels Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect [core label] keymap / key binding Feedback for keyboard shortcuts, key mapping, etc linux
Projects
None yet
Development

No branches or pull requests

2 participants