[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: lynx-dev Re: Slang - ncurses - TeraTerm
From: |
T.E.Dickey |
Subject: |
Re: lynx-dev Re: Slang - ncurses - TeraTerm |
Date: |
Thu, 29 Jul 1999 20:56:32 -0400 (EDT) |
> On or about 26 Jul, 1999, T.E.Dickey
> <address@hidden> wrote:
>
> [...]
>
> > Teraterm is in the class (roughly half of all color terminals) that John
> > Davis has shunned for several years. If you clear the display, the current
> > colors are not used to set the background color.
>
> OK, now I get it. Before I went to a straight black background,
> I always tweaked TeraTerm's background to match the slang color,
> else it did, indeed, look pretty sloppy.
yes (if you were "here", I could show you exactly what I mean - but I think
you've got the idea now). With library and terminfo that work, TeraTerm
seems to work fine (I was using it a few weeks ago when I was stuck in
an off-site course, to read news here).
> I'll (try to) clarify: Lynx isn't trying to read from the pipe,
> as I understand it. I mapped a key in mutt to:
>
> "|${HOME}/bin/scripts/mail2html\n"
>
> which sends the current email to the mail2html script:
>
> #!/usr/local/bin/tcsh
> formail -I "" $1 | ${HOME}/bin/scripts/txt2html.pl --mail >
> /tmp/warner/mutt-tmp.html
> ${HOME}/bin/lynx -blink -nopause -preparsed /tmp/warner/mutt-tmp.html
> rm /tmp/warner/mutt-tmp.html
>
> which strips mail headers, passes to a perl script that turns
> URL's to anchors, and writes the result to a tmp file. *Then*
> lynx is started with the tmp file as its startfile. I guess the
> original pipe from mutt stays open until the mail2html script
> finishes, but lynx isn't reading from it, right?
That sounds right. Perhaps you can do this (force lynx to read from /dev/tty):
#!/usr/local/bin/tcsh
formail -I "" $1 | ${HOME}/bin/scripts/txt2html.pl --mail >
/tmp/warner/mutt-tmp.html
${HOME}/bin/lynx -blink -nopause -preparsed /tmp/warner/mutt-tmp.html
</dev/tty
rm /tmp/warner/mutt-tmp.html
That's because curses reads from stdin and writes to stdout (standards are
useful). I guess slang doesn't follow that standard, if it "works" in that
case. The shell script's stdin is passed down to subprocesses, but you can
override any of them.
-- But why didn't you use the -dump option? (You'll still get a lot of escape
sequences written as part of the output screen, otherwise).
> > Lynx would have to read the pipe data (and do whatever it needs to),
> > then reopen stdin from /dev/tty (or the equivalent on DOS or VMS).
> > It could be done with curses by doing this before initializing curses.
>
> Question 1 - Does (all or part of) this still apply in light of the above?
> Question 2 - You're talking lynx source code changes, right?
> (If so, it's beyond my scope, I'm afraid)
shell scripting should work for this case - I had thought you were referring
to some case like
cat foo |lynx .
where "foo" contains commands.
> Michael Warner
--
Thomas E. Dickey
address@hidden
http://www.clark.net/pub/dickey
- Re: lynx-dev Re: Slang - ncurses - TeraTerm,
T.E.Dickey <=