[texworks] what is a default browser?
Stefan Löffler
st.loeffler at gmail.com
Fri Jul 15 07:19:04 CEST 2011
Hi,
On 2011-07-15 06:34, Atsuhito Kohda wrote:
> recently TeXworks provides nice manual and we can see
> it from menu with a browser.
>
> But, strangely, on one of my Debian system it calls
> /opt/google/chrome/google-chrome as a browser and,
> because there is no such browser on my system, it fails
> to show me a manual. (On another system, it works fine.)
>
> I investigated various methods to define a default browser,
> like x-www-browser, gconf-editor etc. but no success.
>
> I'd like to know how TeXworks selects a default browser
> for manual and if we can define it at compile time.
TeXworks uses QDesktopServices::openUrl (src/TWApp.cpp at 305), documented
at http://doc.trolltech.com/latest/qdesktopservices.html#openUrl
That resource just states "Opens the given /url/ in the appropriate Web
browser for the user's desktop environment".
Digging into the Qt source code (Qt 4.7.2,
src/util/gui/qdesktopservices_x11.cpp) suggests the following things are
tried:
1) `xdg-open`
2) `gnome-open` or `kfmclient exec` (depending on desktop environment)
3) firefox
4) mozilla
5) netscape
6) opera
(note that this applies to local files (file:// protocol). For others,
the DEFAULT_BROWSER and BROWSER environment variable are tried between
attempts 1) and 2).
So, you probably know better how to configure these tools than I do, but
it should get you started in the right direction :).
HTH
Stefan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/texworks/attachments/20110715/159022d3/attachment-0001.html>
More information about the texworks
mailing list