unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* Design bug in browse-url.el: browse-url-can-use-xdg-open's logic uses overly strict assumption
@ 2014-11-07 11:04 Florian v. Savigny
  2014-11-08 17:19 ` bug#18986: " Jan D.
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Florian v. Savigny @ 2014-11-07 11:04 UTC (permalink / raw)
  To: bug-gnu-emacs; +Cc: Denis Howe, emacs-devel



Dear maintainers/authors,

browse-url-can-use-xdg-open returns t only if emacs is running under one of the desktop environments, i.e. Gnome, KDE, Xfce4 or LXDE.

I do not know the deeper reasons for this, but from experience, I can confirm that this running under a desktop environment may be sufficient, but is not necessary: My emacs is running under fvwm, and xdg-open works fine. (You have to know how to configure it, but that is no dark magic either; I do it via ~/.local/share/applications/mimeapps.list.)

My guess is that it would be sufficient to check for the existence of the xdg-open binary. The condition of one of the desktop environments being run is somewhat annoying, because when not fulfilled, it causes browse-url-default-browser, which is often employed to open a URL, to default to mozilla (or whatever follows in its hardcoded list), which may not be exactly what you want. Effectively, it makes it impossible to specify your favourite browser without some kludgy hack.

I have included some of the information produced by M-x report-emacs-bug, but since I am fairly certain that most of it is irrelevant, I have left it out:


In GNU Emacs 24.4.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.14.3)
 of 2014-10-21 on bitzer.hoetzel.info
Windowing system distributor `The X.Org Foundation', version 11.0.11601000
Configured using:
 `configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --with-x-toolkit=gtk3 --with-xft
 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe
 -fstack-protector-strong --param=ssp-buffer-size=4'
 CPPFLAGS=-D_FORTIFY_SOURCE=2
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro'

Important settings:
  value of $LANG: de_DE.ISO-8859-1
  locale-coding-system: iso-latin-1-unix


Best regards,

Florian v. Savigny





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

end of thread, other threads:[~2018-02-16  0:42 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-07 11:04 Design bug in browse-url.el: browse-url-can-use-xdg-open's logic uses overly strict assumption Florian v. Savigny
2014-11-08 17:19 ` bug#18986: " Jan D.
     [not found] ` <E1A681AD-2DC5-4143-B7ED-F179A8856D6B@swipnet.se>
2014-11-08 18:05   ` Stefan Monnier
2014-11-15 12:31     ` Florian v. Savigny
2018-02-12 16:23 ` bug#18986: #18986 " Pierre Neidhardt
2018-02-12 17:47   ` Eli Zaretskii
2018-02-12 17:51     ` Pierre Neidhardt
2018-02-12 18:42       ` Eli Zaretskii
2018-02-14 21:46         ` Pierre Neidhardt
2018-02-15  2:14           ` Noam Postavsky
2018-02-16  0:28             ` Pierre Neidhardt
2018-02-16  0:42               ` Pierre Neidhardt

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).