[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mailclient-send-it usage of browse-url

From: David Reitter
Subject: Re: mailclient-send-it usage of browse-url
Date: Wed, 14 Apr 2010 08:55:50 -0400

On Apr 13, 2010, at 11:22 PM, Christian Lynbech wrote:
> While it could be that emacs-w3m does not do the right thing with
> mailto, it is still so that one cannot really know what `browse-url'
> really points to.

Well, that's Emacs, or Lisp, if you will.  You never know how a function is 
implemented...  Users/third-party packages can override a lot.

> Wouldn't it be a solution to just directly do what `browse-url' was
> normally expected to do rather than relying on the user or the
> third-party package having set everything up correctly?

Have a look at browse-url.el.  What would this be?
It's entirely system-dependent, so stopping short of replicating the code that 
determines `browse-url-browser-function', one could

(let ((browse-url-browser-function (default-value 
   (browse-url mailto-url))

If you're set up correctly, this would let the system handle the mailto URL, 
and the system would give control back to Emacs, because Emacs is your mail 
client.  And there you have your infinite loop again - it's just a wider loop.

The real problem here lies in the design.  `send-mail-function' is supposed to 
specify a function that sends e-mail off without further user interaction.  
Because we can't do that out-of-the-box, we have to do something at a different 
level in the "control hierarchy": call the mail client and let the user edit 
the e-mail again (which is what mailto URLs lead to).
Perhaps we need a mechanism to leave send-mail-function nil by default, yet 
allow bug reporting functions to go through the mail client by default.

Or, one would set up a trivial little script on Savannah to receive a bug 
report by HTTP and then send the mail off.  That's roughly how most modern 
software solves the problem.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]