-- Leo's gemini proxy

-- Connecting to git.thebackupbox.net:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

repo: rxvt-unicode-sixel
action: commit
revision:
path_from:
revision_from: b775a6433ad32ff39cb0384a98a97610183d20f1:
path_to:
revision_to:

git.thebackupbox.net

rxvt-unicode-sixel

git://git.thebackupbox.net/rxvt-unicode-sixel

commit b775a6433ad32ff39cb0384a98a97610183d20f1
Author: Emanuele Giaquinta <emanuele.giaquinta@gmail.com>
Date:   Sun Oct 3 20:48:34 2010 +0000

    Recompute the bg image on resize if tiling is requested and the image
    is cropped.

diff --git a/src/background.C b/src/background.C

index 6c9be34379a0db93b5732d0aa85cd1f098b7b320..

index ..f8f3b539b91c89840581465b373372e81e000881 100644

--- a/src/background.C
+++ b/src/background.C
@@ -140,8 +140,7 @@ bgPixmap_t::window_size_sensitive ()
 # ifdef BG_IMAGE_FROM_FILE
   if (have_image)
     {
-      if (h_scale != 0 || v_scale != 0
-          || h_align != 0 || v_align != 0)
+      if (flags & sizeSensitive)
         return true;
     }
 # endif
@@ -474,6 +473,12 @@ bgPixmap_t::get_image_geometry (int image_width, int image_height, int &w, int &

   if (v_align != rootAlign)
     y = make_align_position (v_align, target_height, h > 0 ? h : image_height);
+
+  flags &= ~sizeSensitive;
+  if (h_scale != 0 || v_scale != 0
+      || h_align != 0 || v_align != 0
+      || image_width > target_width || image_height > target_height)
+    flags |= sizeSensitive;
 }

 #  ifdef HAVE_AFTERIMAGE
diff --git a/src/background.h b/src/background.h

index e92208d0eb2cfbe631b9b56b61ea6d80f4a28277..

index ..3456e15aa453883c2c732e0d6b99b0e0edca8f0a 100644

--- a/src/background.h
+++ b/src/background.h
@@ -41,6 +41,7 @@ struct bgPixmap_t
     isVtOrigin      = 1 << 18,  /* if set pixmap has origin at corner of
                                    vt window instead of parent[0]! */
     hasChanged      = 1 << 19,
+    sizeSensitive   = 1 << 20,
   };

   unsigned int flags;

-----END OF PAGE-----

-- Response ended

-- Page fetched on Sun Jun 2 11:11:49 2024