[comp.sys.ibm.pc] MKS VI bugs ?? still??

jcb@loral.UUCP (Jay C. Bowden) (03/14/89)

I just got the latest release of MKS Toolkit ( i.e. I paid for
an upgrade), and I was disappointed that there were STILL the
same bugs in vi.  I had assumed that the bugs I was seeing were
due to not having the latest version....

Maybe they are not bugs at all, and I am just using it wrong,
somehow.  Clues, anyone?  Here are my probs:

If I backspace in INSERT mode (with control-H; does that make
any difference?), I delete NOT ONLY the character I typed last,
but ALSO delete one character out of the original line for
each backspace I do!

And I cannot insert a "@" character into a line at all!  The 
@ seems to delete to start of line, even in insert mode.


It is hard to believe that these are "bugs" really there in this
product, at this stage!  What am I doing wrong?

I love it otherwise, because of all the ex commands it runs
PERFECTLY!  Like ".,'as/^/    /"

And :r !dir

Yes, it's probably something in need in my ex.rc, isn't it?

Any help is appreciated!

- Jay


------------------------------------------------------------------
Jay Bowden, EE/Consultant; see also Bowden Engineering
Currently contracted at Loral Instrumentation, San Diego
{ucbvax, ittvax!dcdwest, akgua, decvax, ihnp4}!ucsd!loral!jcb


-- 
------------------------------------------------------------------
Jay Bowden, EE/Consultant; see also Bowden Engineering
Currently contracted at Loral Instrumentation, San Diego
{ucbvax, ittvax!dcdwest, akgua, decvax, ihnp4}!ucsd!loral!jcb

johnk@grebyn.COM (John Kennedy) (03/15/89)

In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
>And I cannot insert a "@" character into a line at all!  The 
>@ seems to delete to start of line, even in insert mode.
>- Jay
>

Try escaping the @ sign with a ctrl-v.  It works on my MKS vi.


-- 
John Kennedy            |        Second Source, Inc.
johnk@opel.UUCP         |        Annapolis, MD

wnp@killer.Dallas.TX.US (Wolf Paul) (03/15/89)

In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
>Maybe they are not bugs at all, and I am just using it wrong,
>somehow.  Clues, anyone?  Here are my probs:
>
>If I backspace in INSERT mode (with control-H; does that make
>any difference?), I delete NOT ONLY the character I typed last,
>but ALSO delete one character out of the original line for
>each backspace I do!

That one bit me too, until I got used to it; now I find it annoying
that UNIX vi won't do the same thing.

>And I cannot insert a "@" character into a line at all!  The 
>@ seems to delete to start of line, even in insert mode.

I think that is consistent with UNIX. Vi starts out with @ as the
"line erase" character, and then checks to see if you changed it by means
of "stty". Since this information is not available in a DOS environment,
it never gets changed in the running Vi.

I insert the @ character by preceding it with a back slash ('\'),
and while it is an extra keystroke, one does get used to it.

>It is hard to believe that these are "bugs" really there in this
>product, at this stage!  What am I doing wrong?

Well, it depends on your interpretation of "bugs". The second one,
at least, is really an "implementation difference". There are some things
UNIX utilities expect to find which just aren't there under DOS. How to
deal with these things -- well, different people have different ideas
on that subject. The folks at MKS implemented _their_ ideas 'coz that's
all they had to go by. If enough of their customers complain (in a
nice and polite fashing, mind you -- I am not advocating a flame fest :-))
they will probably consider changing the way certain things are done.

>I love it otherwise, because of all the ex commands it runs

And it really does make the transition from DOS to UNIX and back much easier!
It's a great product.

Wolf
-- 
Wolf N. Paul * 3387 Sam Rayburn Run * Carrollton TX 75007 * (214) 306-9101
UUCP:   killer!wnp                    ESL: 62832882
DOMAIN: wnp@killer.dallas.tx.us       TLX: 910-380-0585 EES PLANO UD

erlebach@turing.toronto.edu (Beverly Erlebacher) (03/15/89)

In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
>
>And I cannot insert a "@" character into a line at all!  The 
>@ seems to delete to start of line, even in insert mode.

I wrote to MKS about this problem last fall and got the following reply.
(I think it's ok to post it since it is certainly not confidential and
is real 'from-the-horse's-mouth' accurate info!)  I did as suggested and
it worked with no problems.  MKS gives very good tech support.

| Date:	Fri, 23 Sep 88 13:55:04 EDT
| From:	mks!wheels@watmath (Gerry Wheeler)
| Subject: re: '@' in vi
| 
| If you start up vi, and look at the list of settings with the ":set all"
| command, you will see one called "linedelete".  By default it is set to
| 0x0040, which is the @ character.  You can change it to whatever you
| like with a command like ":set linedelete 0x0040".  In fact, if you
| don't want it at all you could set it to 0x0000, which is not something
| you're likely to type.  (I guess 0xffff would be similar.) Once you find
| a setting you like, you can put the set command into the ex.rc
| initialisation file. 
|  --
|      Gerry Wheeler                           Phone: (519)884-2251
| Mortice Kern Systems Inc.               UUCP: uunet!watmath!mks!wheels
|    35 King St. North                             BIX: join mks
| Waterloo, Ontario  N2J 2W9                  CompuServe: 73260,1043
| 
| 

gm@romeo.cs.duke.edu (Greg McGary) (03/16/89)

In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
>And I cannot insert a "@" character into a line at all!  The 
>@ seems to delete to start of line, even in insert mode.

MKS vi sets @ as the default line-kill character.
You can fix this by putting the following in your ex.rc:

set linedelete=0x15

This sets the line-kill character to the more common CTRL-U.
Of course, you can set this to be anything you want, just use the
appropriate ascii code (in decimal, octal or hex).

-- Greg McGary
-- 4201 University Drive #102, Durham, NC 27707       voice: (919) 490-6037
-- {decvax,hplabs,seismo,mcnc}!duke!gm                 data: (919) 493-5953
--                                  gm@cs.duke.edu

dr@skivs.UUCP (David Robins) (03/16/89)

In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
>I just got the latest release of MKS Toolkit ( i.e. I paid for
>an upgrade), and I was disappointed that there were STILL the
>same bugs in vi.  I had assumed that the bugs I was seeing were
>due to not having the latest version....
....
>And I cannot insert a "@" character into a line at all!  The 
>@ seems to delete to start of line, even in insert mode.

The @ symbol is the start of a macro command in the MKS vi.  To insert
the @, you have to preceed it with an escape character, the "\" (backslash).
I was stumped also, til I emailed something to MKS, and got a response
from Gary Wheeler.
-- 
David Robins, M.D.  (ophthalmologist / electronics engineer)
The Smith-Kettlewell Institute of Visual Science,  ***  net:  uunet!skivs!dr
2232 Webster St, San Francisco CA 94115            ***  415/561-1705 (voice) 
The opinions expressed herein do not reflect the opinion of the Institute!

wkb@cbnews.ATT.COM (Wm. Keith Brummett) (03/16/89)

    In article <1921@loral.UUCP>, jcb@loral.UUCP (Jay C. Bowden) writes:

    > I just got the latest release of MKS Toolkit ...
    > 
    > And I cannot insert a "@" character into a line at all!  The 
    > @ seems to delete to start of line, even in insert mode.

    Although a couple of people have mentioned that one can change the
    default line-kill character to something other than "@", no one seems to
    have mentioned that you merely have to escape it with a "\" when in the
    insert/append mode.  This works on a Unix(R) system also.  (In fact, I
    just used it in this posting.)  E.g., to insert the string "abc@xyz"
    into a file, you enter "abc\@xyz" while in insert/append mode.  The "\"
    disappears when you enter the "@", and you are left with the string that
    you want.  Is simple, n'est pas?

-- 
    | Wm. Keith Brummett         (614) 860-3187          AT&T, Room 2B-252 |
    | att!cbnews!wkb               Cornet 353          6200 East Broad St. |
    | or, wkb@cbnews.ATT.COM                       Columbus, OH 43213-1550 |
    `----------------------------------------------------------------------'

kiy@pte.UUCP (Kevin Young) (03/21/89)

In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
>
>If I backspace in INSERT mode (with control-H; does that make
>any difference?), I delete NOT ONLY the character I typed last,
>but ALSO delete one character out of the original line for
>each backspace I do!

I have not experienced this with MKS vi.  I do know that, unlike some 
versions of vi, the MKS version will allow you to backspace beyond your
starting point.

>And I cannot insert a "@" character into a line at all!  The 
>@ seems to delete to start of line, even in insert mode.

The '@' character is the UNIX delete-line character and has the same
effect in vi.  To enter characters which have special editting functions,
be sure to precede them with the '\' character.  

>Jay Bowden, EE/Consultant; see also Bowden Engineering
>Currently contracted at Loral Instrumentation, San Diego
>{ucbvax, ittvax!dcdwest, akgua, decvax, ihnp4}!ucsd!loral!jcb

MKS vi still does have a few other bugs.  Specifically, when editting a
file with more than 256 lines and doing excessive moves and deletes,
sometimes the first line of the file gets replicated randomly all over
your text.  MKS has been working on this elusive bug for some time.
Still, MKS vi is an outstanding tool!
Kevin

-- 
>|< Kevin I Young					uunet!edsews!pte!kiy
    Precise Technology & Electronics, Inc.
    Custom Automated Test and Measurement Equipment for Industry
    Old Saying: "Try not. Do, or do not. There is no try." - yoda

brown@nicmad.UUCP (Vidiot) (03/21/89)

In article <11891@grebyn.COM> johnk@opel.UUCP (John Kennedy) writes:
<In article <1921@loral.UUCP> jcb@loral.UUCP (Jay C. Bowden) writes:
<>And I cannot insert a "@" character into a line at all!  The 
<>@ seems to delete to start of line, even in insert mode.
<>- Jay
<>
<
<Try escaping the @ sign with a ctrl-v.  It works on my MKS vi.

I have the following ex.rc file which lets the @ character work as a character:


set 8bits
set native
set dir=c:/tmp
set linedelete=0x15
set scrupdate=1


Also, be sure and set the HOME and ROOTDIR environment variables.

As for the insert/backspace problem, you're right, it does allow you to
backspace further than the number of characters that you had inserted.  I just
never noticed that before.
-- 
	       harvard-\	 att--\
Vidiot            ucbvax!uwvax!astroatc!nicmad!brown
	       rutgers-/      decvax--/
	ARPA/INTERNET: nicmad!brown%astroatc.UUCP@spool.cs.wisc.edu