[Date Prev][Date Next][Subject Prev][Subject Next][
Date Index][
Subject Index]
Re: Automated Clean-up of Ragged Text ?
- Subject: Re: Automated Clean-up of Ragged Text ?
- From: cld@xxxxxxxx (Carl Distefano)
- Date: Thu, 2 Nov 2000 01:30:04 -0500 (EST)
Reply to note from "R Tennenbaum" Wed, 01
Nov 2000 22:13:42 -0500 (EST)
-> ... a quick keyboard routine:
->
-> bc,c,h,cr,/,/,/,cl,cl,NOJM,2,.,P,u,t,D,F,-,C,M,Q2,cr
->
-> If I define a big chunk of spaces from the l.-hand margin over
-> to the first word, then hit the key to which I've attached the
-> above, what I get is
->
-> ch / //
->
-> which I can execute to rid of all them spaces.
Rafe:
The easiest way to craft CHange commands using DeFined text is with a
routine called CHDF and its relations CHADF, CIDF, CIADF, CVDF, CVADF,
SEDF, SEBDF, and SEBADF. The usage is to DeFine the text you want to
change and then issue:
CHDF newstring
All occurrences of the DeFined text, from cursor position to bottom of
file, will be immediately changed to newstring. All switches
applicable to the native CH and CV commands (except, of course, /S to
operate on Selected [DeFined] text) can be used. CHDF/T
newstring to change from Top of File regardless of cursor
position, CHDF/W to change whole words only, etc. A useful variant is
to omit newstring; in this case, all instances of the DeFined text are
replaced with nothing (i.e., are deleted). Very handy.
The related routines are, I think, self-explanatory. CHADF or CIADF
for case-absolute changes, CVDF and CVADF for Change-Verify and
Change-Verify case-absolute, and SEDF, SEBDF, and SEBADF to search for
other occurrences of DeFined text.
Although these routines are listed in the Index, I never got around to
writing a Help screen for them, so they're easy to overlook.
--
Carl Distefano
cld@xxxxxxxx
http://users.datarealm.com/xywwweb/