On 2013-12-01, Peter Davis wrote:
> As I understand it, gnus uses w3m to display html messages if it's
> available.
> 
> I have my .mailcap file setup to use w3m to display html messages
> in mutt, but they don't look like the same messages do in gnus.
> There's less use of color, italics and bold and other text
> features. Also, column layouts in the html appear in gnus but not
> in mutt.
> 
> Here's my .mailcap entry:
> 
> text/html; w3m -I %{charset} -dump %s -cols $COLUMNS; copiousoutput; 
> description=HTML Text; nametemplate=%s.html
> text/*; more
> 
> Is there anything I can do to get mutt's w3m display to look more
> like that in gnus?

According to the Gnus Manual
(http://www.gnu.org/software/emacs/manual/html_node/gnus/HTML.html)
section 4.3 HTML:

    If you have w3m installed on your system, Gnus can display HTML
    articles in the article buffer. There are many Gnus add-ons for
    doing this, using various approaches, but there's one (sort of)
    built-in method that's used by default. 

So to start with, since there appear to be several ways for gnus to
display HTML, and since I didn't see any screen shots in the manual,
I don't know what you mean by "look more like that in gnus."

That aside, there are two ways that mutt can use w3m to display HTML
messages.  One is to use w3m's -dump option to output the message
formatted as plain text, as in your .mailcap entry, and display it
using mutt's pager.  When used that way, w3m does not output any
color information, so the only color that mutt can add to the text
is according to mutt's pager's coloring rules.

The other is to run w3m on the HTML part of the message via the
attachment menu (bound to 'v' by default).  In this method, w3m is
doing the rendering of the message directly to your terminal,
including any coloring of the text, and is not interacting with mutt
at all, so you should see all the color rendering w3m is capable of.

The coloring that w3m applies is also affected by its configuration,
so there may be configuration options that gnus sets that you aren't
setting in your .mailcap entry and that aren't in your ~/.w3m/config
file.

The column layouts should appear the same in both cases and, if gnus
is indeed using w3m for HTML rendering, should appear the same in
gnus.  If you can be more specific and give at least one
reproducible example, I can take a look at the column layout
problem.

Regards,
Gary

Reply via email to