From owner-freebsd-questions Thu Mar 7 13:47: 7 2002 Delivered-To: freebsd-questions@freebsd.org Received: from rutger.owt.com (rutger.owt.com [204.118.6.16]) by hub.freebsd.org (Postfix) with ESMTP id A6E5437B41A for ; Thu, 7 Mar 2002 13:46:56 -0800 (PST) Received: from owt.com (owt-207-41-94-232.owt.com [207.41.94.232]) by rutger.owt.com (8.9.3/8.9.3) with ESMTP id NAA01858; Thu, 7 Mar 2002 13:46:52 -0800 Message-ID: <3C87DFCA.9010400@owt.com> Date: Thu, 07 Mar 2002 13:46:50 -0800 From: Kent Stewart User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.4) Gecko/20011128 Netscape6/6.2.1 X-Accept-Language: en-us, es-mx MIME-Version: 1.0 To: Cliff Sarginson Cc: freebsd-questions@FreeBSD.ORG Subject: Re: vi question References: <20020307210508.GB484@raggedclown.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Cliff Sarginson wrote: > On Thu, Mar 07, 2002 at 02:34:51PM -0600, Bob Giesen wrote: > >>On Thursday 07 March 2002 01:11 pm, Seth Hieronymus wrote: >> >>>Is there any way to stop vi from going back into command mode when >>>I arrow over to the first column (while in insert mode)? >>> >> I don't think so. You could use Vim, instead; this seems to work >>as you'd like it to. >> More to the point is that you're using arrow keys in vi, which is >>optimized for fast typing (little wasted motion and little need for >>Ctrl- or Alt-key combinations). Personally, I find it faster to just >>switch between command and insert modes and use the h,j,k, and l keys >>instead of the arrow keys... Ymmv, of course, but you might want to >>give it a chance, if you haven't already. >> >> > Mmm, this is one of the mysteries of vi. > The arrow keys *may* work, they do for me, on most of the computers > I use. It depends on terminal type, terminal emulation, and the > position of the stars. > > But on some systems, they exhibit the behaviour you mention. > > This has to do with the character. > The brings you back to command mode as you know. > is also the "lead-in" character for "escape-sequences" > the left arrow for example is: > ^[[D > > ^[ = . > > Now vi should wait a little while to see if is just or > whether it is a lead in to an escape sequence..which of course happens > very fast, so the wait only has to be very short. However sometimes vi > just does not seem to wait long enough. We used to have a Cray where I worked and it wasn't the sequence that did it as much as the repeat key frequency on the computer editing the file. We felt the computer was seeing multiple in a row because of the repeat key behaviour and an arrow command butchered arrow command dropped vi into command mode. Kent > > Because of this oddity most "vi veterans" use the keyboard movement keys > and just switch mode as a matter of habit...because this will always > work. > > As mentioned above I don't think other vi clones suffer from this > abberation, try them (vim or nvi). > > You see "vi" is not a screen editor, it is a front end into a > line-editor; this upsets people used to "real" screen editors. > > -- Kent Stewart Richland, WA http://users.owt.com/kstewart/index.html To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message