<<< Date Index >>>     <<< Thread Index >>>

screen, mutt, svgalib



Hi there,

I know there's been a lot of discussion about screen being offtopic in
this list, but this seems to be a problem with it's interaction with
mutt, so I _think_ it's on topic.  Sorry if I'm wrong.

In my .mailcap, I have the following:

image/*; mutt_bgrun /usr/bin/display %s; test=InXTerm
image/*; /usr/bin/zgv --zoom-reduce-only --zoom -m '1024 768 24' %s; 
test=InPlainTerm

Where InXTerm looks like this:

#!/bin/sh
if [ "$TERM" == "xterm" ]
then
    exit 0;
else
    exit 1;
fi

And InPlainTerm like this:

#!/bin/sh
if [ "$TERM" == "linux" ]
then
    exit 0;
elif [ "$TERM" == "screen" ]
then
    exit 0;
else
    exit 1;
fi

When I receive an email with a picture as an attachment, I can view it
in an xterm using ImageMagick's display, or if I'm in a virtual console
"TERM=linux", I can also view it, using zgv.  However, if I'm using
screen it seems to start to load but then exit immediately.  This is not
simply a problem with screen and svgalib because if I try to view a
picture using zgv when mutt isn't running, it works fine.

Can anyone suggest what might be going wrong or where I should be asking
this question?

Many thanks in advance,

Al