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

Re: PATCH: narrow-to-region



"Bart Schaefer" wrote:
> Maybe I'm missing something, but was all that really necessary?
> 
> Seems like all that's needed is a test for whether a recursive edit is in
> progress, and then `widen' can be function that does an accept-line when 
> recursively editing and feeps (or does nothing) otherwise.

There's no way otherwise to tell zle to run a function within the
narrowed region, since control goes straight back to the user via the
recursive edit.  The example function is a bit useless, since it just
does a recursive-edit anyway, but in most cases there'll be something
more at that point.  An alternative, instead of -S and -R, would have
been to pass in a function to run on the narrowed region in place of
`zle recursive-edit'.  Unless you can see how to do it some other way.

-- 
Peter Stephenson <pws@xxxxxxx>                  Software Engineer
CSR Ltd., Science Park, Milton Road,
Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 392070


**********************************************************************
The information transmitted is intended only for the person or
entity to which it is addressed and may contain confidential 
and/or privileged material. 
Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by 
persons or entities other than the intended recipient is 
prohibited.  
If you received this in error, please contact the sender and 
delete the material from any computer.
**********************************************************************



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