diff options
author | Jim Porter <jporterbugs@gmail.com> | 2024-06-19 20:59:59 -0700 |
---|---|---|
committer | Jim Porter <jporterbugs@gmail.com> | 2024-06-22 23:09:00 -0700 |
commit | 5f9b5803bea0f360a91e00cd85d72ea7f56d6095 (patch) | |
tree | f54e14a1871a2fd5c5f276f299058e4a78749f4a /lisp/emacs-lisp/byte-run.el | |
parent | 6f2036243f24369b0b4c35c9b323eb19dad4e4cd (diff) | |
download | emacs-5f9b5803bea0f360a91e00cd85d72ea7f56d6095.tar.gz emacs-5f9b5803bea0f360a91e00cd85d72ea7f56d6095.tar.bz2 emacs-5f9b5803bea0f360a91e00cd85d72ea7f56d6095.zip |
Fix zooming images in SHR
Previously, for images with no alt-text, the zoomed image wouldn't get
properly inserted. For images with alt-text, both the zoomed and
unzoomed image would be displayed at once (bug#71666).
* lisp/net/shr.el (shr-sliced-image): New face.
(shr-zoom-image): Reimplement using
'next/previous-single-property-change', and don't bother deleting any of
the text.
(shr-image-fetched): Clean up any overlays when deleting the old region.
(shr-put-image): Ensure we always have a non-empty string to put the
image on. For sliced images, just use "*", since we'll repeat it, so we
can't preserve the original buffer text exactly anyway. Apply an
overlay to sliced images to prevent unsightly text decorations.
(shr-tag-img): Move the placeholder space insertion where it should be
and explain what it's doing.
* test/lisp/net/shr-tests.el (shr-test--max-wait-time)
(shr-test-wait-for): New helper functions.
(shr-test/zoom-image): New test.
Diffstat (limited to 'lisp/emacs-lisp/byte-run.el')
0 files changed, 0 insertions, 0 deletions