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 #156 received at 4896 <at> debbugs.gnu.org (full text, mbox):
>> Stefan, do you remember why you commented out this line?
>> When `doc-view-mode' has this `mode-class' property, then
>> viewing a PDF file from Dired doesn't activates View-mode.
>
> Because I think that mode-class is for buffers whose content is
> generated from a process or something like that, not from files.
> Things like dired, pcl-cvs, ibuffer, shell-mode, compilation-mode, ...
>
>> (And setting `view-read-only' to nil is not necessary anymore.)
>
> Why not?
Because its value is inessential with (put 'doc-view-mode 'mode-class 'special).
Functions `after-find-file', `view-file', `toggle-read-only' check for
`mode-class' to not activate view-mode when major mode is special.
Do you think we should add another similar property applicable only to
disabling view-mode?
>> Also I discovered another case: visiting a PDF file from a tar archive
>> activates View-mode, because `tar-extract' tries to mimic `view-file'
>> but ignores the `mode-class' property. The patch below fixes this bug
>> for tar-mode.el by duplicating more code from `view-file'.
>
>> After feature freeze this duplicate code could be moved
>> from `view-file' to `view-buffer'.
>
> I think the right solution should be to let the major mode say
> explicitly that it is mutually-exclusive with view-mode.
mode-class=special already says that it is mutually-exclusive with
view-mode, and a new similar property could do the same.
> And it should be a dynamic property: it should only apply when the
> ps/pdf/dvi document is displayed as an image, not when it's displayed
> as text.
mode-class=special already doesn't disable view-mode when the ps/pdf/dvi
document is visited as text because in this case the major mode is not
doc-view-mode.
--
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.