Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Are completions in some way heavy?

On Jun 10,  2:22pm, Sebastian Gniazdowski wrote:
} > I think Sebastian wants to search through the descriptions, whereas
} > the complist search only examines the completions themselves.
} It searches through descriptions of options. Quite nice thing.

Hmm, indeed it does.  It only highlights the option, not the matched
search string, which is probably OK.  I didn't realize this worked
any differently than "interactive" in this respect (see below).

} zstyle ':completion:*:*:*:default' menu yes select search

Hmm again.  Seems to work inconsistently, with e.g.

    zstyle ':completion:*' menu 'yes=long' 'select=9' search

Sometimes I have to press TAB twice to enter incremental search, other
times it starts the search immediately so a second TAB exits from the
search again (though not all the way out of the menu).

} Don't know yet how to cycle through matches,

You have to bind a key in the menuselect keymap, e.g.,

    bindkey -M menuselect ^S history-incremental-search-forward
    bindkey -M menuselect ^R history-incremental-search-backward

If I ever knew why that isn't bound by default, I've forgotten.  It
probably should copy the bindings from the main keymap.

} would like to leave completion on space

    bindkey -M menuselect ' ' accept-line

(But then you can't search the descriptions for multiple word phrases.)

} don't get what "interactive" mode is.

It's like search, except instead of displaying the whole menu and
searching through it, the list of possible matches is narrowed down
as you type.  THIS mode definitely does NOT search descriptions, and
if both interactive and search are specified, interactive wins.

Messages sorted by: Reverse Date, Date, Thread, Author