Gnus development mailing list
 help / color / mirror / Atom feed
From: "Adam Sjøgren" <asjo@koldfront.dk>
To: ding@gnus.org
Subject: Re: View HTML Mail in Browser
Date: Sun, 07 Feb 2021 13:50:13 +0100	[thread overview]
Message-ID: <87zh0gyrcq.fsf@tullinup.koldfront.dk> (raw)
In-Reply-To: <87mtwg6wxw.fsf@gmx.net>

Felix writes:

>> What is problem are you trying to solve?

> I would like to open mails using w3m by default,
> and if I hit K H I would like to open it in the browser:

Ah, ok, I missed the w3m part (shr works better for me), and then got
confused about what wasn't working for you, sorry!

> There must be some configuration that prevents this for me:

Yes, that is very odd, it works "out of the box" for me.

Oh, wait, how do you start Emacs? I have a vague memory that there might
still be parts that check for X once, and then never rechecks, meaning
that you get different behaviour if you start a Emacs as a daemon in the
background without X, or from an Emacs that starts up with an X window.

Could that be it?

I.e. to check, stop Emacs completely, start Emacs in X, read an HTML
email, press K H?

If not, my next step would be to M-x edebug-defun on
gnus-article-browse-html-article and gnus-article-browse-html-parts and
then step through them and see what happens.

It looks like the latter ends up calling browse-url-of-file, so you
might want to experiment with that one, to see if it opens Firefox when
called on a file - if not, then that's a clue.

E.g. if you in a *scratch* buffer evaluate:

  (browse-url-of-file "test.html")

do you then get a Firefox window trying to open test.html?

If not, is your value of:

,----[ C-h v browse-url-browser-function RET ]
| browse-url-browser-function is a variable defined in ‘browse-url.el’.
| Its value is ‘browse-url-firefox’
| Original value was 
| ‘browse-url-default-browser’
| 
|   This variable may be risky if used as a file-local variable.
|   You can customize this variable.
|   This variable was introduced, or its default value was changed, in
|   version 24.1 of Emacs.
|   Probably introduced at or before Emacs version 20.1.
| 
| Documentation:
| Function to display the current buffer in a WWW browser.
| This is used by the ‘browse-url-at-point’, ‘browse-url-at-mouse’, and
| ‘browse-url-of-file’ commands.
| 
| Also see ‘browse-url-secondary-browser-function’ and
| ‘browse-url-handlers’.
`----

?

> Shall I update to Emacs 27.1? Would there be any Gnus compatibility
> issues that I need to watch out for?

I don't think this functionality has changed a lot recently.


  Best regards,

    Adam

-- 
 "heksaeder  -> heksaeder   -> heksæder"                    Adam Sjøgren
                                                       asjo@koldfront.dk



  reply	other threads:[~2021-02-07 12:50 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-06 13:39 Felix Natter
2021-02-06 14:03 ` Andreas Schwab
2021-02-06 21:33   ` Felix Natter
2021-02-06 21:54     ` Adam Sjøgren
2021-02-07  9:36       ` Felix Natter
2021-02-07 12:50         ` Adam Sjøgren [this message]
2021-02-13 11:34           ` Felix Natter
2021-02-13 17:30             ` Adam Sjøgren
2021-02-08 11:05         ` Eric S Fraga
2021-02-08 11:44           ` Emanuel Berg
2021-02-08 11:58             ` Eric S Fraga
2021-02-08 12:12             ` Andreas Schwab
2021-02-08 15:06               ` Emanuel Berg
2021-02-06 23:19     ` Eric Abrahamsen
2021-05-26 14:08   ` Steinar Bang
2021-02-07 10:23 ` Valtteri Vuorikoski
2021-02-09 22:02   ` Adam Sjøgren

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87zh0gyrcq.fsf@tullinup.koldfront.dk \
    --to=asjo@koldfront.dk \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).