[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to copy URL's to clipboard?
From: |
Katsumi Yamaoka |
Subject: |
Re: How to copy URL's to clipboard? |
Date: |
Fri, 13 Jul 2007 13:24:15 +0900 |
User-agent: |
Gnus/5.1008 (Gnus v5.10.8) Emacs/22.1.50 (gnu/linux) |
>>>>> Katsumi Yamaoka wrote:
> For such a link expressed with a plain text, you can bind the
> same key to just the function `browse-url-firefox'. For example:
I forgot to write the way to map the `vv' key to `browse-url-firefox'
also in emacs-w3m buffers. Here it is:
--8<---------------cut here---------------start------------->8---
(define-key w3m-mode-map "v" (make-sparse-keymap))
(define-key w3m-mode-map "vb" 'w3m-bookmark-view)
(define-key w3m-mode-map "vv"
(lambda nil
(interactive)
(let* ((w3m-content-type-alist (copy-sequence w3m-content-type-alist))
(html (cdr (assoc "text/html" w3m-content-type-alist))))
(setq w3m-content-type-alist (delq html w3m-content-type-alist))
(setq html (copy-sequence html))
;; Make sure to use Firefox.
(setcar (nthcdr 2 html) 'browse-url-firefox)
(push html w3m-content-type-alist)
(w3m-external-view-this-url))))
--8<---------------cut here---------------end--------------->8---
This should be added to your ~/.emacs-w3m.el file, not anywhere else.
Note that it remaps the key for the `w3m-bookmark-view' command into
`vb'. I think customizing too much the keymap is not a good idea,
though. In emacs-w3m buffers, you can use the `M' command instead.
- How to copy URL's to clipboard?, Svend Tollak Munkejord, 2007/07/10
- Re: How to copy URL's to clipboard?, Katsumi Yamaoka, 2007/07/10
- Re: How to copy URL's to clipboard?, Svend Tollak Munkejord, 2007/07/11
- Re: How to copy URL's to clipboard?, Hadron, 2007/07/11
- Re: How to copy URL's to clipboard?, Katsumi Yamaoka, 2007/07/11
- Re: How to copy URL's to clipboard?, Hadron, 2007/07/12
- Re: How to copy URL's to clipboard?, Katsumi Yamaoka, 2007/07/12
- Re: How to copy URL's to clipboard?, Hadron, 2007/07/12
- Re: How to copy URL's to clipboard?, Katsumi Yamaoka, 2007/07/12
- Re: How to copy URL's to clipboard?,
Katsumi Yamaoka <=
- Re: How to copy URL's to clipboard?, Hadron, 2007/07/15