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

Suggestions not cleared for menu-select widget #747

Open
Squirreljetpack opened this issue Jun 26, 2023 · 0 comments
Open

Suggestions not cleared for menu-select widget #747

Squirreljetpack opened this issue Jun 26, 2023 · 0 comments
Labels

Comments

@Squirreljetpack
Copy link

Describe the bug

Autosuggestions is not cleared even if menu-select is added to ZSH_AUTOSUGGEST_CLEAR_WIDGETS

To Reproduce

ZSH_AUTOSUGGEST_CLEAR_WIDGETS=(
'history-search-forward'
'history-search-backward'
'history-beginning-search-forward'
'history-beginning-search-backward'
'history-substring-search-up'
'history-substring-search-down'
'up-line-or-beginning-search'
'down-line-or-beginning-search'
'up-line-or-history'
'down-line-or-history'
'accept-line'
'copy-earlier-word'
'menu-select'
)
bindkey '^I' menu-select
Menu looks wonky

Expected behavior

Autosuggestion is cleared after menu-select

Desktop

  • OS + distribution: Arch linux
  • Zsh version: 5.9
  • Plugin version: latest

Additional context

Workaround:
ZSH_AUTOSUGGEST_CLEAR_WIDGETS=(
'history-search-forward'
'history-search-backward'
'history-beginning-search-forward'
'history-beginning-search-backward'
'history-substring-search-up'
'history-substring-search-down'
'up-line-or-beginning-search'
'down-line-or-beginning-search'
'up-line-or-history'
'down-line-or-history'
'accept-line'
'copy-earlier-word'
'do_nothing'
)
function do_nothing() {
}
zle -N do_nothing

function custom-menu-select() {
zle do_nothing
zle menu-select
}
zle -N custom-menu-select
bindkey '^I' custom-menu-select

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant