[Top][All Lists]

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

Re: doc-view and mailcap

From: Reiner Steib
Subject: Re: doc-view and mailcap
Date: Thu, 18 Oct 2007 09:31:56 +0200
User-agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.50 (gnu/linux)

On Thu, Oct 18 2007, Juri Linkov wrote:

>> (and (fboundp 'doc-view-mode-p)
>>      (doc-view-mode-p))
>> with (in `doc-view.el')...
>> (defun doc-view-mode-p ()
>>   (and (display-graphic-p)

Maybe an additional test like "(executable-find
doc-view-ghostscript-program)" would be useful here.

>>        (image-type-available-p 'png)))
>> Shouldn't it?
> I think the second variant is better.  Since this is a matter of doc-view
> to decide if it can support displaying, it should have such a function
> (autoloaded).

I agree.  And it should accept an argument TYPE (`postscript', `pdf',
`dvi') like `image-type-available-p' to decide it for each document
type, e.g. ...

       (viewer . doc-view-mode)
       (test   . (and (fboundp 'doc-view-mode-p)
                      (doc-view-mode-p 'postscript))
       (type   . "application/postscript"))

Bye, Reiner.
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/

reply via email to

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