🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.editors
Article #2695

Re: Question on tab stops in vi (how to map tab to ^V)

#2695
From: Ian Phillipps
Date: Fri, 24 May 1991 16:30
24 lines
1209 bytes
asylvain@felix.UUCP (Alvin "the Chipmunk" Sylvain) writes:

>Written in article <1991May09.190644.13627@Kesa.COM>
>    by jerry@Kesa.COM (Jerry E. Dunmire):

>>    Is there a way to get a 4 space indent in vi without changing tab stops?
>> 
>>    I've tried re-mapping the tab key, but without any luck.

>What you want is a shift-width of 4.  (:set sw=4)

>Then, when entering your input, instead of hitting "tab", you hit
>Control-T (^T).

>No, I'm sorry, you can _not_ map the "tab" into ^T.  I've tried, and it 
>won't work.

Yes you can! You need a few extra Ctrl-Vs. Type in

:map! ^V^V^V^I ^V^T

and it works. What this monstrosity looks like in a .exrc, I've not tested.

Ian
Technical Details
Message-ID: <1991May24.163037.24150@unipalm.uucp>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!mcsun!ukc!acorn!unipalm!ian
References: <1991May09.190644.13627@Kesa.COM> <163509@felix.UUCP>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!mcsun!ukc!acorn!unipalm!ian
From: ian@unipalm.uucp (Ian Phillipps)
Newsgroups: comp.editors
Subject: Re: Question on tab stops in vi (how to map tab to ^V)
Keywords: vi tabs
Message-ID: <1991May24.163037.24150@unipalm.uucp>
Date: 24 May 91 16:30:37 GMT
References: <1991May09.190644.13627@Kesa.COM> <163509@felix.UUCP>
Distribution: comp
Organization: Unipalm Ltd., Cambridge, England
Lines: 24