summaryrefslogtreecommitdiff
path: root/lisp/image-dired.el
Commit message (Collapse)AuthorAgeFilesLines
* Split image-dired.el into several files (part 1/2)Stefan Kangas2022-09-031-3080/+0
| | | | | | | | | | | | | | | | | | | | | Use a git trick to split a file while preserving line history (for "git blame", "git log --follow", etc.): 1) Make exact copies of the original file, in the same commit as moving it. [this commit] 2) Next, trim down the extra copies to contain only the relevant parts. * lisp/image-dired.el: Move from here... * lisp/image/image-dired-dired.el: * lisp/image/image-dired-external.el: * lisp/image/image-dired-tags.el: * lisp/image/image-dired-util.el: * lisp/image/image-dired.el: ...to here. * test/lisp/image-dired-tests.el: Move from here... * test/lisp/image/image-dired-tests.el: ...to here.
* Speed up image-dired-display-imageMorgan Smith2022-08-191-2/+2
| | | | | * lisp/image-dired.el (image-dired-display-image): Open file literally so we don't run image-mode twice. (Bug#57281)
* image-dired: Don't end messages with "."Stefan Kangas2022-07-211-7/+7
| | | | | | | | | | * lisp/image-dired.el (image-dired-toggle-dired-display-properties) (image-dired--on-file-in-dired-buffer) (image-dired-thumbnail-set-image-description) (image-dired-mark-tagged-files) (image-dired-dired-edit-comment-and-tags) (image-dired-modify-mark-on-thumb-original-file): Don't end messages with "." to better comply with '(elisp) Programming Tips'.
* image-dired: Use full name for bookmark handler typeStefan Kangas2022-06-171-1/+1
| | | | | * lisp/image-dired.el (image-dired-bookmark-jump): Use full mode name for bookmark handler type.
* Make anchored regexps work in image-dired-mark-tagged-filesLars Ingebrigtsen2022-05-121-9/+12
| | | | | * lisp/image-dired.el (image-dired-mark-tagged-files): Make anchored regexps work (bug#55375).
* Extend bookmark menu with with handler type columnMatthias Meulien2022-02-171-0/+1
| | | | | | | | | | | | | * lisp/bookmark.el (bookmark-bmenu--revert): Extend table entries with handler type. (bookmark-bmenu-mode): Add handler type column. * lisp/doc-view.el (doc-view-bookmark-jump): Set bookmark handler type. * lisp/help-mode.el (help-bookmark-jump): Set bookmark handler type. * lisp/image-dired.el (image-dired-bookmark-jump): Set bookmark handler type. * lisp/info.el (Info-bookmark-jump): Set bookmark handler type. * lisp/net/eww.el (eww-bookmark-jump): Set bookmark handler type. * lisp/vc/vc-dir.el (vc-dir-bookmark-jump): Set bookmark handler type. * lisp/woman.el (woman-bookmark-jump): Set bookmark handler type.
* Make image-dired-delete-marked more resilientPeter Münster2022-01-201-1/+2
| | | | | * lisp/image-dired.el (image-dired-delete-marked): Don't bug out on empty buffers (bug#53385).
* image-dired: Use MD5 for thumb filename generationStefan Kangas2022-01-141-3/+1
| | | | | * lisp/image-dired.el (image-dired-thumb-name): Revert back to MD5 for file name generation to preserve backwards-compatibility. (Bug#53229)
* 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
| |
* | Merge from origin/emacs-28Stefan Kangas2021-12-101-1/+1
|\| | | | | | | | | | | | | 7a25ba0fde ; * lisp/image-dired.el: Fix typo. dda6337066 emacsclient takes more care about XDG_RUNTIME_DIR 26fb4168b8 ; Prefer HTTPS in more URLs 6b89578524 ; * lisp/progmodes/flymake.el: Update the minimum Emacs ve...
| * ; * lisp/image-dired.el: Fix typo.Stefan Kangas2021-12-101-1/+1
| |
* | image-dired: Show image info in header lineStefan Kangas2021-12-091-25/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-update-header-line): New function to show image information in the header line. (image-dired-display-thumb-properties): Make obsolete. (image-dired-track-thumbnail) (image-dired--display-thumb-properties-fun) (image-dired-forward-image, image-dired-next-line) (image-dired-previous-line, image-dired-beginning-of-buffer) (image-dired-end-of-buffer, image-dired-read-comment): Use image-dired-update-header-line instead of image-dired-display-thumb-properties.
* | image-dired: Go to next image when markingStefan Kangas2021-12-091-19/+37
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-marking-shows-next): New user option to show the next image after marking, unmarking or flagging an image. (image-dired--do-mark-command): New macro. (image-dired-mark-thumb-original-file) (image-dired-unmark-thumb-original-file) (image-dired-flag-thumb-original-file) (image-dired-toggle-mark-thumb-original-file) (image-dired-unmark-all-marks): Use above new macro.
* | image-dired: Remove some TODOsStefan Kangas2021-12-091-9/+0
| | | | | | | | | | | | To the extent that these TODOs are relevant or useful, it would be better to add such features to image-mode directly. * lisp/image-dired.el: Remove some TODOs.
* | image-dired: Navigate from image display bufferStefan Kangas2021-12-081-37/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-mark-thumb-original-file) (image-dired-unmark-thumb-original-file) (image-dired-flag-thumb-original-file) (image-dired-toggle-mark-thumb-original-file) (image-dired-unmark-all-marks) (image-dired-display-next-thumbnail-original) (image-dired-display-previous-thumbnail-original): Make commands usable from image-dired-display-image-mode. (image-dired-display-image-mode-map): Bind above commands. (image-dired--with-thumbnail-buffer): New macro.
* | image-dired: Fix behavior of slideshow commandStefan Kangas2021-12-071-9/+10
| | | | | | | | | | * lisp/image-dired.el (image-dired-slideshow-start): Fix behavior to match documentation. Minor simplification of docstring.
* | Prefer nil to (current-time) when either will doPaul Eggert2021-12-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/timer.el (timer-event-handler, run-at-time): * lisp/gnus/gnus-score.el (gnus-score-date): * lisp/gnus/gnus-search.el (gnus-search-query-parse-date) (gnus-search-imap-handle-date): * lisp/gnus/gnus-sum.el (gnus-user-date) (gnus-summary-create-article): * lisp/image-dired.el (image-dired-create-thumb-1): * lisp/image/gravatar.el (gravatar-retrieve) (gravatar--prune-cache): * lisp/net/dbus.el (dbus-monitor-handler): * lisp/net/tramp-gvfs.el (tramp-gvfs-handle-set-file-times): * lisp/net/tramp-sh.el (tramp-sh-handle-set-file-times): * lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-set-file-times): * test/lisp/autorevert-tests.el (auto-revert--wait-for-revert) (auto-revert-tests--write-file, auto-revert-test--wait-for): * test/lisp/net/tramp-tests.el (tramp--test-print-duration): Prefer nil to (current-time) when either will do, as this avoids some consing. Similarly, prefer omitting (current-time) arg when this is equivalent.
* | image-dired: Use string-match-p in one caseStefan Kangas2021-12-061-1/+1
| | | | | | | | | | * lisp/image-dired.el (image-dired-get-thumbnail-image): Use string-match-p.
* | image-dired: Don't disable mouse draggingStefan Kangas2021-12-061-5/+0
| | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode-map): Don't disable mouse dragging. (Bug#52201)
* | image-dired: Improve some messagesStefan Kangas2021-11-201-7/+7
| | | | | | | | | | | | * lisp/image-dired.el (image-dired-dir) (image-dired-create-thumb-1): Improve messages. (image-dired-rotate-original): Signal 'user-error' instead of 'error'.
* | Revert "* lisp/image-dired.el: Remove unnecessary 'declare-function'."Stefan Kangas2021-11-181-0/+2
| | | | | | | | | | | | | | | | This reverts commit e0261d4a0cf2a23d32b51b84870a3a75f8273c7c. This commit gives warnings on builds --without-x. Problem pointed out by Glenn Morris <rgm@gnu.org> in: https://lists.gnu.org/r/emacs-devel/2021-11/msg01278.html
* | * lisp/image-dired.el: Remove unnecessary 'declare-function'.Stefan Kangas2021-11-171-2/+0
| |
* | image-dired: Quote function symbols as suchStefan Kangas2021-11-121-50/+50
| | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode-line-up-map) (image-dired-thumbnail-mode-tag-map) (image-dired-thumbnail-mode-map, image-dired-minor-mode-map): Quote function symbols as such.
* | Make image-dired-thumbnail-mode non-interactiveStefan Kangas2021-11-121-0/+1
| | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode): No longer interactive, as it only makes sense in a specially prepared buffer.
* | image-dired: Revamp slideshow functionalityStefan Kangas2021-11-121-27/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-slideshow-delay): New defcustom. (image-dired--slideshow-initial): New defvar. (image-dired-slideshow-start): Don't show any prompts when starting a slideshow, unless user gave a negative prefix argument. Use the value of the above new defcustom as the default delay. (image-dired-slideshow-stop): Don't count number of images. Instead, continue the slideshow until the next command. (image-dired-slideshow-step): Use the correct buffer. (image-dired-slideshow-count, image-dired-slideshow-times): Make obsolete. (image-dired--slideshow-timer): Rename from 'image-dired-slideshow-timer'. Make the old name into an obsolete variable alias. (image-dired-display-image-mode-map) (image-dired-thumbnail-mode-map): Bind 'image-dired-slideshow-start' to "S". (image-dired-thumbnail-mode-menu): Add 'image-dired-slideshow-start'.
* | image-dired: Improve thumbnail mode menuStefan Kangas2021-11-121-17/+14
| | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode-menu): Improve menu with more logical ordering and better naming.
* | ; * lisp/image-dired.el: Add some basic sections.Stefan Kangas2021-11-081-8/+47
| | | | | | | | | | | | | | This file is currently rather hard to follow due to things just being thrown in at random by many different contributors, with seemingly no overall plan or idea. This is the first step towards giving it some kind of organization.
* | image-dired: Set window-resize-pixelwise to tStefan Kangas2021-11-081-0/+1
| | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode): Set 'window-resize-pixelwise' to t.
* | ; Fix doc strings of a recent commitEli Zaretskii2021-11-051-4/+4
| | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-gallery-image-root-url) (image-dired-gallery-thumb-image-root-url) (image-dired-gallery-dir): Don't use "path" for file names and URLs.
* | image-dired: Delete commented out codeStefan Kangas2021-11-051-17/+0
| | | | | | | | | | | | * lisp/image-dired.el: Delete broken and commented out speedbar code; it is not clear what, if anything, it is supposed to do. If anyone wants to work on this, they are better off starting from scratch.
* | image-dired: New defgroup and section for gallery supportStefan Kangas2021-11-051-55/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el: Add new section header "Gallery support" to improve file organization. Move relevant TODO:s there. (image-dired-gallery): New defgroup. (image-dired-gallery-dir, image-dired-gallery-image-root-url) (image-dired-gallery-thumb-image-root-url) (image-dired-gallery-hidden-tags): Add options to above new defgroup. (image-dired-add-to-file-comment-list) (image-dired-create-gallery-lists) (image-dired-add-to-tag-file-lists, image-dired-hidden-p): Rename to... (image-dired--add-to-file-comment-list) (image-dired--create-gallery-lists) (image-dired--add-to-tag-file-lists, image-dired--hidden-p): ...this, to make it more clear that these functions are internal. Make the old names obsolete function aliases. (image-dired-add-to-tag-file-list): Make unused function obsolete.
* | ; Fix typoStefan Kangas2021-11-041-1/+1
| | | | | | | | | | * lisp/image-dired.el (image-dired-display-current-image-full): Fix typo.
* | image-dired: Set default-directory in thumbnail bufferStefan Kangas2021-11-041-0/+1
| | | | | | | | | | * lisp/image-dired.el (image-dired-show-all-from-dir): Set default-directory. This fixes e.g. 'dired-jump'.
* | Make image-dired-display-image-mode inherit from image-modeStefan Kangas2021-11-041-171/+123
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-display-image-mode): Inherit from 'image-mode'. (Bug#10758) (image-dired-display-image): Don't generate a temporary image, which is no longer needed with the above change. (image-dired-display-thumbnail-original-image) (image-dired-dired-display-image) (image-dired-mouse-display-image): Simplify. (image-dired-temp-image-file) (image-dired-cmd-create-temp-image-program) (image-dired-cmd-create-temp-image-options) (image-dired-display-window-width-correction) (image-dired-display-window-height-correction) (image-dired-display-window-width) (image-dired-display-window-height) (image-dired-display-current-image-full) (image-dired-display-current-image-sized) (image-dired-window-height-pixels): Make obsolete. (image-dired-create-display-image-buffer): Make into obsolete function alias for 'ignore'. (image-dired-display-image-mode-map): Simplify by removing things duplicated from `image-mode-map'. Disable some commands from `image-mode-map' that doesn't make sense for Image-Dired. (image-dired-display-image-mode-menu): Remove menu, as it no longer contains anything useful. (image-dired-minor-mode): * doc/emacs/dired.texi (Image-Dired): Update documentation for the above change.
* | ; * lisp/image-dired.el: Remove redundant :group args.Stefan Kangas2021-11-031-2/+0
| |
* | image-dired: Add face for flagged filesStefan Kangas2021-11-031-15/+47
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-thumb-mark): New defface. (image-dired-thumb-update-marks): Mark flagged file with above new defface. (image-dired-dired-file-marked-p) (image-dired-thumb-file-marked-p): Add optional argument to be used by 'image-dired-*-flagged-p' functions below. (image-dired-dired-file-flagged-p) (image-dired-thumb-file-flagged-p): New defuns. (image-dired-thumb-mark): Improve definition with color classes. (image-dired-thumb-visible-marks): Doc fix.
* | Fix declaration syntax of 'image-dired--on-file-in-dired-buffer'.Philipp Stephani2021-11-031-2/+2
| | | | | | | | | | * lisp/image-dired.el (image-dired--on-file-in-dired-buffer): Fix declaration syntax.
* | image-dired: Improve marking behaviorStefan Kangas2021-11-031-6/+8
| | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-thumb-mark): Use DarkOrange as background to better match the 'dired-marked' face. (image-dired-show-all-from-dir): Disable all marks when entering a full directory. (image-dired-unmark-all-marks): Add mode tag. (image-dired-thumbnail-mode-map): Bind 'image-dired-unmark-all-marks' to "U".
* | image-dired: Cleanup of four commandsStefan Kangas2021-11-031-27/+45
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired--on-file-in-dired-buffer): New macro. (image-dired-mark-thumb-original-file) (image-dired-unmark-thumb-original-file) (image-dired-flag-thumb-original-file) (image-dired-toggle-mark-thumb-original-file): Rewrite using above new macro. (image-dired-modify-mark-on-thumb-original-file): Make obsolete in favor of above new macro.
* | image-dired: Support wrap-around in display-next-thumbnail-originalStefan Kangas2021-11-031-38/+36
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-forward-image): Support negative prefix argument. Optionally wrap-around, which means to continue from first image after reaching the last one and vice versa. (image-dired-backward-image): Reimplement in terms of 'image-dired-forward-image'. (image-dired-display-next-thumbnail-original) (image-dired-display-previous-thumbnail-original): Wrap around; when reaching the last image, continue from the first one. Add optional prefix argument to move more than one image at a time.
* | image-dired: Improve menusStefan Kangas2021-11-031-17/+25
| | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-toggle-append-browsing) (image-dired-toggle-movement-tracking): Improve messages. (image-dired-thumbnail-mode-menu, image-dired-minor-mode-menu): Make toggle entries into checkboxes. Add separators. Remove obsoleted commands accidentally added back in merge.
* | image-dired: Signal error if file is missing on displayStefan Kangas2021-11-031-0/+2
| | | | | | | | | | * lisp/image-dired.el (image-dired-display-image): Signal error if file is missing.
* | image-dired: Move menu definitions to top levelStefan Kangas2021-11-031-64/+62
| | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode-map) (image-dired-display-image-mode-map, image-dired-minor-mode-map): Move menu definitions from here... (image-dired-thumbnail-mode-menu) (image-dired-display-image-mode-menu) (image-dired-minor-mode-menu): ...to these new top level definitions.
* | Merge from origin/emacs-28Glenn Morris2021-10-291-37/+39
|\| | | | | | | | | | | | | f52fa1c150 image-dired: Unreverse accidentally reversed menus # Conflicts: # lisp/image-dired.el
| * image-dired: Unreverse accidentally reversed menusStefan Kangas2021-10-281-38/+38
| | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-thumbnail-mode-map) (image-dired-display-image-mode-map, image-dired-minor-mode-map): In Emacs 26.1 (commits b905454680c7 and bed0373855ea), the menus were converted to use 'easy-menu-define', but they were reversed in the process. Unreverse the menus. (Bug#51446)
* | Do interactive mode tagging in image-dired.elStefan Kangas2021-10-281-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-restore-window-configuration) (image-dired-next-line, image-dired-previous-line) (image-dired-mark-thumb-original-file) (image-dired-unmark-thumb-original-file) (image-dired-flag-thumb-original-file) (image-dired-toggle-mark-thumb-original-file) (image-dired-jump-original-dired-buffer) (image-dired-delete-char, image-dired-refresh-thumb) (image-dired-display-next-thumbnail-original) (image-dired-display-previous-thumbnail-original): Do interactive tagging; these will only work in 'image-dired-thumbnail-mode'.
* | image-dired: Make thumbnail rotation commands obsoleteStefan Kangas2021-10-281-47/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/image-dired.el (image-dired-cmd-rotate-thumbnail-program) (image-dired-cmd-rotate-thumbnail-options) (image-dired-rotate-thumbnail) (image-dired-rotate-thumbnail-left) (image-dired-rotate-thumbnail-right): Make obsolete in favor of 'image-dired-refresh-thumb' and 'image-rotate'. It makes no sense to have destructive thumbnail rotation commands now that Emacs can rotate thumbnails in memory, and it is very fast to just generate a new one reflecting the rotation of the original. (image-dired-thumbnail-mode-map): Remove menu entries and key bindings for above obsolete commands. The rotate right keybinding had already been made ineffective by the local keymap added by 'insert-image'.
* | ; * lisp/image-dired.el: Be more consistent with spelling.Stefan Kangas2021-10-271-9/+9
| |
* | image-dired: Don't show thumbnails if there are no image filesStefan Kangas2021-10-271-12/+13
| | | | | | | | | | * lisp/image-dired.el (image-dired-show-all-from-dir): Don't show thumbnail buffer if there are no image files.