unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH] browse-url.el mozilla tab support
@ 2002-10-10 14:37 Simon Josefsson
       [not found] ` <jas@extundo.com>
  0 siblings, 1 reply; 5+ messages in thread
From: Simon Josefsson @ 2002-10-10 14:37 UTC (permalink / raw)


Ok to install this?  Does FSF have papers for Steve Youngs?  Maybe it
is too trivial to require papers, it is cut'n'paste of the existing
Galeon code.

2002-10-10  Simon Josefsson  <jas@extundo.com>

	* browse-url.el (browse-url-mozilla): Doc fix.

2002-10-10  Steve Youngs  <youngs@xemacs.org>

	* browse-url.el (browse-url-mozilla-new-window-is-tab): New.
	(browse-url-mozilla): Use it.

--- browse-url.el.~1.23.~	2002-07-25 20:49:46.000000000 +0200
+++ browse-url.el	2002-10-10 16:34:46.000000000 +0200
@@ -335,6 +335,13 @@
   :type '(repeat (string :tag "Argument"))
   :group 'browse-url)
 
+(defcustom browse-url-mozilla-new-window-is-tab nil
+  "*Whether to open up new windows in a tab or a new window.
+If non-nil, then open the URL in a new tab rather than a new window if
+`browse-url-mozilla' is asked to open it in a new window."
+  :type 'boolean
+  :group 'browse-url)
+
 (defcustom browse-url-galeon-new-window-is-tab nil
   "*Whether to open up new windows in a tab or a new window.
 If non-nil, then open the URL in a new tab rather than a new window if
@@ -853,6 +860,10 @@
 random existing one.  A non-nil interactive prefix argument reverses
 the effect of `browse-url-new-window-flag'.
 
+If `browse-url-mozilla-new-window-is-tab' is non-nil, then whenever a
+document would otherwise be loaded in a new window, it is loaded in a
+new tab in an existing window instead.
+
 When called non-interactively, optional second argument NEW-WINDOW is
 used instead of `browse-url-new-window-flag'."
   (interactive (browse-url-interactive-arg "URL: "))
@@ -862,7 +873,8 @@
     (setq url (replace-match
 	       (format "%%%x" (string-to-char (match-string 0 url))) t t url)))
   (let* ((process-environment (browse-url-process-environment))
-         (process (apply 'start-process
+         (process
+	  (apply 'start-process
 			 (concat "mozilla " url) nil
 			 browse-url-mozilla-program
 			 (append
@@ -870,7 +882,11 @@
 			  (list "-remote"
 				(concat "openURL("
 					url
-					(if new-window ",new-window")
+				(if (browse-url-maybe-new-window
+				     new-window)
+				    (if browse-url-mozilla-new-window-is-tab
+					",new-tab")
+				  ",new-window")
 					")"))))))
     (set-process-sentinel process
 			  `(lambda (process change)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] browse-url.el mozilla tab support
       [not found] ` <jas@extundo.com>
@ 2002-10-10 17:31   ` Peter S Galbraith
  2002-10-10 17:40     ` Simon Josefsson
  0 siblings, 1 reply; 5+ messages in thread
From: Peter S Galbraith @ 2002-10-10 17:31 UTC (permalink / raw)
  Cc: bug-gnu-emacs

Simon Josefsson <jas@extundo.com> wrote:

> Ok to install this?  Does FSF have papers for Steve Youngs?

Steve has recently sent in papers to work on mh-e as our xemacs
developper.  I don't know whether he has specified mh-e or not in the
paperwork.   You could ask him.  He's a nice guy!  ;-)

Peter

>                                                              Maybe it
> is too trivial to require papers, it is cut'n'paste of the existing
> Galeon code.
> 
> 2002-10-10  Steve Youngs  <youngs@xemacs.org>
> 
> 	* browse-url.el (browse-url-mozilla-new-window-is-tab): New.
> 	(browse-url-mozilla): Use it.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] browse-url.el mozilla tab support
  2002-10-10 17:31   ` Peter S Galbraith
@ 2002-10-10 17:40     ` Simon Josefsson
  2002-10-10 21:50       ` Steve Youngs
  0 siblings, 1 reply; 5+ messages in thread
From: Simon Josefsson @ 2002-10-10 17:40 UTC (permalink / raw)
  Cc: bug-gnu-emacs

Steve, have you signed papers for browse-url.el?  I wanted to get
Emacs to include your XEmacs browse-url.el patch too.  Thanks.  (Maybe
papers aren't required for that patch though..)

Peter S Galbraith <GalbraithP@dfo-mpo.gc.ca> writes:

> Simon Josefsson <jas@extundo.com> wrote:
>
>> Ok to install this?  Does FSF have papers for Steve Youngs?
>
> Steve has recently sent in papers to work on mh-e as our xemacs
> developper.  I don't know whether he has specified mh-e or not in the
> paperwork.   You could ask him.  He's a nice guy!  ;-)
>
> Peter
>
>>                                                              Maybe it
>> is too trivial to require papers, it is cut'n'paste of the existing
>> Galeon code.
>> 
>> 2002-10-10  Steve Youngs  <youngs@xemacs.org>
>> 
>> 	* browse-url.el (browse-url-mozilla-new-window-is-tab): New.
>> 	(browse-url-mozilla): Use it.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] browse-url.el mozilla tab support
  2002-10-10 17:40     ` Simon Josefsson
@ 2002-10-10 21:50       ` Steve Youngs
  2002-10-10 21:59         ` Simon Josefsson
  0 siblings, 1 reply; 5+ messages in thread
From: Steve Youngs @ 2002-10-10 21:50 UTC (permalink / raw)
  Cc: bug-gnu-emacs

|--==> "SJ" == Simon Josefsson <jas@extundo.com> writes:

  SJ> Steve, have you signed papers for browse-url.el?  I wanted to get
  SJ> Emacs to include your XEmacs browse-url.el patch too.  Thanks.
  SJ> (Maybe papers aren't required for that patch though..)

Not for browse-url.el specifically, no.  Let me know if you need it.


-- 
|---<Steve Youngs>---------------<GnuPG KeyID: 10D5C9C5>---|
|            XEmacs - It's not just an editor.             |
|                    It's a way of life.                   |
|------------------------------------<youngs@xemacs.org>---|

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] browse-url.el mozilla tab support
  2002-10-10 21:50       ` Steve Youngs
@ 2002-10-10 21:59         ` Simon Josefsson
  0 siblings, 0 replies; 5+ messages in thread
From: Simon Josefsson @ 2002-10-10 21:59 UTC (permalink / raw)
  Cc: bug-gnu-emacs

Steve Youngs <youngs@xemacs.org> writes:

> |--==> "SJ" == Simon Josefsson <jas@extundo.com> writes:
>
>   SJ> Steve, have you signed papers for browse-url.el?  I wanted to get
>   SJ> Emacs to include your XEmacs browse-url.el patch too.  Thanks.
>   SJ> (Maybe papers aren't required for that patch though..)
>
> Not for browse-url.el specifically, no.  Let me know if you need it.

What does the Emacs maintainers think?  Are papers necessary for the
following patch, which mimics already existing Galeon code?

--- browse-url.el.~1.23.~	2002-07-25 20:49:46.000000000 +0200
+++ browse-url.el	2002-10-10 16:34:46.000000000 +0200
@@ -335,6 +335,13 @@
   :type '(repeat (string :tag "Argument"))
   :group 'browse-url)
 
+(defcustom browse-url-mozilla-new-window-is-tab nil
+  "*Whether to open up new windows in a tab or a new window.
+If non-nil, then open the URL in a new tab rather than a new window if
+`browse-url-mozilla' is asked to open it in a new window."
+  :type 'boolean
+  :group 'browse-url)
+
 (defcustom browse-url-galeon-new-window-is-tab nil
   "*Whether to open up new windows in a tab or a new window.
 If non-nil, then open the URL in a new tab rather than a new window if
@@ -862,7 +873,8 @@
     (setq url (replace-match
 	       (format "%%%x" (string-to-char (match-string 0 url))) t t url)))
   (let* ((process-environment (browse-url-process-environment))
-         (process (apply 'start-process
+         (process
+	  (apply 'start-process
 			 (concat "mozilla " url) nil
 			 browse-url-mozilla-program
 			 (append
@@ -870,7 +882,11 @@
 			  (list "-remote"
 				(concat "openURL("
 					url
-					(if new-window ",new-window")
+				(if (browse-url-maybe-new-window
+				     new-window)
+				    (if browse-url-mozilla-new-window-is-tab
+					",new-tab")
+				  ",new-window")
 					")"))))))
     (set-process-sentinel process
 			  `(lambda (process change)

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2002-10-10 21:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-10-10 14:37 [PATCH] browse-url.el mozilla tab support Simon Josefsson
     [not found] ` <jas@extundo.com>
2002-10-10 17:31   ` Peter S Galbraith
2002-10-10 17:40     ` Simon Josefsson
2002-10-10 21:50       ` Steve Youngs
2002-10-10 21:59         ` Simon Josefsson

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).