emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: doc-view cache file permissions


From: Stefan Monnier
Subject: Re: doc-view cache file permissions
Date: Wed, 31 Oct 2007 11:10:15 -0400
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/23.0.50 (gnu/linux)

> furthermore I noticed that `g' is bound twice in d-v-mode-map.  I
> changed the bindings so that `g' is bound to d-v-goto-page and `r' is
> bound to d-v-reconvert-doc now.

I understand that `r' (or `C-r') is often used by pdf viewers to
refresh/reload, but `g' is the standard binding in Emacs for that, so I'd
rather we keep `g' for `revert-buffer', add `r' that does the same, and then
just use the standard M-g M-g binding to goto a specific page.

Also I prefer `revert-buffer' because it also reverts the buffer's content
rather than only the display.

So I suggest the patch below instead,


        Stefan


PS: I also think that C-S-n should be C-s and C-S-p should be C-r (but it's
a bit more than just changing bindings and I haven't written the
corresponding code).


Index: doc-view.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/doc-view.el,v
retrieving revision 1.15
diff -u -u -b -r1.15 doc-view.el
--- doc-view.el 31 Oct 2007 03:10:32 -0000      1.15
+++ doc-view.el 31 Oct 2007 15:07:50 -0000
@@ -226,7 +226,7 @@
     (define-key map (kbd "DEL")       'doc-view-scroll-down-or-previous-page)
     (define-key map (kbd "M-<")       'doc-view-first-page)
     (define-key map (kbd "M->")       'doc-view-last-page)
-    (define-key map (kbd "g")         'doc-view-goto-page)
+    (define-key map [remap goto-line] 'doc-view-goto-page)
     ;; Killing/burying the buffer (and the process)
     (define-key map (kbd "q")         'bury-buffer)
     (define-key map (kbd "k")         'doc-view-kill-proc-and-buffer)
@@ -250,7 +250,8 @@
     ;; Toggle between text and image display or editing
     (define-key map (kbd "C-c C-c")   'doc-view-toggle-display)
     ;; Reconvert the current document
-    (define-key map (kbd "g")         'doc-view-reconvert-doc)
+    (define-key map (kbd "g")         'revert-buffer)
+    (define-key map (kbd "r")         'revert-buffer)
     map)
   "Keymap used by `doc-view-mode' when displaying a doc as a set of images.")
 






reply via email to

[Prev in Thread] Current Thread [Next in Thread]