浏览代码

widget binding: don't exclude widgets starting with '_'

Just because a widget starts with _ does not mean it should be
skipped when rebinding. The only reason widgets need to be skipped
is when their function name start with _zsh_highlight_widget*,
which is checked later.

Example:
_expand_alias (^Xa) needs to be wrapped.

The exclusion of _* was introduced in 186d80054a
to fix #65, but it is not needed. The relevant exclusion of
_zsh_highlight_widget* is already enough due to the case statement.
pull/255/head
m0viefreak 8 年前
父节点
当前提交
ed33d2cb13
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      zsh-syntax-highlighting.zsh

+ 1
- 1
zsh-syntax-highlighting.zsh 查看文件

@ -200,7 +200,7 @@ _zsh_highlight_bind_widgets()
# Override ZLE widgets to make them invoke _zsh_highlight.
local cur_widget
for cur_widget in ${${(f)"$(builtin zle -la)"}:#(.*|_*|orig-*|run-help|which-command|beep|set-local-history|yank)}; do
for cur_widget in ${${(f)"$(builtin zle -la)"}:#(.*|orig-*|run-help|which-command|beep|set-local-history|yank)}; do
case $widgets[$cur_widget] in
# Already rebound event: do nothing.

正在加载...
取消
保存