Use woman for manpages in Emacs.
This commit is contained in:
parent
6ff34a0518
commit
3e7250661d
22
init.el
22
init.el
|
@ -1,5 +1,5 @@
|
||||||
;;; init.el --- tastytea's Emacs init file.
|
;;; init.el --- tastytea's Emacs init file.
|
||||||
;; Time-stamp: <2019-10-08T16:15:13+00:00>
|
;; Time-stamp: <2019-10-09T18:39:58+00:00>
|
||||||
|
|
||||||
;;; Commentary:
|
;;; Commentary:
|
||||||
;; Requires at least Emacs 24.3.
|
;; Requires at least Emacs 24.3.
|
||||||
|
@ -610,14 +610,20 @@ With argument, do this that many times."
|
||||||
|
|
||||||
;;;;;;;;;;;;;;;;;;;; Misc ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;; Misc ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
;; Manual pages.
|
;; Manual pages.
|
||||||
(use-package man
|
(use-package woman
|
||||||
:defer t
|
:config
|
||||||
:custom-face
|
(defun my/woman-topic-at-point ()
|
||||||
(Man-overstrike ((t (:inherit font-lock-type-face :bold t))))
|
"Call woman and use the word at point as topic if it exists."
|
||||||
(Man-underline ((t (:inherit font-lock-keyword-face :underline t))))
|
(interactive)
|
||||||
|
(let ((woman-use-topic-at-point t))
|
||||||
|
(woman))
|
||||||
|
)
|
||||||
|
|
||||||
|
;; Open manpages in new window.
|
||||||
|
(setq display-buffer-alist '(("\\`\\*WoMan" display-buffer-pop-up-window)))
|
||||||
:bind
|
:bind
|
||||||
("<f1>" . man)
|
("<f1>" . my/woman-topic-at-point)
|
||||||
("C-<f1>" . (lambda () (interactive) (manual-entry (current-word))))
|
("C-<f1>" . woman)
|
||||||
)
|
)
|
||||||
|
|
||||||
;; Show directory tree in a window.
|
;; Show directory tree in a window.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user