Function: eca-chat--refresh-rendered-images

eca-chat--refresh-rendered-images is a natively compiled function defined in eca-chat-image.el.

Signature

(eca-chat--refresh-rendered-images)

Documentation

Re-rasterize inline images in the current chat at the current scale.

Walks overlays carrying the eca-chat-image property, updates each underlying image object's :max-width and :max-height via image-property, then calls image-flush so Emacs re-rasterizes on the next redisplay. Used by the per-chat zoom commands.

Source Code

;; Defined in /nix/store/jklqzw6pzz6j4jrbv8wy0iwgi7jlrbld-emacs-packages-deps/share/emacs/site-lisp/elpa/eca-20260928.1827/eca-chat-image.el
;;;; Per-chat zoom

(defun eca-chat--refresh-rendered-images ()
  "Re-rasterize inline images in the current chat at the current scale.
Walks overlays carrying the `eca-chat-image' property, updates each
underlying image object's `:max-width' and `:max-height' via
`image-property', then calls `image-flush' so Emacs re-rasterizes on
the next redisplay.  Used by the per-chat zoom commands."
  (let ((max-w (eca-chat--resolve-image-max-width)))
    (dolist (ov (overlays-in (point-min) (point-max)))
      (when (overlay-get ov 'eca-chat-image)
        (let ((image (overlay-get ov 'display)))
          (when (and (consp image) (eq (car image) 'image))
            (when max-w
              (setf (image-property image :max-width) max-w))
            (when eca-chat-image-max-height
              (setf (image-property image :max-height)
                    eca-chat-image-max-height))
            (image-flush image)))))))