- http://www.EmacsWiki.org/emacs/DocViewMode
- https://www.gnu.org/software/emacs/manual/html_node/emacs/Document-View.html
- https://tsdh.wordpress.com/2007/08/22/view-documents-pdfpostscriptdvi-inside-emacs/#comment-4351 – asked the developer to rectify things on the resp. EmacsWiki page quoted above
Ever since I noticed, that in new Emacsen you are able (resp. you should be able) to view e.g. PDFs within Emacs buffers, I wondered why this does not work “on certain platforms”. Today I finally searched for “emacs docview”, found the right document (see above), and solved the issue.
Emacs needs “gs” for converting PDFs to a series of PNGs, but of course it needs to find “gs” on its PATH. “On certain platforms”, $HOME/.profile (or so / etc.) does not get read, so would I manipulate PATH within $HOME/.emacs? No, I don’t like that. An alternative approach:
M-x customize-group RET doc-view RET
And set “Doc View Ghostscript Program” individually. Where is “gs”? Maybe “type -a gs“?!?
Now I enjoy viewing PDFs inside Emacs on even more platforms.
Leave a Reply