Subject: Re: ANSI ESC Sequences in Pico/Pine?

From: [email-masked] (Alan Shutko)
Date: 02 May 1996 22:48:27 -0500

>>>>> "MJ" == Mark Jones <[email-masked]> writes:

MJ>     I am interested in creating some very simple files using Ansi
MJ> <esc> sequences. I would like to type them using Pico from a Unix
MJ> machine. Is it possible to activate these <esc> sequences in Pico?

Pico cannot do that.  Use a real editor.

---

From: [email-masked] (Therefore)
Date: 3 May 1996 07:11:45 GMT

Mark Jones ([email-masked]) wrote in comp.mail.pine on 2 May 1996 22:39:04 GMT:

---

From: [email-masked] (Joseph H Allen)
Date: Fri, 3 May 1996 06:20:17 GMT

In article <[email-masked]>,

>Pico cannot do that.  Use a real editor.

Try joe (get by anonymous ftp from ftp.std.com, file:
src/editors/joe2.8.tar.Z).  It includes 'jpico'- it's like pico, only it's a
real editor.  From jpico (or native joe) control characters can be entered
by prefixing them with `  (to enter a `, you hit ``).  So to enter ESC [ H,
you would type ` <esc> [ H or ` [ [ H.  To enter backspace, type ` H,
` Ctrl-H, or `008.
-- 
/*  [email-masked] (192.74.137.5) */               /* Joseph H. Allen */
int a[1817];main(z,p,q,r){for(p=80;q+p-80;p-=2*a[p])for(z=9;z--;)q=3&(r=time(0)
+r*57)/7,q=q?q-1?q-2?1-p%79?-1:0:p%79-77?1:0:p<1659?79:0:p>158?-79:0,q?!a[p+q*2
]?a[p+=a[p+=q]=q]=q:0:0;for(;q++-1817;)printf(q%79?"%c":"%c\n"," #"[!a[q-1]]);}

---

From: [email-masked] (Richard Slobod)
Date: Fri, 03 May 1996 13:05:34 GMT

[email-masked] (Mark Jones) wrote:
>    I am interested in creating some very simple files using Ansi <esc>
>sequences. I would like to type them using Pico from a Unix machine. Is it
>possible to activate these <esc> sequences in Pico? What keys would I
>literally have to type in order to activate the sequences? For example, I
>know that the sequence to set colors is "ESC [ #;#m", where # = different
>numbers depending on what colors you want to have. But typing the "esc"
>key, followed by the "[" key, etc. in Pico has no effect. Is there some
>sequence of keys that would be interpreted as <esc> in Pico (I found a
>document on the Web which said that <esc> is represented as "$e" in DOS,
>for example)? So what exactly would I type, in Pico, if anything, to
>activate these sequences? Or would I have to type the files on my home PC
>in DOS, encode and download them or something? I am able to view ANSI
>color files using the Unix "cat"  command on my internet provider's remote
>machine. I know that you have to "uuencode" ANSI files in order to
>actually mail them. I'm not so much interested in that, just learning how
>to create some very simple ones, as I said. Any help would be greatly
>appreciated. Please post or email. 

I'm not familiar with Pico, but you normally do this in editors by
preceding the <Esc> with some sort of quoting character.  For
instance, you would type <Ctrl-V><Esc> to enter <Esc> in vi or
<Ctrl-Q><Esc> to do it in Emacs.  I don't know what the quoting
character is in pico (or if it even has that feature, although it
probably does), so you need to check the pico docs.  (It might also be
referred to as "escaping" rather than "quoting", confusingly enough.)

Also, "$e" does _not_ represent <Esc> in DOS.  $e is simply a special
code that tells the command processor to output an <Esc> character
when used in a prompt string, in much the same way that $p will tell
it to output the current path; this feature does not come into play
when editing files, only when setting the prompt.

Lastly, you should be able to e-mail files of ANSI escape sequences
without encoding them; typically, only files containing high-bit
characters (character codes higher than 127) need to be encoded.  Keep
in mind, however,  that if you read the received e-mail in a
terminal-mode (as opposed to GUI) mail-reader on a Unix system and
it's not encoded, the ANSI codes will be immediately "executed" and
may mess up the screen display.

---

From: [email-masked] (Mark Jones)
Date: 2 May 1996 22:39:04 GMT

--
[email-masked] _________       SURVIVOR-Roger McGough              _   /| 
  __ _  ______  /  /  Everyday I think about dying, about disease,   \'o.0'
 /  ' \/ __/ /_/  /   starvation, violence, terrorism, war, the end -=(___)=-
/_/_/_/\__/\_____/    of the world. It helps keep my mind off things.    U

---

From: Mike Sullivan <[email-masked]>
Date: Sat, 4 May 1996 21:11:28 -0700 (PDT)

Can any one tell me if its possible to do a screen dump or scroll text in 
pine. I'm trying to capture uuencoded binaries. Thanks. Mike