emacs-orgmode
[Top][All Lists]
Advanced

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

[O] Use Emacs support for image resizing when using org-image-actual-wid


From: Terje Larsen
Subject: [O] Use Emacs support for image resizing when using org-image-actual-width
Date: Thu, 29 Aug 2019 16:16:28 +0200

I am running Emacs version 27 (building from master) and recently
noticed that my images no longer scales using org-image-actual-width.

I then read that ImageMagick support is no longer enabled by default as
there is a new "native" resizing method built-in to Emacs.

As seen in the news for on Emacs version 27 (master branch):
> ** Emacs no longer defaults to using ImageMagick to display images,
> due to security and stability concerns.  To override the default, use
> 'configure --with-imagemagick'.

As well as:
> ** Emacs now supports resizing and rotating images without ImageMagick.
> All modern systems support this feature.  (On GNU and Unix systems,
> Cairo drawing or the XRender extension to X11 is required for this to
> be available; the configure script will test for it and, if found,
> enable scaling.)

> The new function 'image-transforms-p' can be used to test whether any
> given frame supports these capabilities.

I then inspected the code of org-mode and noticed there is an expression
in the cond that figures out how to scale, e.g.:
> ((not (image-type-available-p 'imagemagick)) nil)

I haven't looked into yet how the scaling is done, but I know some other
modes such as image-mode had support for using the new method.

I think it would be great to support the native scaling option as well
when available. Since opting in to imagemagick will be Emacs wide and
then we loose the benefit of the new functionality.

Best regards,
Terje Larsen



reply via email to

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