diff options
| author | Vibhav Pant | 2015-03-17 05:27:23 +0530 |
|---|---|---|
| committer | Vibhav Pant | 2015-03-17 05:27:23 +0530 |
| commit | 43a847c02c3eb848cd0d55a4722bfe7f39b1112f (patch) | |
| tree | 81b4b137cf471613f98b041921e44993bb20ba58 | |
| parent | ab4e4cc92c62051983f4ee5f1bf9c82440086451 (diff) | |
| download | emacs-43a847c02c3eb848cd0d55a4722bfe7f39b1112f.tar.gz emacs-43a847c02c3eb848cd0d55a4722bfe7f39b1112f.zip | |
Fixes: debbugs:19335
* net/browse-url.el (browse-url-browser-function): Add "Conkeror".
(browse-url-conkeror-program, browse-url-conkeror-arguments)
(browse-url-conkeror-new-window-is-buffer): New defcustoms.
(browse-url-default-browser): Check for `browse-url-conkeror'
and call `browse-url-conkeror-program'.
(browse-url-conkeror): New command.
(bug#19863)
* etc/NEWS: Mention added support for Conkeror.
| -rw-r--r-- | etc/NEWS | 4 | ||||
| -rw-r--r-- | lisp/ChangeLog | 10 | ||||
| -rw-r--r-- | lisp/net/browse-url.el | 56 |
3 files changed, 70 insertions, 0 deletions
| @@ -560,6 +560,10 @@ command line's password prompt. | |||
| 560 | 560 | ||
| 561 | *** The new built-in command `clear' can scroll window contents out of sight. | 561 | *** The new built-in command `clear' can scroll window contents out of sight. |
| 562 | 562 | ||
| 563 | ** Browse-url | ||
| 564 | |||
| 565 | *** browse-url now supports the Conkeror Web Browser. | ||
| 566 | |||
| 563 | +++ | 567 | +++ |
| 564 | ** tar-mode: new `tar-new-entry' command, allowing for new members to | 568 | ** tar-mode: new `tar-new-entry' command, allowing for new members to |
| 565 | be added to the archive. | 569 | be added to the archive. |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3af4bb20b04..1383fdb2ecf 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,15 @@ | |||
| 1 | 2015-03-16 Vibhav Pant <vibhavp@gmail.com> | 1 | 2015-03-16 Vibhav Pant <vibhavp@gmail.com> |
| 2 | 2 | ||
| 3 | * net/browse-url.el (browse-url-browser-function): Add "Conkeror". | ||
| 4 | (browse-url-conkeror-program, browse-url-conkeror-arguments) | ||
| 5 | (browse-url-conkeror-new-window-is-buffer): New defcustoms. | ||
| 6 | (browse-url-default-browser): Check for `browse-url-conkeror' | ||
| 7 | and call `browse-url-conkeror-program'. | ||
| 8 | (browse-url-conkeror): New command. | ||
| 9 | (bug#19863) | ||
| 10 | |||
| 11 | 2015-03-16 Vibhav Pant <vibhavp@gmail.com> | ||
| 12 | |||
| 3 | * eshell/esh-mode.el (eshell/clear): New function. | 13 | * eshell/esh-mode.el (eshell/clear): New function. |
| 4 | 14 | ||
| 5 | 2015-03-16 Alan Mackenzie <acm@muc.de> | 15 | 2015-03-16 Alan Mackenzie <acm@muc.de> |
diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el index 5e61c094c2e..4b64d95d0c6 100644 --- a/lisp/net/browse-url.el +++ b/lisp/net/browse-url.el | |||
| @@ -42,6 +42,7 @@ | |||
| 42 | ;; browse-url-netscape Netscape 1.1b1 | 42 | ;; browse-url-netscape Netscape 1.1b1 |
| 43 | ;; browse-url-mosaic XMosaic/mMosaic <= 2.4 | 43 | ;; browse-url-mosaic XMosaic/mMosaic <= 2.4 |
| 44 | ;; browse-url-cci XMosaic 2.5 | 44 | ;; browse-url-cci XMosaic 2.5 |
| 45 | ;; browse-url-conkeror Conkeror Dont know | ||
| 45 | ;; browse-url-w3 w3 0 | 46 | ;; browse-url-w3 w3 0 |
| 46 | ;; browse-url-w3-gnudoit w3 remotely | 47 | ;; browse-url-w3-gnudoit w3 remotely |
| 47 | ;; browse-url-text-* Any text browser 0 | 48 | ;; browse-url-text-* Any text browser 0 |
| @@ -236,6 +237,7 @@ regexp should probably be \".\" to specify a default browser." | |||
| 236 | (function-item :tag "Netscape" :value browse-url-netscape) | 237 | (function-item :tag "Netscape" :value browse-url-netscape) |
| 237 | (function-item :tag "Mosaic" :value browse-url-mosaic) | 238 | (function-item :tag "Mosaic" :value browse-url-mosaic) |
| 238 | (function-item :tag "Mosaic using CCI" :value browse-url-cci) | 239 | (function-item :tag "Mosaic using CCI" :value browse-url-cci) |
| 240 | (function-item :tag "Conkeror" :value browse-url-conkeror) | ||
| 239 | (function-item :tag "Text browser in an xterm window" | 241 | (function-item :tag "Text browser in an xterm window" |
| 240 | :value browse-url-text-xterm) | 242 | :value browse-url-text-xterm) |
| 241 | (function-item :tag "Text browser in an Emacs window" | 243 | (function-item :tag "Text browser in an Emacs window" |
| @@ -416,6 +418,13 @@ functionality is not available there." | |||
| 416 | :type 'boolean | 418 | :type 'boolean |
| 417 | :group 'browse-url) | 419 | :group 'browse-url) |
| 418 | 420 | ||
| 421 | (defcustom browse-url-conkeror-new-window-is-buffer nil | ||
| 422 | "Whether to open up new windows in a buffer or a new window. | ||
| 423 | If non-nill, then open the URL in a new buffer rather than a new window if | ||
| 424 | `browse-url-conkeror' is asked to open it in a new window" | ||
| 425 | :type 'boolean | ||
| 426 | :group 'browse-url) | ||
| 427 | |||
| 419 | (defcustom browse-url-galeon-new-window-is-tab nil | 428 | (defcustom browse-url-galeon-new-window-is-tab nil |
| 420 | "Whether to open up new windows in a tab or a new window. | 429 | "Whether to open up new windows in a tab or a new window. |
| 421 | If non-nil, then open the URL in a new tab rather than a new window if | 430 | If non-nil, then open the URL in a new tab rather than a new window if |
| @@ -462,6 +471,17 @@ commands reverses the effect of this variable. Requires Netscape version | |||
| 462 | :type 'string | 471 | :type 'string |
| 463 | :group 'browse-url) | 472 | :group 'browse-url) |
| 464 | 473 | ||
| 474 | (defcustom browse-url-conkeror-program "conkeror" | ||
| 475 | "The name by which to invoke Conkeror." | ||
| 476 | :type 'string | ||
| 477 | :version "25.1" | ||
| 478 | :group 'browse-url) | ||
| 479 | |||
| 480 | (defcustom browse-url-conkeror-arguments nil | ||
| 481 | "A list of strings to pass to Conkeror as arguments." | ||
| 482 | :type '(repeat (string :tag "Argument")) | ||
| 483 | :group 'browse-url) | ||
| 484 | |||
| 465 | (defcustom browse-url-filename-alist | 485 | (defcustom browse-url-filename-alist |
| 466 | `(("^/\\(ftp@\\|anonymous@\\)?\\([^:]+\\):/*" . "ftp://\\2/") | 486 | `(("^/\\(ftp@\\|anonymous@\\)?\\([^:]+\\):/*" . "ftp://\\2/") |
| 467 | ;; The above loses the username to avoid the browser prompting for | 487 | ;; The above loses the username to avoid the browser prompting for |
| @@ -936,6 +956,7 @@ used instead of `browse-url-new-window-flag'." | |||
| 936 | ((executable-find browse-url-kde-program) 'browse-url-kde) | 956 | ((executable-find browse-url-kde-program) 'browse-url-kde) |
| 937 | ((executable-find browse-url-netscape-program) 'browse-url-netscape) | 957 | ((executable-find browse-url-netscape-program) 'browse-url-netscape) |
| 938 | ((executable-find browse-url-mosaic-program) 'browse-url-mosaic) | 958 | ((executable-find browse-url-mosaic-program) 'browse-url-mosaic) |
| 959 | ((executable-find browse-url-conkeror-program) 'browse-url-conkeror) | ||
| 939 | ((executable-find browse-url-xterm-program) 'browse-url-text-xterm) | 960 | ((executable-find browse-url-xterm-program) 'browse-url-text-xterm) |
| 940 | ((locate-library "w3") 'browse-url-w3) | 961 | ((locate-library "w3") 'browse-url-w3) |
| 941 | (t | 962 | (t |
| @@ -1359,6 +1380,41 @@ used instead of `browse-url-new-window-flag'." | |||
| 1359 | (process-send-string "browse-url" "disconnect\r\n") | 1380 | (process-send-string "browse-url" "disconnect\r\n") |
| 1360 | (delete-process "browse-url")) | 1381 | (delete-process "browse-url")) |
| 1361 | 1382 | ||
| 1383 | ;; --- Conkeror --- | ||
| 1384 | ;;;###autoload | ||
| 1385 | (defun browse-url-conkeror (url &optional new-window) | ||
| 1386 | "Ask the Conkeror WWW browser to load URL. | ||
| 1387 | Default to the URL around or before point. The strings in the variable | ||
| 1388 | `browse-url-conkeror-arguments' are also passed to Conkeror. | ||
| 1389 | |||
| 1390 | When called interactively, if variable `browse-url-new-window-flag' | ||
| 1391 | is non-nil, load the document in a new Conkeror window, otherwise use a random | ||
| 1392 | existing one. A non-nil interactive prefix argument reverses the effect of | ||
| 1393 | `browse-url-new-window-flag' | ||
| 1394 | |||
| 1395 | If `browse-url-conkeror-new-window-is-buffer' then whenever a document would | ||
| 1396 | otherwise be loaded in a new window, it is loaded in a new buffer in an existing | ||
| 1397 | window instead. | ||
| 1398 | |||
| 1399 | When called non-interatively, optional second argument NEW-WINDOW is used instead of | ||
| 1400 | `browse-url-new-window-flag'" | ||
| 1401 | (interactive (browse-url-interactive-arg "URL: ")) | ||
| 1402 | (setq url (browse-url-encode-url url)) | ||
| 1403 | (let* ((process-environment (browse-url-process-environment))) | ||
| 1404 | (apply 'start-process (format "conkeror %s" url) | ||
| 1405 | nil | ||
| 1406 | browse-url-conkeror-program | ||
| 1407 | (append | ||
| 1408 | browse-url-conkeror-arguments | ||
| 1409 | (list | ||
| 1410 | "-e" | ||
| 1411 | (format "load_url_in_new_%s('%s')" | ||
| 1412 | (if (browse-url-maybe-new-window new-window) | ||
| 1413 | (if browse-url-conkeror-new-window-is-buffer | ||
| 1414 | "buffer" | ||
| 1415 | "window") | ||
| 1416 | "buffer") | ||
| 1417 | url)))))) | ||
| 1362 | ;; --- W3 --- | 1418 | ;; --- W3 --- |
| 1363 | 1419 | ||
| 1364 | ;; External. | 1420 | ;; External. |