From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/26991 Path: main.gmane.org!not-for-mail From: Daniel Pittman Newsgroups: gmane.emacs.gnus.general Subject: URL buttons and new browser windows... Date: 17 Nov 1999 11:19:53 +1100 Organization: Here, there and everywhere... Sender: owner-ding@hpc.uh.edu Message-ID: <8766z23r6e.fsf@inanna.danann.net> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: main.gmane.org 1035164095 22259 80.91.224.250 (21 Oct 2002 01:34:55 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 21 Oct 2002 01:34:55 +0000 (UTC) Keywords: patch, browse-url Return-Path: Original-Received: from bart.math.uh.edu (bart.math.uh.edu [129.7.128.48]) by sclp3.sclp.com (8.8.5/8.8.5) with ESMTP id TAA07833 for ; Tue, 16 Nov 1999 19:20:37 -0500 (EST) Original-Received: from sina.hpc.uh.edu (lists@Sina.HPC.UH.EDU [129.7.3.5]) by bart.math.uh.edu (8.9.1/8.9.1) with ESMTP id SAB03408; Tue, 16 Nov 1999 18:20:35 -0600 (CST) Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Tue, 16 Nov 1999 18:20:51 -0600 (CST) Original-Received: from sclp3.sclp.com (root@sclp3.sclp.com [204.252.123.139]) by sina.hpc.uh.edu (8.9.3/8.9.3) with ESMTP id SAA25375 for ; Tue, 16 Nov 1999 18:20:40 -0600 (CST) Original-Received: from fw01.osa.com.au (fw01.osa.com.au [203.6.130.130]) by sclp3.sclp.com (8.8.5/8.8.5) with SMTP id TAA07827 for ; Tue, 16 Nov 1999 19:20:04 -0500 (EST) Original-Received: (qmail 25737 invoked by uid 0); 17 Nov 1999 00:19:56 -0000 Original-Received: from redgum.osa.com.au (15.16.33.1) by fw01.osa.com.au with SMTP; 17 Nov 1999 00:19:56 -0000 Original-Received: from inanna.danann.net (inanna.osa.com.au [172.16.33.101]) by redgum.osa.com.au (8.6.9/8.6.9) with ESMTP id LAA29106 for ; Wed, 17 Nov 1999 11:19:26 +1100 Original-Received: by inanna.danann.net (Postfix, from userid 1000) id 31A2E5783C; Wed, 17 Nov 1999 11:19:53 +1100 (EST) Original-To: ding@gnus.org X-Homepage: http://danann.net/ Mail-Copies-To: Never X-spies: Kennedy radar clones Albania COSCO encryption DES [Hello to all my fans in domestic surveillance] South Africa ECHELON domestic disruption bomb SDI cryptographic Mena Original-Lines: 28 User-Agent: Gnus/5.070099 (Pterodactyl Gnus v0.99) XEmacs/21.2 (Yoko) Precedence: list X-Majordomo: 1.94.jlt7 Xref: main.gmane.org gmane.emacs.gnus.general:26991 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:26991 --=-=-= Given that I am often on a relatively slow connection, I tend to use my web browser as a background process--create a new window for an URL, do something for a while and then go and read it. This is fairly trivial to do and works well with the XEmacs 'browse-url' library and 'browse-url-new-window-p' set to 't'. This should cause the package to open a new window when a URL is visited. pGnus in the article buttonization code does not use the top level entry-point for 'browse-url' but rather directly calls the selected function (browse.*netscape) in my case :) The problem is that gnus did not respect the setting of 'browse-url-new-window-p' which was annoying to me. The attached patch corrects this and is, I believe, trivially correct. Daniel --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Description: browse-url patch Index: lisp/gnus-art.el =================================================================== RCS file: /usr/local/cvsroot/gnus/lisp/gnus-art.el,v retrieving revision 5.89 diff -u -r5.89 gnus-art.el --- lisp/gnus-art.el 1999/11/07 03:26:48 5.89 +++ lisp/gnus-art.el 1999/11/17 00:16:13 @@ -4388,7 +4388,9 @@ ;; In Emacs 20, `browse-url-browser-function' may be an alist. (if (listp browse-url-browser-function) (browse-url address) - (funcall browse-url-browser-function address))) + (funcall browse-url-browser-function address + (and (boundp browse-url-new-window-p) + browse-url-new-window-p)))) (defun gnus-button-embedded-url (address) "Browse ADDRESS." --=-=-= -- Any form of power without responsibility, without direct and formal checks and balances, is frightening to people -- and reasonably so. It should be frankly admitted that hackers are frightening, and that the basis of this fear is not irrational. -- Bruce Sterling --=-=-=--