-- 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: 08808048f2605857d1b41e41ae9d9dd650f2c559:
path_to:
revision_to:

git.thebackupbox.net

rxvt-unicode-sixel

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

commit 08808048f2605857d1b41e41ae9d9dd650f2c559
Author: Emanuele Giaquinta <emanuele.giaquinta@gmail.com>
Date:   Tue Jan 1 21:14:39 2008 +0000

    Revert 2007-12-29 change and move scrollbar_len from rxvt_term to scrollBar_t.

diff --git a/Changes b/Changes

index 7c8c2e75993886b75e6d70aa68bd5db70c7a2bbd..

index ..bb07eb1752da904bafd4fd3140a53307189661cf 100644

--- a/Changes
+++ b/Changes
@@ -17,8 +17,6 @@ WISH: load system-wide config file even if we don't have one
 WISH: look into XAddConnectionWatch, does anybody need that?
 DUMB: support tex fonts

-TODO: with -ip, the scorllbar doesn't refresh after resizing.
-
 8.9  Mon Dec 24 07:51:40 CET 2007
 	- fix the issue where urxvtd would not immediately close a window
           when the command exited but only on the next X event.
diff --git a/src/scrollbar.C b/src/scrollbar.C

index 77f9f18f3c6a47725cbc50e4215fa729cbfe4918..

index ..e299cc3c7bcd35f7a63f74a7fa6d2dddb21e57d9 100644

--- a/src/scrollbar.C
+++ b/src/scrollbar.C
@@ -147,7 +147,6 @@ rxvt_term::scrollbar_show (int update)
   int             ret = 0;
 #ifdef HAVE_SCROLLBARS
   int             top, bot, len, adj;
-  int             scrollbar_len = 0;

   if (!scrollBar.state)
     return 0;
@@ -160,9 +159,9 @@ rxvt_term::scrollbar_show (int update)
       adj = (((bot - top) * scrollbar_size ()) % len) > 0 ? 1 : 0;

       scrollBar.top = (scrollBar.beg + (top * scrollbar_size ()) / len);
-      scrollbar_len = ((bot - top) * scrollbar_size ()) / len +
+      scrollBar.len = ((bot - top) * scrollbar_size ()) / len +
                       scrollbar_minheight () + adj;
-      scrollBar.bot = (scrollBar.top + scrollbar_len);
+      scrollBar.bot = (scrollBar.top + ScrollBar.len);
       /* no change */
       if (scrollBar.top == scrollBar.last_top
           && scrollBar.bot == scrollBar.last_bot
@@ -170,7 +169,7 @@ rxvt_term::scrollbar_show (int update)
         return 0;
     }

-  ret = (this->*scrollBar.update) (update, scrollBar.last_top, scrollBar.last_bot, scrollbar_len);
+  ret = (this->*scrollBar.update) (update, scrollBar.last_top, scrollBar.last_bot, scrollBar.len);

   scrollBar.last_top = scrollBar.top;
   scrollBar.last_bot = scrollBar.bot;
diff --git a/src/scrollbar.h b/src/scrollbar.h

index aee19713a0cd51cff335ad621e93e6f1e29b968a..

index ..a53bf53b0cdb2361474f3c0b24213dc44c72ec0e 100644

--- a/src/scrollbar.h
+++ b/src/scrollbar.h
@@ -18,6 +18,7 @@ typedef struct {
   int             last_bot;     /* scrollbar last bottom position           */
   int             last_top;     /* scrollbar last top position              */
   int             last_state;   /* scrollbar last state                     */
+  int             len;
   unsigned char   align;
   Window          win;
   int             (rxvt_term::*update)(int, int, int, int);

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

-- Response ended

-- Page fetched on Sun Jun 2 12:02:46 2024