diff options
Diffstat (limited to 'init.org')
-rw-r--r-- | init.org | 13 |
1 files changed, 8 insertions, 5 deletions
@@ -1181,14 +1181,16 @@ #+end_src *** same mode #+begin_src emacs-lisp - (defun jao-buffer-same-mode (&optional mode) + (defun jao-buffer-same-mode (&optional mode pre-fn) (interactive) (let* ((mode (or mode major-mode)) (pred `(lambda (b) (let ((b (get-buffer (if (consp b) (car b) b)))) (and ;; (not (eq b ,(current-buffer))) - (eq ',mode (buffer-local-value 'major-mode b))))))) - (pop-to-buffer (read-buffer "Buffer: " nil t pred)))) + (eq ',mode (buffer-local-value 'major-mode b)))))) + (buff (read-buffer "Buffer: " nil t pred))) + (when pre-fn (funcall pre-fn)) + (pop-to-buffer buff))) (global-set-key (kbd "C-c C-b") #'jao-buffer-same-mode) #+end_src *** buffer quit function (the triple ESC) @@ -1540,7 +1542,8 @@ ("O" (jao-org-pdf-goto-org 4) "notes file, linking")) "Navigation" (("b" jao-doc-view-back "back jump") - ("B" jao-doc-view-back "forward jump")) + ("B" jao-doc-view-back "forward jump") + ("u" jao-doc-view-visit-url "visit URL")) "Slices" (("cb" doc-view-set-slice-from-bounding-box "bounding box") ("cm" doc-view-set-slice-using-mouse "using mouse")) @@ -2229,7 +2232,7 @@ *** Web browsers #+begin_src emacs-lisp (jao-load-org "eww") - (jao-load-org "w3m") + ;; (jao-load-org "w3m") #+end_src * Shells *** shell modes |