# HG changeset patch # User Richard M. Stallman # Date 845001267 0 # Node ID c7622616333c8744ea6f5c5ebde64d4359fd6ef5 # Parent e25afe6ea4d6751d3cc11a5207b414c3ddd39562 (browse-url-at-point): Add autoload cookie. (browse-url-at-mouse, browse-url-of-buffer, browse-url-of-file) (browse-url-of-dired-file): Likewise. diff -r e25afe6ea4d6 -r c7622616333c lisp/browse-url.el --- a/lisp/browse-url.el Fri Oct 11 02:32:17 1996 +0000 +++ b/lisp/browse-url.el Fri Oct 11 02:34:27 1996 +0000 @@ -101,22 +101,6 @@ ;; Do any other browsers have remote control? ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -;; Installation - -;; Put the following in your ~/.emacs file: -;; -;; (autoload 'browse-url-at-point "browse-url" -;; "Ask a WWW browser to load the URL at or before point." t) -;; (autoload 'browse-url-at-mouse "browse-url" -;; "Ask a WWW browser to load a URL clicked with the mouse." t) -;; (autoload 'browse-url-of-buffer "browse-url" -;; "Ask a WWW browser to display BUFFER." t) -;; (autoload 'browse-url-of-file "browse-url" -;; "Ask a WWW browser to display FILE." t) -;; (autoload 'browse-url-of-dired-file "browse-url" -;; "In Dired, ask a WWW browser to display the file named on this line." t) - -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Usage ;; To display the URL at or before point: @@ -430,6 +414,7 @@ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Browse current buffer +;;;###autoload (defun browse-url-of-file (&optional file) "Ask a WWW browser to display FILE. Display the current buffer's file if FILE is nil or if called @@ -477,6 +462,7 @@ "/" (substring file (match-end 0))))) file) +;;;###autoload (defun browse-url-of-buffer (&optional buffer) "Ask a WWW browser to display BUFFER. Display the current buffer if BUFFER is nil." @@ -524,6 +510,7 @@ (add-hook 'kill-buffer-hook 'browse-url-delete-temp-file) (add-hook 'kill-emacs-hook 'browse-url-delete-temp-file-list) +;;;###autoload (defun browse-url-of-dired-file () "In Dired, ask a WWW browser to display the file named on this line." (interactive) @@ -541,6 +528,7 @@ (interactive (browse-url-interactive-arg "URL: ")) (apply browse-url-browser-function args)) +;;;###autoload (defun browse-url-at-point () "Ask a WWW browser to load the URL at or before point. Doesn't let you edit the URL like browse-url. Variable @@ -560,6 +548,7 @@ (defun event-point (event) (posn-point (event-start event))))) +;;;###autoload (defun browse-url-at-mouse (event) "Ask a WWW browser to load a URL clicked with the mouse. The URL is the one around or before the position of the mouse click