-- 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: 6381040037c9828b1f02fc185d6326e6e5f73cd3:
path_to:
revision_to:

git.thebackupbox.net

rxvt-unicode-sixel

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

commit 6381040037c9828b1f02fc185d6326e6e5f73cd3
Author: Marc Lehmann <schmorp@schmorp.de>
Date:   Tue Jan 17 05:47:42 2006 +0000

    *** empty log message ***

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

index ca38a84cd8c19b9348a1bd369ebfe1043e82a913..

index ..f0226d46c22cfd2ee80d29ae738ba3a5b9a25b1f 100644

--- a/src/command.C
+++ b/src/command.C
@@ -1008,7 +1008,7 @@ rxvt_term::flush ()
           while (row < end_row);
         }

-      scr_refresh (refresh_type);
+      scr_refresh ();
       scrollbar_show (1);
 #ifdef USE_XIM
       IMSendSpot ();
@@ -1070,7 +1070,6 @@ rxvt_term::cont_scroll_cb (time_watcher &w)
   if ((scrollbar_isUp() || scrollbar_isDn()) &&
       scr_page (scrollbar_isUp() ? UP : DN, 1))
     {
-      refresh_type |= SMOOTH_REFRESH;
       want_refresh = 1;
       w.start (w.at + SCROLLBAR_CONTINUOUS_DELAY);
     }
@@ -1084,7 +1083,6 @@ rxvt_term::sel_scroll_cb (time_watcher &w)
   if (scr_page (scroll_selection_dir, scroll_selection_lines))
     {
       selection_extend (selection_save_x, selection_save_y, selection_save_state);
-      refresh_type |= SMOOTH_REFRESH;
       want_refresh = 1;
       w.start (w.at + SCROLLBAR_CONTINUOUS_DELAY);
     }
@@ -1102,7 +1100,6 @@ rxvt_term::slip_wheel_cb (time_watcher &w)
       if (view_start == top_row || view_start == 0)
         mouse_slip_wheel_speed = 0;

-      refresh_type |= SMOOTH_REFRESH;
       want_refresh = 1;
       w.start (w.at + SCROLLBAR_CONTINUOUS_DELAY);
     }
@@ -2102,9 +2099,6 @@ rxvt_term::button_release (XButtonEvent &ev)
     {
       scrollBar.setIdle ();
       scrollbar_show (0);
-#ifndef NO_SCROLLBAR_BUTTON_CONTINUAL_SCROLLING
-      refresh_type &= ~SMOOTH_REFRESH;
-#endif
     }

 #ifdef SELECTION_SCROLLING
@@ -2800,7 +2794,7 @@ rxvt_term::cmd_parse ()
               else
                 {
                   flag = true;
-                  scr_refresh (refresh_type);
+                  scr_refresh ();
                   want_refresh = 1;
                 }
             }
diff --git a/src/rxvt.h b/src/rxvt.h

index 83775f5406ede4625f98afc866066f2e8a7f43fe..

index ..208f3527e00d7f01156740207c3c46bd1e52a68c 100644

--- a/src/rxvt.h
+++ b/src/rxvt.h
@@ -338,10 +338,9 @@ typedef struct _mwmhints {
   */

 enum {
-  NO_REFRESH       = 0   ,  /* Window not visible at all!        */
-  FAST_REFRESH     = 1<<0,  /* Fully exposed window              */
-  SLOW_REFRESH     = 1<<1,  /* Partially exposed window          */
-  SMOOTH_REFRESH   = 1<<2,  /* Do sync'ing to make it smooth     */
+  NO_REFRESH       = 0,  /* Window not visible at all!        */
+  FAST_REFRESH     = 1,  /* Fully exposed window              */
+  SLOW_REFRESH     = 2,  /* Partially exposed window          */
 };

 #ifdef NO_SECONDARY_SCREEN
@@ -702,7 +701,8 @@ enum {
  * MACRO DEFINES
  *****************************************************************************
  */
-#define dDisp			Display *disp = display->display
+#define dLocal(type,name)       type const name = this->name
+#define dDisp			Display *disp = this->display->display

 /* convert pixel dimensions to row/column values.  Everything as int32_t */
 #define Pixel2Col(x)            Pixel2Width((int32_t)(x))
@@ -1423,7 +1423,7 @@ struct rxvt_term : zero_initialized, rxvt_vars {
   void scr_reset ();
   void scr_release ();
   void scr_clear (bool really = false);
-  void scr_refresh (unsigned char refresh_type);
+  void scr_refresh ();
   bool scr_refresh_rend (rend_t mask, rend_t value);
   void scr_erase_screen (int mode);
 #if ENABLE_FRILLS
diff --git a/src/rxvtfont.C b/src/rxvtfont.C

index c1a3584baf05fbdfb8080dac2c7ad4ff24f45857..

index ..bd52e39806245d133b6ea4ccd8d153200ba45f32 100644

--- a/src/rxvtfont.C
+++ b/src/rxvtfont.C
@@ -29,9 +29,6 @@
 #include <wchar.h>
 #include <inttypes.h>

-#define DISPLAY  r->display->display
-#define TGC      r->gc
-
 #define MAX_OVERLAP (4 + 1)	// max. character width in 4ths of the base width

 const struct rxvt_fallback_font {
@@ -155,6 +152,9 @@ static uint16_t extent_test_chars[] = {

 #define NUM_EXTENT_TEST_CHARS (sizeof (extent_test_chars) / sizeof (extent_test_chars[0]))

+#define dTermDisplay Display *disp = term->display->display
+#define dTermGC      GC gc = term->gc
+
 /////////////////////////////////////////////////////////////////////////////

 #if XFT
@@ -248,17 +248,20 @@ rxvt_font::set_name (char *name)
 }

 void
-rxvt_font::clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color)
+rxvt_font::clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color) const
 {
+  dTermDisplay;
+  dTermGC;
+
   if (color == Color_bg)
-    XClearArea (d.display->display, d, x, y, w, h, FALSE);
+    XClearArea (disp, d, x, y, w, h, FALSE);
   else if (color >= 0)
     {
 #if XFT
-      XftDrawRect (d, &r->pix_colors[color].c, x, y, w, h);
+      XftDrawRect (d, &term->pix_colors[color].c, x, y, w, h);
 #else
-      XSetForeground (d.display->display, TGC, r->pix_colors[color]);
-      XFillRectangle (d.display->display, d, TGC, x, y, w, h);
+      XSetForeground (disp, gc, term->pix_colors[color]);
+      XFillRectangle (disp, d, gc, x, y, w, h);
 #endif
     }
 }
@@ -296,7 +299,7 @@ struct rxvt_font_default : rxvt_font {
     return true;
   }

-  bool has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful)
+  bool has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful) const
   {
     careful = false;

@@ -310,7 +313,7 @@ struct rxvt_font_default : rxvt_font {
       return true;

     if (unicode >= 0x2500 && unicode <= 0x259f &&
-        !r->option (Opt_skipBuiltinGlyphs))
+        !term->option (Opt_skipBuiltinGlyphs))
       return true;

     if (IS_COMPOSE (unicode))
@@ -336,11 +339,12 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
                          const text_t *text, int len,
                          int fg, int bg)
 {
-  Display *disp = d.display->display;
+  dTermDisplay;
+  dTermGC;

-  clear_rect (d, x, y, r->fwidth * len, r->fheight, bg);
+  clear_rect (d, x, y, term->fwidth * len, term->fheight, bg);

-  XSetForeground (disp, TGC, r->pix_colors[fg]);
+  XSetForeground (disp, gc, term->pix_colors[fg]);

   while (len)
     {
@@ -354,7 +358,7 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
         ;

       int width = text - tp;
-      int fwidth = r->fwidth * width;
+      int fwidth = term->fwidth * width;

       if (0x2500 <= t && t <= 0x259f)
         {
@@ -363,7 +367,7 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
           uint32_t *b = a + (offs & 15);

           int W = fwidth;
-          int H = r->fheight;
+          int H = term->fheight;

           int x_[16];
           int y_[16];
@@ -381,7 +385,7 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,

           gcv.cap_style = CapButt;
           gcv.line_width = 0;
-          XChangeGC (disp, TGC, GCLineWidth | GCCapStyle, &gcv);
+          XChangeGC (disp, gc, GCLineWidth | GCCapStyle, &gcv);

           while (a < b)
             {
@@ -398,7 +402,7 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
               switch (op)
                 {
                   case 0: // line
-                    XDrawLine (disp, d, TGC, x1, y1, x2, y2);
+                    XDrawLine (disp, d, gc, x1, y1, x2, y2);
                     break;

                   case 1: // rectangle, possibly stippled
@@ -411,23 +415,23 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
                         gcv.ts_x_origin = x;
                         gcv.ts_y_origin = y;

-                        XChangeGC (disp, TGC,
+                        XChangeGC (disp, gc,
                                    GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin,
                                    &gcv);
                       }

-                    XFillRectangle (disp, d, TGC, x1, y1, x2 - x1 + 1, y2 - y1 + 1);
+                    XFillRectangle (disp, d, gc, x1, y1, x2 - x1 + 1, y2 - y1 + 1);

                     if (a)
                       {
                         XFreePixmap (disp, gcv.stipple);
                         gcv.stipple = 0;
                         gcv.fill_style = FillSolid;
-                        XChangeGC (disp, TGC, GCFillStyle, &gcv);
+                        XChangeGC (disp, gc, GCFillStyle, &gcv);
                       }
                     break;
                   case 2: // arc
-                    XDrawArc (disp, d, TGC,
+                    XDrawArc (disp, d, gc,
                               x1 - W/2, y1 - H/2, W-1, H-1,
                               (a - 1) * 90*64, (b - 1) * 90*64);
                     break;
@@ -468,8 +472,8 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
               break;

             default:
-              XDrawRectangle (disp, d, TGC, x + 2, y + 2,
-                              fwidth - 4, r->fheight - 4);
+              XDrawRectangle (disp, d, gc, x + 2, y + 2,
+                              fwidth - 4, term->fheight - 4);
           }

       x += fwidth;
@@ -487,7 +491,7 @@ struct rxvt_font_x11 : rxvt_font {

   bool load (const rxvt_fontprop &prop);

-  bool has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful);
+  bool has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful) const;

   void draw (rxvt_drawable &d, int x, int y,
              const text_t *text, int len,
@@ -509,8 +513,8 @@ rxvt_font_x11::get_property (XFontStruct *f, const char *property, const char *r
 {
   unsigned long value;

-  if (XGetFontProperty (f, XInternAtom (DISPLAY, property, 0), &value))
-    return XGetAtomName (DISPLAY, value);
+  if (XGetFontProperty (f, XInternAtom (term->display->display, property, 0), &value))
+    return XGetAtomName (term->display->display, value);
   else
     return rxvt_strdup (repl);
 }
@@ -541,14 +545,14 @@ rxvt_font_x11::set_properties (rxvt_fontprop &p, XFontStruct *f)
   unsigned long height;

 #if 0
-  if (!XGetFontProperty (f, XInternAtom (DISPLAY, "PIXEL_SIZE", 0), &height))
+  if (!XGetFontProperty (f, XInternAtom (term->display->display, "PIXEL_SIZE", 0), &height))
     return false;
 #else
   height = f->ascent + f->descent;
 #endif

   unsigned long avgwidth;
-  if (!XGetFontProperty (f, XInternAtom (DISPLAY, "AVERAGE_WIDTH", 0), &avgwidth))
+  if (!XGetFontProperty (f, XInternAtom (term->display->display, "AVERAGE_WIDTH", 0), &avgwidth))
     avgwidth = 0;

   char *weight = get_property (f, "WEIGHT_NAME", "medium");
@@ -567,6 +571,7 @@ rxvt_font_x11::set_properties (rxvt_fontprop &p, XFontStruct *f)
 bool
 rxvt_font_x11::set_properties (rxvt_fontprop &p, const char *name)
 {
+  dTermDisplay;
   int slashes = 0;
   const char *comp[13];

@@ -584,7 +589,7 @@ rxvt_font_x11::set_properties (rxvt_fontprop &p, const char *name)
       && (*comp[11] >= '0' && *comp[11] <= '9'))
     return set_properties (p, atoi (comp[6]), comp[2], comp[3], atoi (comp[11]));

-  XFontStruct *f = XLoadQueryFont (DISPLAY, name);
+  XFontStruct *f = XLoadQueryFont (disp, name);

   if (f)
     {
@@ -592,7 +597,7 @@ rxvt_font_x11::set_properties (rxvt_fontprop &p, const char *name)
       // (e.g. if the user did xset fp rehash just when we were searching fonts).
       // in that case, just return garbage.
       bool ret = set_properties (p, f);
-      XFreeFont (DISPLAY, f);
+      XFreeFont (disp, f);
       return ret;
     }
   else
@@ -640,7 +645,7 @@ replace_field (char *buf, const char *name, int index, const char old, const cha
 bool
 rxvt_font_x11::load (const rxvt_fontprop &prop)
 {
-  Display *disp = DISPLAY;
+  dTermDisplay;

   clear ();

@@ -725,7 +730,7 @@ rxvt_font_x11::load (const rxvt_fontprop &prop)
       if (replace_field (fname, list[i], 6, '0', field_str))
         diff += 10; // slightly penalize scalable fonts
       else if (replace_field (fname, list[i], 11, '0', "0"))
-        diff += 300; // more heavily penalize what looks like scaled bitmap fotns
+        diff += 300; // more heavily penalize what looks like scaled bitmap fonts

       if (!set_properties (p, fname))
         continue;
@@ -888,13 +893,13 @@ rxvt_font_x11::clear ()
 {
   if (f)
     {
-      XFreeFont (DISPLAY, f);
+      XFreeFont (term->display->display, f);
       f = 0;
     }
 }

 bool
-rxvt_font_x11::has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful)
+rxvt_font_x11::has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful) const
 {
   uint32_t ch = FROM_UNICODE (cs, unicode);

@@ -963,14 +968,17 @@ rxvt_font_x11::draw (rxvt_drawable &d, int x, int y,
   // yet we are trying to be perfect /.
   // but the result still isn't perfect /.

+  dTermDisplay;
+  dTermGC;
+
   bool slow = this->slow
-              || width != r->fwidth
-              || height != r->fheight;
+              || width  != term->fwidth
+              || height != term->fheight;

-  int base = ascent; // sorry, incorrect: r->fbase;
+  int base = ascent; // sorry, incorrect: term->fbase;

   XGCValues v;
-  v.foreground = r->pix_colors[fg];
+  v.foreground = term->pix_colors[fg];
   v.font = f->fid;

   if (enc2b)
@@ -979,30 +987,30 @@ rxvt_font_x11::draw (rxvt_drawable &d, int x, int y,

       if (bg == Color_bg && !slow)
         {
-          v.background = r->pix_colors[bg];
-          XChangeGC (d.display->display, TGC, GCForeground | GCBackground | GCFont, &v);
-          XDrawImageString16 (d.display->display, d, TGC, x, y + base, xc, len);
+          v.background = term->pix_colors[bg];
+          XChangeGC (disp, gc, GCForeground | GCBackground | GCFont, &v);
+          XDrawImageString16 (disp, d, gc, x, y + base, xc, len);
         }
       else
         {
-          clear_rect (d, x, y, r->fwidth * len, r->fheight, bg);
+          clear_rect (d, x, y, term->fwidth * len, term->fheight, bg);

-          XChangeGC (d.display->display, TGC, GCForeground | GCFont, &v);
+          XChangeGC (disp, gc, GCForeground | GCFont, &v);

           if (slow)
             {
               do
                 {
                   if (xc->byte1 || xc->byte2)
-                    XDrawString16 (d.display->display, d, TGC, x, y + base, xc, 1);
+                    XDrawString16 (disp, d, gc, x, y + base, xc, 1);

-                  x += r->fwidth;
+                  x += term->fwidth;
                   xc++; len--;
                 }
               while (len);
             }
           else
-            XDrawString16 (d.display->display, d, TGC, x, y + base, xc, len);
+            XDrawString16 (disp, d, gc, x, y + base, xc, len);
         }
     }
   else
@@ -1011,30 +1019,30 @@ rxvt_font_x11::draw (rxvt_drawable &d, int x, int y,

       if (bg == Color_bg && !slow)
         {
-          v.background = r->pix_colors[bg];
-          XChangeGC (d.display->display, TGC, GCForeground | GCBackground | GCFont, &v);
-          XDrawImageString (d.display->display, d, TGC, x, y + base, xc, len);
+          v.background = term->pix_colors[bg];
+          XChangeGC (disp, gc, GCForeground | GCBackground | GCFont, &v);
+          XDrawImageString (disp, d, gc, x, y + base, xc, len);
         }
       else
         {
-          clear_rect (d, x, y, r->fwidth * len, r->fheight, bg);
+          clear_rect (d, x, y, term->fwidth * len, term->fheight, bg);

-          XChangeGC (d.display->display, TGC, GCForeground | GCFont, &v);
+          XChangeGC (disp, gc, GCForeground | GCFont, &v);

           if (slow)
             {
               do
                 {
                   if (*xc)
-                    XDrawString (d.display->display, d, TGC, x, y + base, xc, 1);
+                    XDrawString (disp, d, gc, x, y + base, xc, 1);

-                  x += r->fwidth;
+                  x += term->fwidth;
                   xc++; len--;
                 }
               while (len);
             }
           else
-            XDrawString (d.display->display, d, TGC, x, y + base, xc, len);
+            XDrawString (disp, d, gc, x, y + base, xc, len);
         }
     }
 }
@@ -1056,7 +1064,7 @@ struct rxvt_font_xft : rxvt_font {
              const text_t *text, int len,
              int fg, int bg);

-  bool has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &carefull);
+  bool has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &carefull) const;

 protected:
   XftFont *f;
@@ -1067,7 +1075,7 @@ rxvt_font_xft::clear ()
 {
   if (f)
     {
-      XftFontClose (DISPLAY, f);
+      XftFontClose (term->display->display, f);
       f = 0;
     }
 }
@@ -1095,7 +1103,7 @@ rxvt_font_xft::properties ()
 bool
 rxvt_font_xft::load (const rxvt_fontprop &prop)
 {
-  Display *disp = DISPLAY;
+  dTermDisplay;

   clear ();

@@ -1132,7 +1140,7 @@ rxvt_font_xft::load (const rxvt_fontprop &prop)
   set_name ((char *)FcNameUnparse (p));

   XftResult result;
-  FcPattern *match = XftFontMatch (disp, r->display->screen, p, &result);
+  FcPattern *match = XftFontMatch (disp, term->display->screen, p, &result);

   FcPatternDestroy (p);

@@ -1240,11 +1248,11 @@ rxvt_font_xft::load (const rxvt_fontprop &prop)
 }

 bool
-rxvt_font_xft::has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful)
+rxvt_font_xft::has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &careful) const
 {
   careful = false;

-  if (!XftCharExists (DISPLAY, f, unicode))
+  if (!XftCharExists (term->display->display, f, unicode))
     return false;

   if (!prop || prop->width == rxvt_fontprop::unset)
@@ -1253,7 +1261,7 @@ rxvt_font_xft::has_char (unicode_t unicode, const rxvt_fontprop *prop, bool &car
   // check character against base font bounding box
   FcChar32 ch = unicode;
   XGlyphInfo g;
-  XftTextExtents32 (DISPLAY, f, &ch, 1, &g);
+  XftTextExtents32 (term->display->display, f, &ch, 1, &g);

   int w = g.width - g.x;
   int wcw = wcwidth (unicode);
@@ -1271,11 +1279,14 @@ rxvt_font_xft::draw (rxvt_drawable &d, int x, int y,
                      const text_t *text, int len,
                      int fg, int bg)
 {
+  clear_rect (d, x, y, term->fwidth * len, term->fheight, bg);
+
   XGlyphInfo extents;
   XftGlyphSpec *enc = (XftGlyphSpec *)get_enc_buf (len * sizeof (XftGlyphSpec));
   XftGlyphSpec *ep = enc;

-  clear_rect (d, x, y, r->fwidth * len, r->fheight, bg);
+  dTermDisplay;
+  dTermGC;

   // cut trailing spaces
   while (len && text [len - 1] == ' ')
@@ -1283,16 +1294,16 @@ rxvt_font_xft::draw (rxvt_drawable &d, int x, int y,

   while (len)
     {
-      int cwidth = r->fwidth;
+      int cwidth = term->fwidth;
       FcChar32 fc = *text++; len--;

       while (len && *text == NOCHAR)
-        text++, len--, cwidth += r->fwidth;
+        text++, len--, cwidth += term->fwidth;

       if (fc != ' ') // skip spaces
         {
-          FT_UInt glyph = XftCharIndex (d.display->display, f, fc);
-          XftGlyphExtents (d.display->display, f, &glyph, 1, &extents);
+          FT_UInt glyph = XftCharIndex (disp, f, fc);
+          XftGlyphExtents (disp, f, &glyph, 1, &extents);

           ep->glyph = glyph;
           ep->x = x + (cwidth - extents.xOff >> 1);
@@ -1304,14 +1315,14 @@ rxvt_font_xft::draw (rxvt_drawable &d, int x, int y,
     }

   if (ep != enc)
-    XftDrawGlyphSpec (d, &r->pix_colors[fg].c, f, enc, ep - enc);
+    XftDrawGlyphSpec (d, &term->pix_colors[fg].c, f, enc, ep - enc);
 }
 #endif

 /////////////////////////////////////////////////////////////////////////////

-rxvt_fontset::rxvt_fontset (rxvt_t r)
-: fontdesc (0), r (r)
+rxvt_fontset::rxvt_fontset (rxvt_term *term)
+: fontdesc (0), term (term)
 {
   clear ();
 }
@@ -1365,7 +1376,7 @@ rxvt_fontset::new_font (const char *name, codeset cs)
   else
     f = new rxvt_font_x11;

-  f->set_term (r);
+  f->set_term (term);
   f->set_name (strdup (name));

   f->cs = cs;
@@ -1558,7 +1569,7 @@ rxvt_fontset::find_font (unicode_t unicode)
               //FcPatternAddBool    (p, FC_ANTIALIAS, 1);

               XftResult result;
-              FcPattern *match = XftFontMatch (DISPLAY, r->display->screen, p, &result);
+              FcPattern *match = XftFontMatch (term->display->display, term->display->screen, p, &result);

               FcPatternDestroy (p);

diff --git a/src/rxvtfont.h b/src/rxvtfont.h

index b62cea18cdfc65632c3019de179baac2237bb563..

index ..e52a57f78a7f291c8036e380f380ab84a1990130 100644

--- a/src/rxvtfont.h
+++ b/src/rxvtfont.h
@@ -63,8 +63,8 @@ struct rxvt_drawable {

 struct rxvt_font {
   // managed by the fontset
-  rxvt_term *r;
-  void set_term (rxvt_term *r) { this->r = r; }
+  rxvt_term *term;
+  void set_term (rxvt_term *term) { this->term = term; }

   char *name;
   codeset cs;
@@ -81,12 +81,12 @@ struct rxvt_font {

   virtual void clear () { };

-  void clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color);
+  void clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color) const;

   virtual rxvt_fontprop properties () = 0;

   virtual bool load (const rxvt_fontprop &morph) = 0;
-  virtual bool has_char (uint32_t unicode, const rxvt_fontprop *prop, bool &careful) = 0;
+  virtual bool has_char (uint32_t unicode, const rxvt_fontprop *prop, bool &careful) const = 0;

   virtual void draw (rxvt_drawable &d,
                      int x, int y,
@@ -101,7 +101,7 @@ struct rxvt_fallback_font;
 struct rxvt_fontset {
   char *fontdesc;

-  rxvt_fontset (rxvt_term *r);
+  rxvt_fontset (rxvt_term *term);
   ~rxvt_fontset ();

   bool populate (const char *desc);
@@ -117,7 +117,7 @@ struct rxvt_fontset {
   }

 private:
-  rxvt_term *r;
+  rxvt_term *term;
   rxvt_fontprop prop;
   simplevec<rxvt_font *> fonts;
   const rxvt_fallback_font *fallback;
diff --git a/src/screen.C b/src/screen.C

index 68a9833b76ed22d8f8456361db5429c87e2d06bf..

index ..dc86668e20abf5e43f2aee906630c243a3367a96 100644

--- a/src/screen.C
+++ b/src/screen.C
@@ -450,7 +450,7 @@ rxvt_term::scr_poweron ()
   scr_reset ();

   scr_clear (true);
-  scr_refresh (SLOW_REFRESH);
+  scr_refresh ();
 }

 /* ------------------------------------------------------------------------- *
@@ -1792,8 +1792,10 @@ rxvt_term::scr_expose (int x, int y, int ewidth, int eheight, bool refresh)
   for (i = rc[PART_BEG].row; i <= rc[PART_END].row; i++)
     fill_text (&drawn_buf[i].t[rc[PART_BEG].col], 0, rc[PART_END].col - rc[PART_BEG].col + 1);

+  num_scr_allow = 0;
+
   if (refresh)
-    scr_refresh (SLOW_REFRESH);
+    scr_refresh ();
 }

 /* ------------------------------------------------------------------------- */
@@ -1937,7 +1939,7 @@ rxvt_term::scr_printscreen (int fullhist)
  * screen.text/screen.rend contain what the screen will change to.
  */
 void
-rxvt_term::scr_refresh (unsigned char refresh_type)
+rxvt_term::scr_refresh ()
 {
   unsigned char must_clear, /* use draw_string not draw_image_string     */
                 showcursor; /* show the cursor                           */
@@ -2071,7 +2073,6 @@ rxvt_term::scr_refresh (unsigned char refresh_type)
    * D: CopyArea pass - very useful for slower links
    *    This has been deliberately kept simple.
    */
-  i = num_scr;
   if (!display->is_local
       && refresh_type == FAST_REFRESH && num_scr_allow && num_scr
       && abs (num_scr) < nrow && !must_clear)
@@ -2079,6 +2080,7 @@ rxvt_term::scr_refresh (unsigned char refresh_type)
       int16_t nits;
       int j;
       int len, wlen;
+      dLocal (int, num_scr);

       j = nrow;
       wlen = len = -1;

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

-- Response ended

-- Page fetched on Sun Jun 2 09:33:46 2024