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

Re: [PATCH] Include number of chars in zle unget mechanism in $PENDING calculation



Ok. How about a separate parameter that just returns kungetct?

My use case is disabling zsh-autosuggestions (https://github.com/zsh-
users/zsh-autosuggestions) while bracketed-paste-magic and other
widgets using zle -U are running. Ideally, I could just avoid fetching
a suggestion until $PENDING and this new param are zero.



On Tue, Feb 28, 2017 at 7:52 PM Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
wrote:
>
> Yeah, this was discussed (with identical patch) back in May 2016 in
> workers/38522.  It turned out not to have the desired effect so we
> didn't do anything with it.
>
> The question is whether it's useful to be able to tell that TTY read
> will not block, separately from whether ZLE has available input.
> There are cases where one might be invoking a tty read in the middle
> of a widget, before any of the "zle -U" pushback would be consumed.
>
> We'd also have to change the doc that says "where the shell is not able
> to get this information, this parameter will always have a value of zero."


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