[comp.os.coherent] A question on "less"...

marke@richs118.cpg.trs.reuter.com (Mark Ellis) (04/25/91)

"less" on Coherent seems to require one to hit the return key after
every command, unlike what I am used to on other OS's using "less".  Am
I missing something?

Thanks!

P.S.
Anyone seen a way to switch the "ctrl" & "caps lock" keys on the
keyboard under 
Coherent?  Several such pgms are around for DOS.  I suspect it would need to be
done in the keyboard driver, but maybe there is another solution?

gsm@mendelson.com (Geoffrey S. Mendelson) (04/26/91)

marke@richs118.cpg.trs.reuter.com (Mark Ellis) asks:
>
>"less" on Coherent seems to require one to hit the return key after
>every command, unlike what I am used to on other OS's using "less".  Am
>I missing something?
>
That's what happens if you try to port the UNIX version of less to Coherent.
RAW tty handling is a mixture of BSD and AT&T (system V). If you get a 
copy of less that has already been ported (I got mine from mwcbbs) it works
just fine.


-- 
Copyright (C) 1991, Geoffrey S. Mendelson.              All Rights Reserved.
Except for usenet followups, may not be reproduced without permsission. 
----------------------------------------------------------------------------
|  Geoffrey S. Mendelson  |  Computer Software Consulting    |    Dr.      |
|  (215) 242-8712         |  IBM Mainframes, Unix, PCs, Macs |    Who      |
|  gsm@mendelson.com      |                                  |    Fan  too!| 
----------------------------------------------------------------------------
|          WANTED:  PAL VIDEO TAPES (VHS or BETA) inquire within.          |
|                  Especialy "missing" Dr Who Episodes.                    |
---------------------------------------------------------------------------

shawn@jpradley.jpr.com (Shawn Blair) (05/02/91)

In article <1680@richsun.cpg.trs.reuter.com> richsun!marke writes:
>"less" on Coherent seems to require one to hit the return key after
>every command, unlike what I am used to on other OS's using "less".  Am
>I missing something?
>
I can't answer this question, but it brings up at least one of my own.  I
compiled less using ALL the new(er) libraries.  When I use less for my man
paging I get caret (^) symbols in place of underlines and bolds.  My consoles
is the basic ansi console.  Anybody have any ideas?  Does anybody else
experience this same thing?  


_______________________________________________________________________________
--      Shawn R. Blair   ~  shawn@jpr.com                                    --
--      ...murphy!jpradley!rpmc!{srblair!}shawn (hourly)                     -- 
--      uunet!sir-alan!admiral!rpmc!{srblair!}shawn (weekly)                 --

albani@cadlab.sublink.ORG (Lanfranco Albani) (05/07/91)

shawn@jpradley.jpr.com (Shawn Blair) writes:

>compiled less using ALL the new(er) libraries.  When I use less for my man
>paging I get caret (^) symbols in place of underlines and bolds.  My consoles
>is the basic ansi console.  Anybody have any ideas?  Does anybody else
>experience this same thing?  

less uses an enviroment variable LESS.  You must use the flag "u" (lowercase
U) to avoid the "invasion of the carets" on your screen.
BTW there are a LOT of flags... :-)

Bye, Lanfranco (from Italy)

-- 
Lanfranco Albani - CAD.LAB s.p.a., v. Stalingrado 45, Bologna, Italia
Email: (work:) albani@cadlab.sublink.org, (home:) bob@allan.sublink.org
Phone: (work:) ++39 (51) 371099, (home:) ++39 (51) 727372; 
Fax: ++39 (51) 366964 (work only), Fidonet: 2:332/401.4 (home only).

nlane@well.sf.ca.us (Nathan D. Lane) (05/10/91)

I experience the same problem withless - it uses the raw terminal interface,
rather than displaying control sequences.  Scat works properly.  I haven't
figured out how to fix less - it's a shame I can't use it for a man pager
because those carets sure mess things up.

-Nathan Lane
Digital Technology Service
Santa Barbara, CA

marke@richs118.cpg.trs.reuter.com (Mark Ellis) (05/13/91)

Set an environment variable as follows:

	LESS=u; export LESS

in your .profile to get rid of the caret symbols.

shawn@jpradley.jpr.com (Shawn Blair) (05/18/91)

In article <825@cadlab.sublink.ORG> albani@cadlab.sublink.ORG (Lanfranco Albani) writes:
>shawn@jpradley.jpr.com (Shawn Blair) writes:
>
>>compiled less using ALL the new(er) libraries.  When I use less for my man
>>paging I get caret (^) symbols in place of underlines and bolds.  My consoles
>>is the basic ansi console.  Anybody have any ideas?  Does anybody else
>>experience this same thing?  
>
>less uses an enviroment variable LESS.  You must use the flag "u" (lowercase
>U) to avoid the "invasion of the carets" on your screen.
>BTW there are a LOT of flags... :-)
>
Thanks to all those who responded to my less problem.  The 'u' flag resolved
the problem.  (And I've added a few other flags to the LESS environment
variable to 'pretty' things up.)  Thanks also to Glen Walker of Edmonton Canada
as well.  I have quoted his email message below for anyone else interested.
Seems there is a fix to the program itself that will correct this problem too.
I haven't tried it yet, but I will soon.

From Glen Walker <9105151817.AA1281.V2.20.escort@>
>I had the same problem with the carets.  This fix is really simple.
>In the file output.c, in the funtion put_line(), there is a variable
>declared as:
>        register char *p;
>change that to
>        register unsigned char *p;
>and all will be well.
> 
>The problem is that the code in put_line() assumes that *p is an
>unsigned value. The code uses the MSB of the character as a flag for
>character highlighting and underlining etc.
>
>Of course, you need to have /etc/termcap set up for bold, and underlining.
>For the console (or vt-100) I added:
>
>        md=\E[1m:me=\E[m:       --- this for bold start, bold end
>        us=\E[4m:ue=\E[m:       --- for underlining.
>
>If you don't define the md/me pair less uses the so/se pair (often
>reverse video). This can make for a very gaudy man page.
>Hope this helps.
>
Well, maybe this will make a difference for someone else as well.  Thanks again
for all the input.  See you on the net!

Shawn
--
>Bye, Lanfranco (from Italy)
>
>-- 
>Lanfranco Albani - CAD.LAB s.p.a., v. Stalingrado 45, Bologna, Italia
>Email: (work:) albani@cadlab.sublink.org, (home:) bob@allan.sublink.org
>Phone: (work:) ++39 (51) 371099, (home:) ++39 (51) 727372; 
>Fax: ++39 (51) 366964 (work only), Fidonet: 2:332/401.4 (home only).



_______________________________________________________________________________
--      Shawn R. Blair   ~  shawn@jpr.com                                    --
--      ...murphy!jpradley!rpmc!{srblair!}shawn (hourly)                     -- 
--      uunet!sir-alan!admiral!rpmc!{srblair!}shawn (weekly)                 --