[Date Prev][Date Next][Subject Prev][Subject Next][
Date Index][
Subject Index]
Flushing the delete buffer (WAS: pgm leaks code into text)
- Subject: Flushing the delete buffer (WAS: pgm leaks code into text)
- From: TBaehr TBaehr@xxxxxxxx
- Date: Mon, 19 Jan 1998 21:42:49 EST
Annie wrote, as a way to flush the delete buffer:
≪ {sv86,GT XD DF DF RD XD } ≫
I don't think you need the last XD, since RD gets rid of it, even in XyIII.
One good refinement might be to put a similar program on the key that does RD.
It would do the following:
RD -- then open or go to a scratch file (code could be tricky there), do a BF
to get to the bottom, put in a carriage return, do an undelete to get the
deleted text out of the buffer, do DF DF RD to flush the buffer, and then do
AS to get back to the original text.
You could also do the whole thing blind with the APPEND command:
Define text; APPEND it to a pre-established scratch file; RD DF DF RD.
In either case you end up with a slush bucket file of deleted scraps.
Undeleting something could be messy (Define, Copy to a Save/Get, AS PV the
Save/Get), but it would all be there. Periodic housekeeping would be necessary
to keep the scratch file from overrunning the hard drive.
I could imagine more elegant and complete versions of this, and maybe someday
I'll write one....
Tim Baehr
TBaehr@xxxxxxxx