Article View: comp.editors
Article #2484Re: Arbitrary text blocks (Was: VI??? GROSS!)
From: DWT
Date: Wed, 18 Nov 1992 03:31
Date: Wed, 18 Nov 1992 03:31
24 lines
1698 bytes
1698 bytes
hjiwa@gruc19.nor.chevron.com (Jeff Wang) wrote in <1992Nov17.005252@gruc19.nor.chevron.com>: W> bvaughan@sheps.Princeton.EDU (Barbara Vaughan) writes: V> I also found this feature useful when writing programs. Let's say I have V> a section of code I decide to make conditional, so I want to indent it to V> make an "if.. then.." block. I just insert a column of blanks in front of V> that section of code. W> You could use :'a,'bs/^/ / to shift a block to the right. If you want to indent it by one shiftwidth -- and it doesn't make much sense to set shiftwidth to any other value than your indentation increment -- you can use :'a,'b> in vi. Heck, don't even mark the range: move to the top and :.,/^$/-1> Oh, belay that. Just do }> and you've indented the rest of the paragraph. None of these suggestions require shelling out to fork another program. }> doesn't even need a switch to ex mode. David W. Tamkin Box 59297 Northtown Station, Illinois 60659-0297 dattier@ddsw1.mcs.com CompuServe: 73720,1570 MCI Mail: 426-1818
Technical Details
Message-ID:
<Bxw75B.1wM@ddsw1.mcs.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!ames!saimiri.primate.wisc.edu!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uchinews!machine!ddsw1!dattierReferences:
<1992Nov16.221338.42264@datamark.co.nz> <1992Nov17.145011.24541@Princeton.EDU> <1992Nov17.005252@gruc19.nor.chevron.com>Show Full Headers
Complete Article Headers
Newsgroups: comp.editors Path: arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!ames!saimiri.primate.wisc.edu!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uchinews!machine!ddsw1!dattier From: dattier@ddsw1.mcs.com (DWT) Subject: Re: Arbitrary text blocks (Was: VI??? GROSS!) Message-ID: <Bxw75B.1wM@ddsw1.mcs.com> Date: Wed, 18 Nov 1992 03:31:59 GMT References: <1992Nov16.221338.42264@datamark.co.nz> <1992Nov17.145011.24541@Princeton.EDU> <1992Nov17.005252@gruc19.nor.chevron.com> Organization: Contributor Account at ddsw1, Chicago, Illinois 60657 Lines: 24