Function: image-scroll-left

image-scroll-left is an interactive and byte-compiled function defined in image-mode.el.gz.

Signature

(image-scroll-left &optional N)

Documentation

Scroll image in current window leftward by N character widths.

Stop if the right edge of the image is reached. If ARG is omitted or nil, scroll leftward by a near full screen. A near full screen is 2 columns less than a full screen. Negative ARG means scroll rightward. If ARG is the atom -, scroll rightward by nearly full screen. When calling from a program, supply as argument a number, nil, or -.

Probably introduced at or before Emacs version 26.1.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/image-mode.el.gz
(defun image-scroll-left (&optional n)
  "Scroll image in current window leftward by N character widths.
Stop if the right edge of the image is reached.
If ARG is omitted or nil, scroll leftward by a near full screen.
A near full screen is 2 columns less than a full screen.
Negative ARG means scroll rightward.
If ARG is the atom `-', scroll rightward by nearly full screen.
When calling from a program, supply as argument a number, nil, or `-'."
  (interactive "P" image-mode)
  (cond ((null n)
	 (let* ((edges (window-inside-edges))
		(win-width (- (nth 2 edges) (nth 0 edges))))
	   (image-forward-hscroll
	    (max 0 (- win-width 2)))))
	((eq n '-)
	 (let* ((edges (window-inside-edges))
		(win-width (- (nth 2 edges) (nth 0 edges))))
	   (image-forward-hscroll
	    (min 0 (- 2 win-width)))))
	(t (image-forward-hscroll (prefix-numeric-value n)))))