Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-04 Thread Harry Putnam
Oscar del Rio  writes:

> On 04/ 3/14 11:44 PM, Harry Putnam wrote:
>> However, it was not the variable PERLDOC_PAGER that did the trick but the
>> variable PAGER is where applying -r to less did the job.
>
> From "perldoc perldoc":
>
>  "perldoc" will use, in order of preference, the pager
>  defined in "PERLDOC_PAGER", "MANPAGER", or "PAGER" before
>  trying to find a pager on its own.

Thanks, yeah, I had assumed... once I noticed it worked on PAGER but
not on PERLDOC_PAGER that there was some kind of pecking order
involved.


___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-04 Thread Oscar del Rio


On 04/ 3/14 11:44 PM, Harry Putnam wrote:

However, it was not the variable PERLDOC_PAGER that did the trick but the
variable PAGER is where applying -r to less did the job.


From "perldoc perldoc":

 "perldoc" will use, in order of preference, the pager
 defined in "PERLDOC_PAGER", "MANPAGER", or "PAGER" before
 trying to find a pager on its own.


___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread Harry Putnam
James Carlson  writes:

> On 04/03/14 14:28, Harry Putnam wrote:
>> ESC[1mNAMEESC[0m
>>  Cwd − get pathname of current working directory
>
> At a guess, your TERM setting doesn't match the actual terminal emulator
> you're using.
>
> There are many terminal emulators around -- including an extended vt102
> emulator built into xterm, emulators built into various Windows
> applications, and so on.  It would help if you could provide precise
> details on how you're connecting *to* your system and how you're
> displaying the results.

It appears that Alexander P has provided the help needed... adding -r
to less switches.

I'm logged in at the oi terminal

My emulater is /usr/bin/xterm

  echo $TERM
  xterm

> I would expect you get different results depending on how you connect
> (e.g., Putty on Windows versus actual OI console running an xterm).

Thanks for the helpful input... yes I should have known to include
info about the terminal.

Yes, the first two you mention and including ssh from linux running
xterm, all work as expected... that is, no control char in perldoc
output.

It was only logged in at oi terminal running X and xterm, that showed
the problem.

Now apparently cured by adding -r switch to less.

However, it was not the variable PERLDOC_PAGER that did the trick but the
variable PAGER is where applying -r to less did the job.



___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread Harry Putnam
Alexander Pyhalov  writes:


[...]

> Hello.
> A bit of googling gives
>
> export PERLDOC_PAGER='less -r'


I was too hasty in my response.  I said it had no effect for me.  And
that it is true the line above does not help here.

However, if I apply your tip to PAGER instead of PERLDOC_PAGER then it
clears things right up.

PAGER was already set to 'less -ins' .  I don't recall now where I got
that bit of advice.

But changing it to `export "PAGER=less -rins"'  has cleared things
right up.

Apparently the -r makes less display control char as 'raw' control
char, and somehow that makes the display work.


___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread Harry Putnam
Alexander Pyhalov  writes:

> Harry Putnam писал 03.04.2014 22:28:
>> Running 151_a8 as guest in vbox vm on win 7 host
>>
>> I get esc sequences in perldoc output that makes it hard to read.  A
>> small sample is included at the end.
>>
>> I vaguely remember having to make some kind of LANG or related
>> variable adjustment in the past for this problem...
>>
>> But cannot remember now what was done.
>>
>> I am using less as pager.
>>
>> Anyone know what needs to be adjusted so that the perldoc pages clear
>> up?
>
> Hello.
> A bit of googling gives
>
> export PERLDOC_PAGER='less -r'
>

Has no effect here.  I still see the same escape sequences


___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread Alexander Pyhalov


Harry Putnam писал 03.04.2014 22:28:

Running 151_a8 as guest in vbox vm on win 7 host

I get esc sequences in perldoc output that makes it hard to read.  A
small sample is included at the end.

I vaguely remember having to make some kind of LANG or related
variable adjustment in the past for this problem...

But cannot remember now what was done.

I am using less as pager.

Anyone know what needs to be adjusted so that the perldoc pages clear
up?


Hello.
A bit of googling gives

export PERLDOC_PAGER='less -r'

---
System Administrator of Southern Federal University Computer Center



___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread Tim Mooney

In regard to: Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc...:


On 04/03/14 14:28, Harry Putnam wrote:

ESC[1mNAMEESC[0m
 Cwd − get pathname of current working directory


At a guess, your TERM setting doesn't match the actual terminal emulator
you're using.


I see the same problem when using the default "gnome-terminal", with
TERM=xterm.  I'm using OI151a9 as my desktop workstation.

Tim
--
Tim Mooney tim.moo...@ndsu.edu
Enterprise Computing & Infrastructure  701-231-1076 (Voice)
Room 242-J6, Quentin Burdick Building  701-231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


Re: [OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread James Carlson
On 04/03/14 14:28, Harry Putnam wrote:
> ESC[1mNAMEESC[0m
>  Cwd − get pathname of current working directory

At a guess, your TERM setting doesn't match the actual terminal emulator
you're using.

There are many terminal emulators around -- including an extended vt102
emulator built into xterm, emulators built into various Windows
applications, and so on.  It would help if you could provide precise
details on how you're connecting *to* your system and how you're
displaying the results.

I would expect you get different results depending on how you connect
(e.g., Putty on Windows versus actual OI console running an xterm).

-- 
James Carlson 42.703N 71.076W 

___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss


[OpenIndiana-discuss] 'less' Esc sequences in peldoc output

2014-04-03 Thread Harry Putnam
Running 151_a8 as guest in vbox vm on win 7 host

I get esc sequences in perldoc output that makes it hard to read.  A
small sample is included at the end.

I vaguely remember having to make some kind of LANG or related
variable adjustment in the past for this problem...

But cannot remember now what was done.

I am using less as pager.

Anyone know what needs to be adjusted so that the perldoc pages clear
up?


Sample (a snippet from "perldoc Cwd"):

ESC[1mNAMEESC[0m
 Cwd − get pathname of current working directory

ESC[1mSYNOPSISESC[0m
 use Cwd;
 my $dir = getcwd;

 use Cwd 'abs_path';
 my $abs_path = abs_path($file);

ESC[1mDESCRIPTIONESC[0m
 This module provides functions for determining the pathname
 of the current working directory.  It is recommended that
 getcwd (or another *ESC[4mcwd()ESC[24m function) be used in 
ESC[4mallESC[24m code to
 ensure portability.

 By default, it exports the functions ESC[4mcwd()ESC[24m, 
ESC[4mgetcwd()ESC[24m,
 ESC[4mfastcwd()ESC[24m, and ESC[4mfastgetcwd()ESC[24m (and, on Win32, 
ESC[4/tmp/xFkMcR5f3E 



___
OpenIndiana-discuss mailing list
OpenIndiana-discuss@openindiana.org
http://openindiana.org/mailman/listinfo/openindiana-discuss