Re: Disabling Undo temporarily
- On 05/30/01 (Wed) at 09:38:52, Preben Guldberg wrote:
> Thus wrote pcp (da.box@...) on :you have a point =)...
> > Yes but this clears the undo buffer so i can't undo other edits
> Not before ":set ul=-1", no.
> But how would you expect undo to work (properly) if it has no idea
> what might have changed in the meantime? As a quick example on a
> buffer with three lines:
> First line
> Second line
> Third line
> Now do, from the F in the first line
> This is a simple command that can be undone by issuing the very same
> Then disable undo, delete first line and restore 'undolevel'
> :se ul=-1|1d|se ul&
> So if you hit "u" now, should vim go to the first line (where the
> latest "known" change happened) and issue "g~3e"?
> Peppe [not what I would expect]
> "Before you criticize someone, walk
> Preben "Peppe" Guldberg __/-\__ a mile in his shoes. That way, if
> c928400@... (o o) he gets angry, he'll be a mile away
> ----------------------oOOo (_) oOOo-- - and barefoot." --Sarah Jackson
* Name: Nikolai Weibull
* Nicks: pcp, pcppopper
* System: Midi ATX, ASUS CUV4X, Celeron 667@950, GeForce2 MX 32,
* 256mb PC133, Fujitsu 20.49gb UDMA-66
* E-Mail: da.box@..., pcp@...
* E-Location: www.pcppopper.org