summaryrefslogtreecommitdiff
path: root/lisp/image-mode.el
Commit message (Collapse)AuthorAgeFilesLines
* ; Add 2023 to copyright years.Eli Zaretskii2023-01-011-1/+1
|
* Don't auto-resize image if echo area is non-emptyStefan Kangas2022-09-261-1/+3
| | | | | * lisp/image-mode.el (image-fit-to-window): Don't auto-resize image if there's a message in the echo area.
* Autoload wallpaper-setStefan Kangas2022-09-231-1/+0
| | | | | | | * lisp/image/wallpaper.el (wallpaper-set): Autoload. * lisp/image-mode.el (wallpaper): * lisp/image/image-dired.el (wallpaper): * lisp/thumbs.el (wallpaper): Don't require.
* Obsolete image-mode--images-in-directoryStefan Kangas2022-09-211-10/+11
| | | | | * lisp/image-mode.el (image-mode--images-in-directory): Make unused function obsolete.
* Inhibit image-mode resizing in the minibufferLars Ingebrigtsen2022-09-161-1/+5
| | | | | * lisp/image-mode.el (image-fit-to-window): Don't resize when in the minibuffer (bug#57823).
* Make image cropping work in image-mode buffersLars Ingebrigtsen2022-09-141-0/+3
| | | | | * lisp/image-mode.el (image-mode): Update the buffer text after cropping (bug#57793).
* Rename image transform commands to be less confusingStefan Kangas2022-09-141-6/+9
| | | | | | | | | | | | * lisp/image-mode.el (image-transform-original): Rename from this... (image-transform-reset-to-original): ...to this. Make old name into an obsolete function alias and update all callers. (image-transform-reset): Rename from this... (image-transform-reset-to-initial): ...to this. Make old name into an obsolete function alias and update all callers. (Bug#51451) * doc/emacs/files.texi (Image Mode): Update for above change.
* Add new command image-mode-wallpaper-setStefan Kangas2022-09-141-0/+15
| | | | | | * lisp/image-mode.el (wallpaper): Require. (image-mode-wallpaper-set): New command. (image-mode-map): Bind above new command to "W".
* Fix some misleading quoting in cl-caseLars Ingebrigtsen2022-09-131-3/+3
| | | | | | | | | | | * lisp/progmodes/compile.el (compilation-auto-jump): * lisp/image/image-crop.el (image-crop--crop-image-1): (image-crop--crop-image-1): * lisp/image/exif.el (exif--process-value): * lisp/image-mode.el (image-mode--next-file): * lisp/dnd.el (dnd-begin-text-drag): (dnd-begin-file-drag): (dnd-begin-drag-files): Fix misleading quoting in cl-case (bug#51368).
* Merge from origin/emacs-28Stefan Kangas2022-08-191-11/+12
|\ | | | | | | e64d811b51 Improve image-mode-as-hex docstring
| * Improve image-mode-as-hex docstringStefan Kangas2022-08-181-11/+12
| | | | | | | | | | * lisp/image-mode.el: Fix typos. (image-mode-as-hex): Doc fix; say that it uses 'hexl-mode' and reflow.
* | Improve obsoletion of image-transform-fit-to-{height,width}Stefan Kangas2022-08-181-2/+2
| | | | | | | | | | | | * lisp/image-mode.el (image-transform-fit-to-height) (image-transform-fit-to-width): Change obsoletion to refer to new command 'image-transform-fit-to-window'.
* | Do interactive mode tagging in image-mode.elStefan Kangas2022-08-181-29/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-mode.el (image-forward-hscroll) (image-backward-hscroll, image-next-line, image-previous-line) (image-scroll-up, image-scroll-down, image-scroll-left) (image-scroll-right, image-bol, image-eol, image-bob, image-eob) (image-mode-fit-frame, image-kill-buffer, image-next-file) (image-previous-file, image-mode-copy-file-name-as-kill) (image-mode-mark-file, image-mode-unmark-file) (image-transform-set-percent, image-transform-set-scale) (image-transform-fit-to-height, image-transform-fit-to-width) (image-transform-fit-both, image-transform-fit-to-window) (image-transform-set-rotation, image-transform-set-smoothing) (image-transform-original, image-transform-reset): Add interactive tag for image-mode.
* | Make toggling between image, hex and text more consistentStefan Kangas2022-08-181-14/+18
| | | | | | | | | | | | | | | | * lisp/image-mode.el (image-toggle-hex-display, image-toggle-display): Ensure commands work correctly also in `hexl-mode'. (image-mode-to-text): (image-mode-as-hex, image-mode-as-text): Enable image-minor-mode also in hexl-mode, which adds the "C-c C-x" keybinding for easier toggling.
* | ; * lisp/image-mode.el (image-minor-mode): Reflow docstring.Stefan Kangas2022-08-181-3/+3
| |
* | New command image-transform-set-percentStefan Kangas2022-08-181-0/+11
| | | | | | | | | | | | * lisp/image-mode.el (image-transform-set-percent): New command. (image-mode-map): Bind above new command to "s p". * doc/emacs/files.texi (Image Mode): Document it.
* | Prefer defvar-keymap in image-mode.elStefan Kangas2022-08-181-148/+147
| | | | | | | | | | * lisp/image-mode.el (image-mode-map, image-minor-mode-map): Prefer defvar-keymap.
* | ; * lisp/image-mode.el: Delete commented out image-transform-mode.Stefan Kangas2022-08-181-20/+0
| | | | | | | | | | This mode was added in 2010 but never implemented. It was subsequently commented out in 2012.
* | Merge from origin/emacs-28Stefan Kangas2022-08-181-10/+10
|\| | | | | | | | | | | | | ef1e68f11d * lisp/image-mode.el (image-mode-as-hex): Fix toggle instr... dc0fce3a7d ; lisp/image-mode.el: Fix typo. 254ba1d3e5 * lisp/image-mode.el: Improve commentary. ac43ac1af9 cl-reduce doc string improvement
| * * lisp/image-mode.el (image-mode-as-hex): Fix toggle instructions.Stefan Kangas2022-08-181-7/+3
| |
| * ; lisp/image-mode.el: Fix typo.Stefan Kangas2022-08-181-3/+3
| |
| * * lisp/image-mode.el: Improve commentary.Stefan Kangas2022-08-181-4/+8
| |
* | Quote some literal keys to get help-key-binding faceStefan Kangas2022-07-031-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/align.el (align): * lisp/bindings.el (undo-repeat-map): * lisp/calc/calc-embed.el (calc-do-embedded): * lisp/calc/calc-prog.el (calc-user-define-invocation): * lisp/calc/calc-yank.el (calc--edit-mode): * lisp/comint.el (comint-history-isearch) * lisp/dired.el (dired-mode): * lisp/emulation/viper.el (viper-mode): * lisp/erc/erc-button.el (erc-button-face): * lisp/erc/erc-track.el (erc-track-enable-keybindings): * lisp/gnus/gnus-art.el (gnus-article-button-face): * lisp/gnus/gnus-eform.el (gnus-edit-form): * lisp/gnus/gnus-sum.el (gnus-summary-stop-at-end-of-message) (gnus-summary-goto-unread): * lisp/icomplete.el (icomplete-show-matches-on-no-input): * lisp/image-mode.el (image-scroll-up): * lisp/international/iso-transl.el (iso-transl-set-language): * lisp/isearch.el (isearch-forward-regexp): * lisp/misc.el (butterfly): * lisp/outline.el (outline-minor-mode-cycle-filter) (outline-minor-mode-cycle): * lisp/progmodes/grep.el (rgrep): * lisp/progmodes/gud.el (gud-gdb-repeat-map, gud-sdb-repeat-map) (gud-dbx-repeat-map, gud-xdb-repeat-map, gud-perldb-repeat-map) (gud-pdb-repeat-map, gud-guiler-repeat-map, gud-jdb-repeat-map): * lisp/progmodes/idlw-shell.el (idlwave-shell-graphics-window-size) (idlwave-shell-mode): * lisp/progmodes/idlwave.el (idlwave-shell-debug-modifiers) (idlwave-list-shell-load-path-shadows): * lisp/progmodes/python.el (python-shell-get-process-or-error): * lisp/repeat.el (repeat-check-key): * lisp/replace.el (query-replace, query-replace-regexp) (read-regexp): * lisp/simple.el (read-extended-command-predicate): * lisp/tab-bar.el (tab-bar-switch-repeat-map) (tab-bar-move-repeat-map): * lisp/term.el (ansi-term): * lisp/textmodes/reftex-index.el (reftex-index-phrases-set-macro-key): * lisp/vc/emerge.el (emerge-scroll-left, emerge-scroll-right): * lisp/windmove.el: * lisp/winner.el (winner-mode): Quote literal keys to get 'help-key-binding' face. * lisp/comint.el (comint-insert-previous-argument): Use regular quotes.
* | Fix some declare-after-interactive functionsLars Ingebrigtsen2022-06-171-1/+1
| | | | | | | | | | | | | | | | | | | | * lisp/progmodes/opascal.el (opascal-new-comment-line): * lisp/image-mode.el (image-transform-fit-to-height): * lisp/help-fns.el (help-fns-edit-variable): * lisp/gnus/gnus-salt.el (gnus-pick-start-reading): * lisp/eshell/esh-util.el (eshell-for): * lisp/ldefs-boot.el (view-return-to-alist-update): Fix warnings about declare after interactive.
* | Explain better what the interactive prefix does in scroll-down/upLars Ingebrigtsen2022-05-071-6/+20
| | | | | | | | | | | | * lisp/window.el (scroll-up-command, scroll-down-command): * lisp/image-mode.el (image-scroll-up, image-scroll-down): Actually explain what the interactive prefix does (bug#44503).
* | More robust checks for directory buffers in image-modeMichael Albinus2022-04-011-2/+5
| | | | | | | | | | * lisp/image-mode.el (image-mode--directory-buffers): Apply more robust checks for directory buffers. (Bug#54606)
* | Fix image-mode-fit-frame some moreLars Ingebrigtsen2022-03-241-22/+12
| | | | | | | | | | | | * lisp/image-mode.el (image-mode-fit-frame): Use frame-text-width and fit-frame-to-buffer instead of computing things ourselves (bug#37630). This makes things work better across platforms.
* | Fix image-mode-fit-frame resizingLars Ingebrigtsen2022-03-231-15/+17
| | | | | | | | | | * lisp/image-mode.el (image-mode-fit-frame): Use pixel sizes instead of lines/columns to get more accurate resizing (bug#37630).
* | Make `n' in image-mode work more reliably with external formatsLars Ingebrigtsen2022-03-211-1/+8
| | | | | | | | | | | | | | | | | | * lisp/image-mode.el (image-mode): Init the external machinery so that commands like `n' work for those files. * lisp/image/image-converter.el (image-converter-initialize): Factored out into own function. (image-convert-p): Use it. (image-convert): Ditto.
* | Merge from origin/emacs-28Stefan Kangas2022-02-221-3/+5
|\| | | | | | | | | | | | | | | 666e40a109 Fix 'display-line-numbers-mode' in hide-show buffers 68d134cf0f Don't check whether a deleted window is deletable (Bug#54028) b38223a844 A friendlier error message from image-mode in an empty buffer b7a651ba37 Update to Org 9.5.2-17-gea6b74 3a8c3f7abd ; Don't reference obsolete variables in edebug.el
| * A friendlier error message from image-mode in an empty bufferEli Zaretskii2022-02-211-3/+5
| | | | | | | | | | * lisp/image-mode.el (image-mode): Handle the case where the empty buffer doesn't visit a file (Bug#54084)
* | Merge from origin/emacs-28Eli Zaretskii2022-01-011-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 836be7a112 ; * etc/refcards/ru-refcard.tex: Update Copyright year. 86cbc6ee4a * lisp/net/tramp-sh.el: Adapt copyright year ebe8772f65 ; Minor fixes related to copyright years 23c1ee6989 ; * test/manual/etags/ETAGS.good_N: Adjust to copyright ye... 8d3fc7ec89 * src/xfaces.c (face_for_font): Make 'hash' be uintptr_t. 19dcb237b5 ; Add 2022 to copyright years. # Conflicts: # etc/NEWS # etc/refcards/ru-refcard.tex # lib/cdefs.h # lisp/erc/erc-dcc.el # lisp/erc/erc-imenu.el # lisp/erc/erc-replace.el # lisp/image-dired.el # lisp/progmodes/xref.el # m4/alloca.m4 # m4/byteswap.m4 # m4/errno_h.m4 # m4/getopt.m4 # m4/gnulib-common.m4 # m4/inttypes.m4 # m4/stddef_h.m4 # m4/stdint.m4 # m4/sys_socket_h.m4
| * ; Add 2022 to copyright years.Eli Zaretskii2022-01-011-1/+1
| |
* | Remove obsolete values from image-mode-auto-resizeStefan Kangas2021-12-071-6/+4
| | | | | | | | | | | | | | | | | | * lisp/image-mode.el (image-auto-resize): Remove obsolete options fit-height and fit-width. (image-transform-resize): Document that fit-height and fit-width are obsolete. (image-auto-resize-max-scale-percent): Fix defcustom const :tag.
* | image-mode: Advertize viewing as text less eagerlyStefan Kangas2021-12-031-17/+26
| | | | | | | | | | | | | | | | | | * lisp/image-mode.el (image-text-based-formats): New defcustom. (image-mode--setup-mode): Don't show message to show image as text unless it is a text based image format. Don't mention key binding for editing as hex. (Bug#51961) (image-mode-as-text): Don't mention key binding for editing as hex. (image-mode-as-hex): Minor cleanup.
* | ; * lisp/image-mode.el (image-mode): Minor doc fix.Stefan Kangas2021-12-031-2/+3
| |
* | New user option image-auto-resize-max-scale-percentStefan Kangas2021-11-061-1/+26
| | | | | | | | | | | | | | * lisp/image-mode.el (image-auto-resize-max-scale-percent): New user option to limit how much 'fit-window' will scale up an image. (image--scale-within-limits-p): New function. (image-toggle-display-image): Respect above new user option.
* | New command image-transform-fit-to-windowStefan Kangas2021-11-061-17/+40
|/ | | | | | | | | | | | | | | | | * lisp/image-mode.el (image-auto-resize, image-transform-resize): Add new value 'fit-window', meaning to scale the image up or down to fit the window. (Bug#) (image-transform-fit-to-window): New command. (image-transform-fit-to-height, image-transform-fit-to-width): Make obsolete in favor of above new command. (image-mode-map): Bind "s w" to 'image-transform-fit-to-window'. Move binding for obsolete command 'image-transform-fit-to-width' to "s i". (image-mode-map): Add menu entry for 'image-transform-fit-to-window'. Remove menu entries for above obsolete commands. * doc/emacs/files.texi (Image Mode): Update documentation. (image-transform-fit-both): Doc fix.
* ; Minor stylistic fixes found by checkdocStefan Kangas2021-09-161-2/+2
|
* * lisp/**/*.el: Avoid positional args to `define-minor-mode`Stefan Monnier2021-04-111-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Back in Emacs-21.1, `define-minor-mode` grew keywords arguments to replace its old positional arguments. Let's make sure we don't use the old-style any more. * lisp/org/ox-beamer.el (org-beamer-mode-map): Move initialization into declaration. (org-beamer-mode): * lisp/textmodes/tildify.el (tildify-mode): * lisp/textmodes/sgml-mode.el (html-autoview-mode): * lisp/textmodes/rst.el (rst-minor-mode): * lisp/textmodes/remember.el (remember-notes-mode): * lisp/textmodes/ispell.el (ispell-minor-mode): * lisp/tar-mode.el (tar-subfile-mode): * lisp/strokes.el (strokes-mode): * lisp/so-long.el (so-long-minor-mode): * lisp/shell.el (shell-dirtrack-mode): * lisp/scroll-all.el (scroll-all-mode): * lisp/ruler-mode.el (ruler-mode): * lisp/rect.el (rectangle-mark-mode): * lisp/progmodes/sh-script.el (sh-electric-here-document-mode): * lisp/outline.el (outline-minor-mode): * lisp/org/org.el (org-cdlatex-mode): * lisp/org/org-table.el (org-table-header-line-mode) (org-table-follow-field-mode, orgtbl-mode): * lisp/org/org-src.el (org-src-mode): * lisp/org/org-list.el (org-list-checkbox-radio-mode): * lisp/org/org-indent.el (org-indent-mode): * lisp/org/org-capture.el (org-capture-mode): * lisp/obsolete/pc-select.el (pc-selection-mode): * lisp/obsolete/iswitchb.el (iswitchb-mode): * lisp/net/rcirc.el (rcirc-omit-mode, rcirc-multiline-minor-mode) (rcirc-track-minor-mode): * lisp/net/goto-addr.el (goto-address-mode, goto-address-prog-mode): * lisp/image-mode.el (image-minor-mode): * lisp/ibuf-ext.el (ibuffer-auto-mode): * lisp/gnus/gnus-cite.el (gnus-message-citation-mode): * lisp/font-core.el (font-lock-mode): * lisp/erc/erc.el (define-erc-module): * lisp/erc/erc-track.el (erc-track-minor-mode): * lisp/erc/erc-fill.el (erc-fill-mode): * lisp/epa-mail.el (epa-mail-mode): * lisp/emacs-lisp/checkdoc.el (checkdoc-minor-mode): * lisp/dirtrack.el (dirtrack-mode, dirtrack-debug-mode): * lisp/dired-aux.el (dired-isearch-filenames-mode): * lisp/cedet/semantic/idle.el (semantic-idle-scheduler-mode): * lisp/cedet/semantic/decorate/mode.el (semantic-decoration-mode): * lisp/autoarg.el (autoarg-mode, autoarg-kp-mode): * lisp/vc/pcvs.el (cvs-minor-mode): Avoid old-style positional args to `define-minor-mode`.
* Don't call `image-toggle-display-text' when togglingLin Sun2021-04-051-2/+3
| | | | | *lisp/image-mode.el (image-mode-to-text): Do not call the image-toggle-display-text twice when toggle image display (bug#47521).
* Rename to image--transform-smoothing in image-mode.elLars Ingebrigtsen2021-03-121-5/+5
| | | | | | * lisp/image-mode.el (image--transform-smoothing): Rename from image-transform-smoothing. (image-transform-properties, image-transform-reset): Adjust usage.
* ; Fix some typos.Basil L. Contovounesios2021-03-111-2/+2
|
* Enable selectable image smoothing (bug#38394)Alan Third2021-03-101-2/+18
| | | | | | | | | | | | | | | * lisp/doc-view.el (doc-view-insert-image): Always use smoothing in docview. * lisp/image-mode.el (image-transform-smoothing): New variable. (image-mode-map): Add smoothing binding. (image-transform-properties): Apply smoothing when requested. (image-transform-set-smoothing): New function. (image-transform-reset): Reset smoothing. * src/image.c (image_set_transform): Use new :transform-smoothing attribute. (syms_of_image): Add :transform-smoothing attribute. * doc/lispref/display.texi (Image Descriptors): Document new :transform-smoothing property.
* Merge from origin/emacs-27Glenn Morris2021-02-191-1/+3
|\ | | | | | | | | | | | | | | | | | | | | 8e8b46ef81 (origin/emacs-27) More accurate documentation of the "r" i... dcb2015a5b Mention the GNU Kind Communications Guidelines in the FAQ 9882e63eea ; * CONTRIBUTE: Another wording change regarding tiny chan... 850f18ef23 Allow newlines in password prompts again in comint c977370dd7 Avoid point movement when visiting image files da64a257a4 ; * CONTRIBUTE: Yet another clarification of significant c... d03f2a6ee9 Avoid assertion violation in callproc.c dcc00bbb19 ; * CONTRIBUTE: Clarify the "15-lines" rule a bit more.
| * Avoid point movement when visiting image filesEli Zaretskii2021-02-161-1/+3
| | | | | | | | | | | | * lisp/image-mode.el (image-toggle-display-image): Preserve point around the call to exif-parse-buffer, to prevent it from moving into the image data. (Bug#46552)
| * Update copyright year to 2021Paul Eggert2021-01-011-1/+1
| | | | | | | | Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
* | Revert "Fix problem of point movement in image-mode"Lars Ingebrigtsen2021-02-161-2/+0
| | | | | | | | | | | | This reverts commit 7c7377288a125ef47f2b422cf131f044a3b418e1. This is fixed differently in Emacs 27.
* | Fix problem of point movement in image-modeLars Ingebrigtsen2021-02-161-0/+2
| | | | | | | | | | | | * lisp/image-mode.el (image-mode): Switch disable-point-adjustment on, otherwise `C-c C-c' will move point around oddly. (image-toggle-display): Ensure that point is on the image (bug#46552).
* | Don't resize images in image-mode if we have a rotationLars Ingebrigtsen2021-02-161-0/+6
| | | | | | | | | | | | * lisp/image-mode.el (image-fit-to-window): Don't resize of we have a manually rotated imaged (and explain the resizing logic a bit).