emacs-devel
[Top][All Lists]
Advanced

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

Re: Image-conversion shims


From: Eli Zaretskii
Subject: Re: Image-conversion shims
Date: Sun, 29 Sep 2019 10:11:52 +0300

> From: Lars Ingebrigtsen <address@hidden>
> Date: Sun, 29 Sep 2019 01:29:48 +0200
> Cc: address@hidden
> 
> Stefan Monnier <address@hidden> writes:
> 
> > Go for it. 
> 
> I went for it.

Thanks.

> (setq convert-images-externally t)

That variable's name should start with "image-", IMO, and the same for
the (confusingly similar) convert-external-images.  It should also be
documented in the user manual (I'd simply move what you wrote for the
ELisp manual to the user manual, since I see no reason to document
this in the former).

When looking for an installed converter, shouldn't we put ImageMagick
last?

I also think that using call-process for invoking the converter makes
the feature less flexible and more "tricky" to maintain.  Already you
needed to jump through some hoops to support "gm convert".  I think
using shell-command would have made all this much simpler and more
straightforward.

> It doesn't work in image-mode yet, because I was unsure at what point to
> hook the auto-mode stuff together with this stuff.  It's slightly
> chicken and egg -- convert-images-externally isn't consulted before we
> try to display an image, and it will then compute what image suffixes it
> can handle.
> 
> But if that hasn't been computed, then image-mode won't be triggered,
> and so create-image won't be called.

Maybe we need a new hook?



reply via email to

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