summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2024-06-30 11:43:03 +0200
committerBirte Kristina Friesel <derf@finalrewind.org>2024-06-30 11:43:30 +0200
commit1547ccb28eda8120a03c3edc51ca7a5539c75874 (patch)
tree3a80f79e6a75522bafd051bf5b9f126b622339b5
parent08b269d172acc2b4cb9b9336e2cd8097d89ef6a7 (diff)
Fix rotate by 180 degrees bug (patch by wwsmiff, thanks!)
Closes #754 Closes #740 Squashed commit of the following: commit 7770f4cf1a1e7ff86238d67053b22b066e3d38ec Author: wwsmiff <arnav0872@gmail.com> Date: Sun Mar 17 01:54:55 2024 +0530 Remove font file commit 70bc5864817e308d44fea51a409ef68c2bb9e574 Author: wwsmiff <arnav0872@gmail.com> Date: Sun Mar 17 01:54:23 2024 +0530 Fix rotate by 180 degrees bug
-rw-r--r--src/imlib.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/imlib.c b/src/imlib.c
index 143807d..eb3f522 100644
--- a/src/imlib.c
+++ b/src/imlib.c
@@ -1543,9 +1543,11 @@ void feh_edit_inplace(winwidget w, int op)
imlib_image_flip_horizontal();
else {
imlib_image_orientate(op);
- tmp = w->im_w;
- w->im_w = w->im_h;
- w->im_h = tmp;
+ if(op != 2) {
+ tmp = w->im_w;
+ w->im_w = w->im_h;
+ w->im_h = tmp;
+ }
if (FEH_FILE(w->file->data)->info) {
FEH_FILE(w->file->data)->info->width = w->im_w;
FEH_FILE(w->file->data)->info->height = w->im_h;