After cropping a .jpg image in the home directory (I'll attach a sample, public domain one soon) and cancelling/denying the crop operation (so it's just the original image), the preview icon shows the cropped version in the directory browser Reproducible: Always Steps to Reproduce: 1. Copy cupcakes.jpg to ~. 2. Run gwenview ~ 3. Select cupcakes.jpg . 4. Crop it using Edit->crop and the crop button. 5. Select undo. 6. Press the "Browse" button in the toolbar. Actual Results: The cropped image is shown. Expected Results: The uncropped image should be shown. shlomif@telaviv1:~/Download/unpack/kde/gwenview/gwenview$ git log -1 commit 68a5acbe6e12f5a1e84d9ccefed668735744cbfb Author: Shlomi Fish <shlomif@iglu.org.il> Date: Sat Nov 14 16:13:56 2015 +0100 Enable gwenview to build against the new versions of libkipi (as well as older ones) This patch allows gwenview to build against the new versions of libkipi, and retains compatibility with older ones. See https://mail.kde.org/pipermail/release-team/2015-November/009108.html REVIEW: 125986 Also happens with gwenview-15.11.80-2.mga6
Created attachment 96228 [details] An offending file, but I tested a different image.
Hi all! I noticed it also happens with scaling an image and with other operations. Here's a proposed patch - I'm not sure it's the best way to fix it - https://git.reviewboard.kde.org/r/126678/ .
Can't reproduce in Gwenview 17.11.70 in KDE Neon.
I can still reproduce using the provided steps. The browse mode shows the cropped version after undoing the crop.
Git commit f78e5e4b05b7e5a04690dceb5e2203b0ef41bf66 by Peter Mühlenpfordt. Committed on 09/04/2018 at 06:23. Pushed by muhlenpfordt into branch 'Applications/18.04'. Fix thumbnail update after undo Summary: After editing an image multiple times (e.g. rotate) and then undoing, the thumbnail displays a previous edit state between the undos. This is caused by connecting to `QUndoStack` signal `indexChanged` which emits before some undo operations are finished and the new thumbnail is created too early. This patch emits the `modified`/`saved` signals for a document only after the undo image operation is finished. It also solves the problem displaying a wrong thumbnail in another mode after undoing all edits. Depends on D11714 FIXED-IN: 18.04.0 Test Plan: * Open image in Gwenview (View or Browse Mode) * Edit image at least 3 times (e.g. rotate with {key Ctrl R}) * Undo all edits ({key Ctrl Z}) * Thumbnail should always correspond to undo step * Thumbnail should be identical in View, Browse and Fullscreen Mode Reviewers: #gwenview, rkflx Reviewed By: #gwenview, rkflx Subscribers: rkflx, huoni Differential Revision: https://phabricator.kde.org/D11715 M +9 -0 lib/abstractimageoperation.cpp M +2 -0 lib/abstractimageoperation.h M +1 -0 lib/crop/cropimageoperation.cpp M +1 -2 lib/document/document.cpp M +2 -1 lib/document/document.h M +1 -0 lib/redeyereduction/redeyereductionimageoperation.cpp M +1 -0 lib/resize/resizeimageoperation.cpp M +1 -1 lib/thumbnailview/thumbnailview.cpp M +4 -1 lib/transformimageoperation.cpp M +2 -0 tests/auto/documenttest.cpp https://commits.kde.org/gwenview/f78e5e4b05b7e5a04690dceb5e2203b0ef41bf66