Function: image-decrease-size

image-decrease-size is an interactive and byte-compiled function defined in image.el.gz.

Signature

(image-decrease-size &optional N POSITION)

Documentation

Decrease the image size at POSITION by a factor specified by N.

If N is 3, then the image size will be decreased by 30%. More generally, the image size is multiplied by 1 minus N divided by 10. N defaults to 2, which decreases the image size by 20%. POSITION can be a buffer position or a marker, and defaults to point.

When user option image-recompute-map-p is non-nil, the image's :map is recomputed to fit the newly transformed image.

View in manual

Probably introduced at or before Emacs version 30.1.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/image.el.gz
(defun image-decrease-size (&optional n position)
  "Decrease the image size at POSITION by a factor specified by N.
If N is 3, then the image size will be decreased by 30%.  More
generally, the image size is multiplied by 1 minus N divided by 10.
N defaults to 2, which decreases the image size by 20%.
POSITION can be a buffer position or a marker, and defaults to point.

When user option `image-recompute-map-p' is non-nil, the image's `:map'
is recomputed to fit the newly transformed image."
  (interactive "P")
  (image--delayed-change-size (if n
                                  (- 1 (/ (prefix-numeric-value n) 10.0))
                                0.8)
                              position)
  (set-transient-map image--repeat-map nil nil
                     "Use %k for further adjustments"))