* Having browse-url-text-emacs open in other window
@ 2012-07-10 10:14 Mark Skilbeck
2012-07-10 10:23 ` Bastien
0 siblings, 1 reply; 5+ messages in thread
From: Mark Skilbeck @ 2012-07-10 10:14 UTC (permalink / raw)
To: help-gnu-emacs
Hi, all.
I would like to configure browse-url-text-emacs to open documents in a
new window, i.e. not the current window. This is behaviour similar to
apropos, slime, and a whole bunch of other commands. I *could* get
down and dirty in the browse-url code--but, really, who wants to do
that?
Thanks, all.
--
- mgs.
if all you young men / were fish in the water
how many young girls / would undress and dive after
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Having browse-url-text-emacs open in other window
2012-07-10 10:14 Having browse-url-text-emacs open in other window Mark Skilbeck
@ 2012-07-10 10:23 ` Bastien
2012-07-10 10:41 ` Mark Skilbeck
0 siblings, 1 reply; 5+ messages in thread
From: Bastien @ 2012-07-10 10:23 UTC (permalink / raw)
To: Mark Skilbeck; +Cc: help-gnu-emacs
Mark Skilbeck <m@iammark.us> writes:
> I would like to configure browse-url-text-emacs to open documents in a
> new window, i.e. not the current window. This is behaviour similar to
> apropos, slime, and a whole bunch of other commands. I *could* get
> down and dirty in the browse-url code--but, really, who wants to do
> that?
C-u M-x browse-url-text-emacs RET
C-h v browse-url-new-window-flag RET
HTH,
--
Bastien
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Having browse-url-text-emacs open in other window
2012-07-10 10:23 ` Bastien
@ 2012-07-10 10:41 ` Mark Skilbeck
2012-07-11 5:03 ` Bastien
0 siblings, 1 reply; 5+ messages in thread
From: Mark Skilbeck @ 2012-07-10 10:41 UTC (permalink / raw)
To: Bastien; +Cc: help-gnu-emacs
On Tue, Jul 10, 2012 at 12:23:39PM +0200, Bastien wrote:
>
> C-u M-x browse-url-text-emacs RET
>
> C-h v browse-url-new-window-flag RET
>
> HTH,
>
Indeed, I saw this while browsing the documentation. However, it
doesn't do as it says-on-the-tin, at least not in my experience.
Instead of opening a new window (perhaps I should clarify that I mean:
split the window vertically if there's space, or horizontally
otherwise, a la M-x apropos) it looks for an already-present *text
broser* buffer and tries to send the new URL to this buffer. Do I have
it wrong? Did you test this yourself? Perhaps I should restart Emacs
to undo any customizations I've made and try again.
Cheers.
--
- mgs.
if all you young men / were fish in the water
how many young girls / would undress and dive after
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Having browse-url-text-emacs open in other window
2012-07-10 10:41 ` Mark Skilbeck
@ 2012-07-11 5:03 ` Bastien
2012-07-11 14:35 ` Mark Skilbeck
0 siblings, 1 reply; 5+ messages in thread
From: Bastien @ 2012-07-11 5:03 UTC (permalink / raw)
To: Mark Skilbeck; +Cc: help-gnu-emacs
Hi Mark,
Mark Skilbeck <m@iammark.us> writes:
> Indeed, I saw this while browsing the documentation. However, it
> doesn't do as it says-on-the-tin, at least not in my experience.
Sorry I misread the documentation myself.
I would advise the function like this:
(defadvice browse-url (before browse-url-other-window activate)
(switch-to-buffer-other-window (get-buffer-create "*Browser*")))
HTH,
--
Bastien
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Having browse-url-text-emacs open in other window
2012-07-11 5:03 ` Bastien
@ 2012-07-11 14:35 ` Mark Skilbeck
0 siblings, 0 replies; 5+ messages in thread
From: Mark Skilbeck @ 2012-07-11 14:35 UTC (permalink / raw)
To: Bastien; +Cc: help-gnu-emacs
On Wed, Jul 11, 2012 at 07:03:31AM +0200, Bastien wrote:
> Hi Mark,
>
> Mark Skilbeck <m@iammark.us> writes:
>
> > Indeed, I saw this while browsing the documentation. However, it
> > doesn't do as it says-on-the-tin, at least not in my experience.
>
> Sorry I misread the documentation myself.
>
> I would advise the function like this:
>
> (defadvice browse-url (before browse-url-other-window activate)
> (switch-to-buffer-other-window (get-buffer-create "*Browser*")))
>
> HTH,
>
Cool! That works almost perfectly. However, there is a dangling
*Browser* buffer when I leave the browser process. I got around this
by doing:
(defadvice browse-url (before browse-url-other-window activate)
(switch-to-buffer-other-window nil t))
However, this isn't *entirely* desirable. If I have two windows, A and
B, split vertically with a buffer C not displayed, using the above
advice, either A or B (depending on which window is switched-into) is
changed to the C buffer on exiting the browser. It's not a show
stopper, in fact it's much better than the default behaviour of
opening the browser in the same window!
Thanks for your help.
--
- mgs.
if all you young men / were fish in the water
how many young girls / would undress and dive after
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-07-11 14:35 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-10 10:14 Having browse-url-text-emacs open in other window Mark Skilbeck
2012-07-10 10:23 ` Bastien
2012-07-10 10:41 ` Mark Skilbeck
2012-07-11 5:03 ` Bastien
2012-07-11 14:35 ` Mark Skilbeck
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.