Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 1eb2ebd79e
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 45 lines (36 sloc) 1.394 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
;;; emacs-rc-w3m.el ---

;; Copyright (C) 2003 Alex Ott
;;
;; Author: alexott@gmail.com
;; Keywords:
;; Requirements:
;; Status: not intended to be distributed yet

;;(add-to-list 'load-path "~/emacs/emacs-w3m")
;;(autoload 'w3m "w3m" "Interface for w3m on Emacs." t)
(setq w3m-coding-system 'utf-8
                        w3m-file-coding-system 'utf-8
                        w3m-file-name-coding-system 'utf-8
                        w3m-input-coding-system 'utf-8
                        w3m-output-coding-system 'utf-8
                        w3m-terminal-coding-system 'utf-8
                        w3m-use-cookies t
                        )

(add-hook 'w3m-display-hook
          (lambda (url)
            (rename-buffer
             (format "*w3m: %s*" (or w3m-current-title
                                     w3m-current-url)) t)))

(defun w3m-open-current-page-in-firefox ()
  "Opens the current URL in Mozilla Firefox."
  (interactive)
  (browse-url-firefox w3m-current-url))

(defun w3m-open-link-or-image-in-firefox ()
  "Opens the current link or image in Firefox."
  (interactive)
  (browse-url-firefox (or (w3m-anchor)
                          (w3m-image))))

;; (eval-after-load 'w3m
;; (progn
;; (define-key w3m-mode-map "f" 'w3m-open-current-page-in-firefox)
;; (define-key w3m-mode-map "F" 'w3m-open-link-or-image-in-firefox)))


;;; emacs-rc-w3m.el ends here
Something went wrong with that request. Please try again.