[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
doc-view functions inside with-current-buffer do not work
From: |
Alexander Baier |
Subject: |
doc-view functions inside with-current-buffer do not work |
Date: |
Mon, 03 Nov 2014 17:16:58 +0100 |
User-agent: |
Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.4 (gnu/linux) |
Hello,
Consider the following steps:
- Define this function:
#+BEGIN_SRC emacs-lisp
(defun my-doc-view-goto-page (n)
(with-current-buffer (get-buffer "test.pdf")
(doc-view-goto-page n)))
#+END_SRC
- C-x C-f test.pdf RET
- Evaluating the following snippet:
#+BEGIN_SRC emacs-lisp
(my-doc-view-goto-page 2)
#+END_SRC
For me the buffer containing the test.pdf is still displaying the first
page of test.pdf. I expected it to show the second. Is this a bug?
Note: I waited for doc-view-mode to convert the whole pdf to png
images. At least the mode line displays "1/22" and does not change
anymore.
Regards,
--
Alexander Baier
- doc-view functions inside with-current-buffer do not work,
Alexander Baier <=