(set-keymap-parent map special-mode-map)
(define-key map "\C-c\C-c" 'image-toggle-display)
(define-key map (kbd "SPC") 'image-scroll-up)
+ (define-key map (kbd "S-SPC") 'image-scroll-down)
(define-key map (kbd "DEL") 'image-scroll-down)
(define-key map (kbd "RET") 'image-toggle-animation)
(define-key map "n" 'image-next-file)
(run-mode-hooks 'image-mode-hook)
(let ((image (image-get-display-property))
(msg1 (substitute-command-keys
- "Type \\[image-toggle-display] to view the image as ")))
+ "Type \\[image-toggle-display] to view the image as "))
+ animated)
(cond
((null image)
(message "%s" (concat msg1 "an image.")))
- ((image-animated-p image)
+ ((setq animated (image-animated-p image))
+ (setq image-current-frame (or (plist-get (cdr image) :index) 0)
+ mode-line-process
+ `(:eval (propertize (format " [%s/%s]"
+ (1+ image-current-frame)
+ ,(car animated))
+ 'help-echo "Frame number")))
(message "%s"
(concat msg1 "text, or "
(substitute-command-keys