@@ -20,7 +20,7 @@ will be used if graphical browsers are not available or an X11 display isn't
20
20
available. If text-mode browsers are used, the calling process will block until
21
21
the user exits the browser.
22
22
23
- If the environment variable :envvar: `BROWSER ` exists, it is interpreted as the
23
+ If the environment variable :envvar: `! BROWSER ` exists, it is interpreted as the
24
24
:data: `os.pathsep `-separated list of browsers to try ahead of the platform
25
25
defaults. When the value of a list part contains the string ``%s ``, then it is
26
26
interpreted as a literal browser command line to be used with the argument URL
@@ -97,7 +97,7 @@ The following functions are defined:
97
97
98
98
Setting *preferred * to ``True `` makes this browser a preferred result for
99
99
a :func: `get ` call with no argument. Otherwise, this entry point is only
100
- useful if you plan to either set the :envvar: `BROWSER ` variable or call
100
+ useful if you plan to either set the :envvar: `! BROWSER ` variable or call
101
101
:func: `get ` with a nonempty argument matching the name of a handler you
102
102
declare.
103
103
@@ -111,49 +111,49 @@ for the controller classes, all defined in this module.
111
111
+------------------------+-----------------------------------------+-------+
112
112
| Type Name | Class Name | Notes |
113
113
+========================+=========================================+=======+
114
- | ``'mozilla' `` | :class: ` Mozilla('mozilla') ` | |
114
+ | ``'mozilla' `` | `` Mozilla('mozilla') `` | |
115
115
+------------------------+-----------------------------------------+-------+
116
- | ``'firefox' `` | :class: ` Mozilla('mozilla') ` | |
116
+ | ``'firefox' `` | `` Mozilla('mozilla') `` | |
117
117
+------------------------+-----------------------------------------+-------+
118
- | ``'epiphany' `` | :class: ` Epiphany('epiphany') ` | |
118
+ | ``'epiphany' `` | `` Epiphany('epiphany') `` | |
119
119
+------------------------+-----------------------------------------+-------+
120
- | ``'kfmclient' `` | :class: ` Konqueror() ` | \( 1) |
120
+ | ``'kfmclient' `` | `` Konqueror() `` | \( 1) |
121
121
+------------------------+-----------------------------------------+-------+
122
- | ``'konqueror' `` | :class: ` Konqueror() ` | \( 1) |
122
+ | ``'konqueror' `` | `` Konqueror() `` | \( 1) |
123
123
+------------------------+-----------------------------------------+-------+
124
- | ``'kfm' `` | :class: ` Konqueror() ` | \( 1) |
124
+ | ``'kfm' `` | `` Konqueror() `` | \( 1) |
125
125
+------------------------+-----------------------------------------+-------+
126
- | ``'opera' `` | :class: ` Opera() ` | |
126
+ | ``'opera' `` | `` Opera() `` | |
127
127
+------------------------+-----------------------------------------+-------+
128
- | ``'links' `` | :class: ` GenericBrowser('links') ` | |
128
+ | ``'links' `` | `` GenericBrowser('links') `` | |
129
129
+------------------------+-----------------------------------------+-------+
130
- | ``'elinks' `` | :class: ` Elinks('elinks') ` | |
130
+ | ``'elinks' `` | `` Elinks('elinks') `` | |
131
131
+------------------------+-----------------------------------------+-------+
132
- | ``'lynx' `` | :class: ` GenericBrowser('lynx') ` | |
132
+ | ``'lynx' `` | `` GenericBrowser('lynx') `` | |
133
133
+------------------------+-----------------------------------------+-------+
134
- | ``'w3m' `` | :class: ` GenericBrowser('w3m') ` | |
134
+ | ``'w3m' `` | `` GenericBrowser('w3m') `` | |
135
135
+------------------------+-----------------------------------------+-------+
136
- | ``'windows-default' `` | :class: ` WindowsDefault ` | \( 2) |
136
+ | ``'windows-default' `` | `` WindowsDefault `` | \( 2) |
137
137
+------------------------+-----------------------------------------+-------+
138
- | ``'macosx' `` | :class: ` MacOSXOSAScript('default') ` | \( 3) |
138
+ | ``'macosx' `` | `` MacOSXOSAScript('default') `` | \( 3) |
139
139
+------------------------+-----------------------------------------+-------+
140
- | ``'safari' `` | :class: ` MacOSXOSAScript('safari') ` | \( 3) |
140
+ | ``'safari' `` | `` MacOSXOSAScript('safari') `` | \( 3) |
141
141
+------------------------+-----------------------------------------+-------+
142
- | ``'google-chrome' `` | :class: ` Chrome('google-chrome') ` | |
142
+ | ``'google-chrome' `` | `` Chrome('google-chrome') `` | |
143
143
+------------------------+-----------------------------------------+-------+
144
- | ``'chrome' `` | :class: ` Chrome('chrome') ` | |
144
+ | ``'chrome' `` | `` Chrome('chrome') `` | |
145
145
+------------------------+-----------------------------------------+-------+
146
- | ``'chromium' `` | :class: ` Chromium('chromium') ` | |
146
+ | ``'chromium' `` | `` Chromium('chromium') `` | |
147
147
+------------------------+-----------------------------------------+-------+
148
- | ``'chromium-browser' `` | :class: ` Chromium('chromium-browser') ` | |
148
+ | ``'chromium-browser' `` | `` Chromium('chromium-browser') `` | |
149
149
+------------------------+-----------------------------------------+-------+
150
150
151
151
Notes:
152
152
153
153
(1)
154
154
"Konqueror" is the file manager for the KDE desktop environment for Unix, and
155
155
only makes sense to use if KDE is running. Some way of reliably detecting KDE
156
- would be nice; the :envvar: `KDEDIR ` variable is not sufficient. Note also that
156
+ would be nice; the :envvar: `! KDEDIR ` variable is not sufficient. Note also that
157
157
the name "kfm" is used even when using the :program: `konqueror ` command with KDE
158
158
2 --- the implementation selects the best strategy for running Konqueror.
159
159
@@ -163,6 +163,11 @@ Notes:
163
163
(3)
164
164
Only on macOS platform.
165
165
166
+ .. versionadded :: 3.2
167
+ A new :class: `!MacOSXOSAScript ` class has been added
168
+ and is used on Mac instead of the previous :class: `!MacOSX ` class.
169
+ This adds support for opening browsers not currently set as the OS default.
170
+
166
171
.. versionadded :: 3.3
167
172
Support for Chrome/Chromium has been added.
168
173
@@ -171,9 +176,6 @@ Notes:
171
176
Removed browsers include Grail, Mosaic, Netscape, Galeon,
172
177
Skipstone, Iceape, and Firefox versions 35 and below.
173
178
174
- .. deprecated-removed :: 3.11 3.13
175
- :class: `MacOSX ` is deprecated, use :class: `MacOSXOSAScript ` instead.
176
-
177
179
Here are some simple examples::
178
180
179
181
url = 'https://docs.python.org/'
@@ -222,4 +224,4 @@ module-level convenience functions:
222
224
.. rubric :: Footnotes
223
225
224
226
.. [1 ] Executables named here without a full path will be searched in the
225
- directories given in the :envvar: `PATH ` environment variable.
227
+ directories given in the :envvar: `! PATH ` environment variable.
0 commit comments