aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/doc-view.el
diff options
context:
space:
mode:
authorGlenn Morris <[email protected]>2008-10-18 22:30:55 +0000
committerGlenn Morris <[email protected]>2008-10-18 22:30:55 +0000
commitca32d854d63ba89c0467925e29dd586fdb66cc84 (patch)
treef8767e45e9a500e88849767cf42062d6a78d6c94 /lisp/doc-view.el
parent04d36203696979941183c2811c96ae7a36e91c6d (diff)
(doc-view-pdf->txt, doc-view-ps->pdf): Give an error if the needed
external programs were not found.
Diffstat (limited to 'lisp/doc-view.el')
-rw-r--r--lisp/doc-view.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/lisp/doc-view.el b/lisp/doc-view.el
index 9694e9a70e..36029fb2f6 100644
--- a/lisp/doc-view.el
+++ b/lisp/doc-view.el
@@ -654,6 +654,8 @@ Start by converting PAGES, and then the rest."
(defun doc-view-pdf->txt (pdf txt callback)
"Convert PDF to TXT asynchronously and call CALLBACK when finished."
+ (or doc-view-pdftotext-program
+ (error "You need the `pdftotext' program to convert a PDF to text"))
(doc-view-start-process "pdf->txt" doc-view-pdftotext-program
(list "-raw" pdf txt)
callback))
@@ -684,6 +686,8 @@ Start by converting PAGES, and then the rest."
(defun doc-view-ps->pdf (ps pdf callback)
"Convert PS to PDF asynchronously and call CALLBACK when finished."
+ (or doc-view-ps2pdf-program
+ (error "You need the `ps2pdf' program to convert PS to PDF"))
(doc-view-start-process "ps->pdf" doc-view-ps2pdf-program
(list
;; Avoid security problems when rendering files from