GNU bug report logs -
#4896
DocView: Continuous mode
Previous Next
Reported by: Juri Linkov <juri <at> jurta.org>
Date: Tue, 10 Nov 2009 08:25:05 UTC
Severity: wishlist
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #147 received at 4896 <at> emacsbugs.donarmstrong.com (full text, mbox):
>> Maybe we should switch off view-mode in doc-view-mode explicitly? IMO
>> doc-view-mode is THE view-mode for PDF/DVI/PS files...
>
> Thanks. It seems your fix doesn't work. The reason is that
> `after-find-file' calls `view-mode-enter' *after* calling
> `doc-view-mode' via `normal-mode'.
>
> However, adding the following line to the end of `doc-view-mode'
> seems to work (because `after-find-file' checks for `view-read-only'
> before calling `view-mode-enter'):
>
> (set (make-local-variable 'view-read-only) nil)
This still doesn't work in all cases. Typing `v' on a PDF file in Dired
activates View-mode (I type RET in Dired when the intention is to *edit*
the file, and type `v' when the intention is to *view* the file).
Doc-view-mode has no chance to disable view-mode, because view-file
(called from dired-view-file) at first visits the file with
find-file-noselect that enables doc-view-mode, and after that
view-file enables view-mode.
View-file doesn't enable view-mode only when the property `mode-class' is
`special'. Actually lisp/doc-view.el already contains the necessary line,
but it is commented out:
;; (put 'doc-view-mode 'mode-class 'special)
I wonder what was the reason for commenting this out?
--
Juri Linkov
http://www.jurta.org/emacs/
This bug report was last modified 3 years and 107 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.