mirror of
https://github.com/fscotto/infra.git
synced 2026-05-30 15:39:58 +00:00
Enable PDF viewing in Emacs with pdf-tools and poppler dependencies
This commit is contained in:
@@ -85,6 +85,8 @@ profile_packages:
|
||||
- deluge-gtk
|
||||
- dnsmasq
|
||||
- emacs-gtk3
|
||||
- poppler-glib
|
||||
- poppler-utils
|
||||
- exo
|
||||
- fontconfig-devel
|
||||
- freetype-devel
|
||||
|
||||
@@ -41,11 +41,10 @@
|
||||
'misc/gptel
|
||||
'misc/email
|
||||
'misc/rss
|
||||
'misc/terminal
|
||||
'misc/vcs
|
||||
;; FIXME PDF viewer with annotations
|
||||
;; 'misc/pdf
|
||||
'misc/epub
|
||||
'misc/terminal
|
||||
'misc/vcs
|
||||
'misc/pdf
|
||||
'misc/epub
|
||||
'misc/i3-config)
|
||||
|
||||
(message "...user configuration loaded")
|
||||
|
||||
@@ -1,4 +1,22 @@
|
||||
;;; pdf.el -*- lexical-binding: t; -*-
|
||||
|
||||
(use-package pdf-tools
|
||||
:ensure t
|
||||
:config
|
||||
(pdf-tools-install))
|
||||
|
||||
(use-package pdf-view
|
||||
:config
|
||||
(setq-default pdf-view-display-size 'fit-width)
|
||||
(setq pdf-cache-org-imgparams t
|
||||
pdf-view-use-smooth-scrolling t)
|
||||
(setq pdf-annot-default-visible-properties t))
|
||||
|
||||
(with-eval-after-load 'pdf-view
|
||||
(define-key pdf-view-mode-map (kbd "n") 'pdf-view-next-page)
|
||||
(define-key pdf-view-mode-map (kbd "p") 'pdf-view-previous-page)
|
||||
(define-key pdf-view-mode-map (kbd "q") 'pdf-view-close))
|
||||
|
||||
(provide 'misc/pdf)
|
||||
|
||||
;;; pdf.el ends here
|
||||
|
||||
Reference in New Issue
Block a user