[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/doc-toc cf6b12ca35 79/84: Fix #10: prevent pdf-filename
From: |
ELPA Syncer |
Subject: |
[elpa] externals/doc-toc cf6b12ca35 79/84: Fix #10: prevent pdf-filename become nil |
Date: |
Mon, 26 Sep 2022 13:58:40 -0400 (EDT) |
branch: externals/doc-toc
commit cf6b12ca356d119e68935737e3340155d8fda3f3
Author: Daniel Nicolai <dalanicolai@gmail.com>
Commit: Daniel Nicolai <dalanicolai@gmail.com>
Fix #10: prevent pdf-filename become nil
---
toc-mode.el | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/toc-mode.el b/toc-mode.el
index e8b43e61ac..11a70566fd 100644
--- a/toc-mode.el
+++ b/toc-mode.el
@@ -325,16 +325,17 @@ The newly created PDF that includes the TOC is written to
a file
named output.pdf and opened in a new buffer. Don't forget to
rename this new file."
(interactive)
- (write-file default-directory)
- (let* ((message (shell-command-to-string (format "pdftocio '%s' < toc"
pdf-filename))))
+ (let* ((output-buf (get-buffer-create "*pdftocio-output*")))
+ (call-process-region (point-min) (point-max) "pdftocio"
+ nil output-buf nil pdf-filename)
(kill-buffer-if-not-modified (find-file pdf-filename))
(when (file-exists-p (concat (file-name-base pdf-filename) "_out.pdf"))
(delete-file pdf-filename)
(rename-file (concat (file-name-base pdf-filename) "_out.pdf")
pdf-filename))
(find-file pdf-filename)
- (unless (string= message "")
- (message (concat "The pdftocio command returned the following message:
\n\n" message)))))
-
+ (if (> (buffer-size output-buf) 0)
+ (pop-to-buffer output-buf)
+ (kill-buffer output-buf))))
(defvar toc-pdftocgen-mode-map
(let ((map (make-sparse-keymap)))
- [elpa] externals/doc-toc 8c2cb1283d 60/84: Add info about pdf.tocgen alternative, (continued)
- [elpa] externals/doc-toc 8c2cb1283d 60/84: Add info about pdf.tocgen alternative, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc dc5be6442f 66/84: Add jump-by-level to toc-tabular-mode, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 06de33f511 70/84: Fix pdf-view-current-page macro not function, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc a0018b8a63 71/84: Add replace fields in toc-tabular-mode feature, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc f2ea7db226 68/84: Fix all checkdoc warnings, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 487177a81b 73/84: Update package description, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 36fe728f38 72/84: Make tesseract psm code configurable via universal arg, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc d5629c7165 75/84: Update djvu ocr to djvu3.el (create ppm instead of svg), ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc a259f4cc65 77/84: Correct docstring position, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 0671d11654 78/84: Merge pull request #8 from syohex/docstring, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc cf6b12ca35 79/84: Fix #10: prevent pdf-filename become nil,
ELPA Syncer <=
- [elpa] externals/doc-toc b4bb748aa3 84/84: Fix README (remove repeated section), ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 0c9a7a484f 09/84: Update README with link to djvulibre website, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 559e7bbf3d 13/84: Implement extract with tesseract ocr, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 97c0ce5c40 19/84: Implement from tabular jump to/scroll page for djvu, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 2b6045b0a3 22/84: minor additions i.e. autoload comment and docstrings, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc dda3491299 34/84: Fix djvu parse tablist to djvused algorithm, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc e84c00c923 45/84: Fix/remove ask for path before add TOC djvu, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc eb8c6a0c00 56/84: Fix seq and cl compiler warnings, ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 05b6d034aa 59/84: Fix djvu/pdf hard dependency (github issue #3), ELPA Syncer, 2022/09/26
- [elpa] externals/doc-toc 8d4817a543 62/84: Fix org-noter conflict (github #4), ELPA Syncer, 2022/09/26