[unix-pc.general] vi missing commands on 3b1

psfales@cbnewsc.ATT.COM (Peter Fales) (09/15/89)

In article <15580@duke.cs.duke.edu>, pusateri@romeo.cs.duke.edu (Thomas J. Pusateri) writes:
> Does anyone know why ctrl-^ doesn't work with the unix-pc 3.51 version of vi?
> Once you specify an alternate file to edit, it is supposed to switch back
> and forth between the two files. It works fine on every other System V and
> BSD version of vi I have ever used, but for some reason it has been
> disabled on the unix-pc.

I believe the problem here is not vi, but the way that characters are mapped
to the keyboard.  Holding down shift, control, and the "6" key does not
send a ctrl-^ character.  IMHO this is wrong, however 
I have spoken to the person at AT&T who does the kernel updates and he 
doesn't want to make a change here because the current keycodes for 
ctrl-shift-^ and ctrl-shift-_ are documented.  With the stock kernel, 
there is not even a way to generate the characters with ASCII values
0x1e or 0x1f from the keyboard.  The "fixdisk" currently
under development will be able to generate these codes from the keyboard
using a different key combination (such as ctrl-period). 
As an alternative, you can run the  keyfix.c program posted by Michael 
Ditto some time back.

> Also I have noticed that I cannot directly enter a '@' character on the
> unix-pc version of vi. I have to enter a ^V first and then the '@ character.
> Who's been adding features (?) to vi?

Have you changed your "kill" character?  The default unix line kill 
character is @ and if you haven't changed it using "stty" vi will use
it for the same purpose.

-- 
Peter Fales			AT&T, Room 5B-420
				2000 N. Naperville Rd.
UUCP:	...att!peter.fales	Naperville, IL 60566
Domain: peter.fales@att.com	work:	(312) 979-8031

gst@gnosys.UUCP (Gary S. Trujillo) (09/16/89)

In article <3192@cbnewsc.ATT.COM> psfales@cbnewsc.ATT.COM (Peter Fales) writes:
> In article <15580@duke.cs.duke.edu>, pusateri@romeo.cs.duke.edu (Thomas J. Pusateri) writes:
> > Does anyone know why ctrl-^ doesn't work with the unix-pc 3.51 version of vi?
> I believe the problem here is not vi, but the way that characters are mapped
> to the keyboard.  Holding down shift, control, and the "6" key does not
> send a ctrl-^ character...

Yeah.  Shift-ctrl-6 generates ESC-P-f (as does just ctrl-6).  However, you
can easily use vi's "map" command to cause ctrl-6 to do what you want:

	map ^[Pf :e #^M

I tried it and it worked just fine.

(You'll have to use ^V to enter the ctrl-6 and ^M characters into your ~/.exrc
file.)

-- 
Gary S. Trujillo			      {linus,bbn,m2c}!spdcc!gnosys!gst
Somerville, Massachusetts		      {ima,stech,wjh12,cdp}!gnosys!gst

bob@rush.cts.com (Bob Ames) (09/17/89)

In article <352@gnosys.UUCP> gst@gnosys.UUCP (Gary S. Trujillo) writes:
>In article <3192@cbnewsc.ATT.COM> psfales@cbnewsc.ATT.COM (Peter Fales) writes:
>> In article <15580@duke.cs.duke.edu>, pusateri@romeo.cs.duke.edu (Thomas J. Pusateri) writes:
>> > Does anyone know why ctrl-^ doesn't work with the unix-pc 3.51 version of vi?
>> I believe the problem here is not vi, but the way that characters are mapped
>> to the keyboard.  Holding down shift, control, and the "6" key does not
>> send a ctrl-^ character...
>
>Yeah.  Shift-ctrl-6 generates ESC-P-f (as does just ctrl-6).  However, you
>can easily use vi's "map" command to cause ctrl-6 to do what you want:
>
>	map ^[Pf :e #^M
>
>I tried it and it worked just fine.
>
>(You'll have to use ^V to enter the ctrl-6 and ^M characters into your ~/.exrc
>file.)

I`ve recently installed Mike Ditto`s keyfix and nkbd.  My Shift-ctrl-6 works!!
This allows you to generate most any of the 255 ascii characters from your
unixpc console.

I got these from manta.pha.pa.us, who allows anonymous UUCP.
This line goes in your /usr/lib/uucp/L.sys or /usr/lib/uucp/Systems file:
manta Any ACU 1200 12156625301 "" \d in:--in: uupub assword: UUsnarf
$ uucp manta!/usr/spool/pub/index /usr/spool/uucppublic/mantaindex

Mike made reference to possible future enhancements...  What would it take
to switch the functions of the left ctrl and caps-lock keys?  I.E. to make
the 'Caps Lock' key function as the Meta key and the left ctrl key function
as the control key...

Bob
---
Bob Ames   The National Organization for  the Reform of Marijuana Laws, NORML 
"Pot is the world's best source of complete protein, alcohol fuel, and paper,
is the best fire de-erosion seed, and is america's largest cash crop." - USDA
bob@rush.cts.com or ncr-sd!rush!bob@nosc.mil  or rutgers!ucsd!ncr-sd!rush!bob
619-432-6106 "We each pay a fabulous price for our visions of paradise," Rush