]> git.eshelyaron.com Git - emacs.git/commit
Fix the different image zoom levels in SHR to work as expected
authorJim Porter <jporterbugs@gmail.com>
Sun, 23 Jun 2024 21:48:32 +0000 (14:48 -0700)
committerEshel Yaron <me@eshelyaron.com>
Sun, 7 Jul 2024 13:16:52 +0000 (15:16 +0200)
commit66d48e2201265ac1222c5f77846e8cd2a612d1d4
tree300b7ac5c421625b6eed34f459689e0a0fdf05ab
parentd81d96592a624206bd830d26ccc099192de0cb4c
Fix the different image zoom levels in SHR to work as expected

* lisp/net/shr.el (shr-image-zoom-levels): New option.
(shr-image-zoom-level-alist): New variable.
(shr-zoom-image): Take POSITION and ZOOM-LEVEL arguments.  Consult
'shr-image-zoom-levels'.
(shr-put-image): Use 'shr-image-zoom-level-alist'.
(shr-rescale-image): Only reset width *or* height when either is too
large.
(shr--image-zoom-original-size, shr--image-zoom-image-size)
(shr--image-zoom-fill-height): New functions.

* etc/NEWS: Announce this change.

(cherry picked from commit 208207c1c07fb4669c6b7d64c27236074f996ae4)
etc/NEWS
lisp/net/shr.el