diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/net/jao-notmuch.el | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/lib/net/jao-notmuch.el b/lib/net/jao-notmuch.el index 8ed14dc..b67c788 100644 --- a/lib/net/jao-notmuch.el +++ b/lib/net/jao-notmuch.el @@ -111,6 +111,28 @@ (message "No URLs in this message"))))) +;; Navigating URLs +(defun jao-notmuch-show-next-button () + (interactive) + (when (get-text-property (point) 'w3m-href-anchor) + (goto-char (next-single-property-change (point) 'w3m-href-anchor))) + (if-let (pos (next-single-property-change (point) 'w3m-href-anchor)) + (goto-char pos) + (forward-button 1))) + +(defun jao-notmuch-show-previous-button () + (interactive) + (if-let (pos (previous-single-property-change (point) 'w3m-href-anchor)) + (goto-char (previous-single-property-change pos 'w3m-href-anchor)) + (backward-button 1))) + +(defun jao-notmuch-show-ret () + (interactive) + (when-let (url (or (get-text-property (point) 'w3m-href-anchor) + (thing-at-point-url-at-point))) + (browse-url url))) + + ;; Toggling mime parts and images (defun jao-notmuch--toggle-mime () @@ -164,7 +186,6 @@ ;; fix w3m renderer keymap (defun jao-w3m-gnus-html-renderer (handle) (let ((w3m-message-silent t) - (mm-inline-text-html-with-w3m-keymap t) (mm-w3m-safe-url-regexp nil)) (condition-case nil (mm-inline-text-html-render-with-w3m handle) |