[BACK]Return to screen-write.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / tmux

Diff for /src/usr.bin/tmux/screen-write.c between version 1.17 and 1.18

version 1.17, 2009/07/22 20:53:38 version 1.18, 2009/07/27 11:33:21
Line 723 
Line 723 
         struct tty_ctx           ttyctx;          struct tty_ctx           ttyctx;
         struct grid_utf8         gu, *tmp_gu;          struct grid_utf8         gu, *tmp_gu;
         u_int                    width, xx, i;          u_int                    width, xx, i;
         struct grid_cell         tmp_gc, *tmp_gc2;          struct grid_cell         tmp_gc, tmp_gc2, *tmp_gcp;
         int                      insert = 0;          int                      insert = 0;
   
         /* Ignore padding. */          /* Ignore padding. */
Line 743 
Line 743 
         if (width == 0) {          if (width == 0) {
                 if (s->cx == 0)                  if (s->cx == 0)
                         return;                          return;
                 tmp_gc2 = grid_view_get_cell(gd, s->cx - 1, s->cy);                  tmp_gcp = grid_view_get_cell(gd, s->cx - 1, s->cy);
                 if (!(tmp_gc2->flags & GRID_FLAG_UTF8)) {                  if (!(tmp_gcp->flags & GRID_FLAG_UTF8)) {
                         tmp_gc2->flags |= GRID_FLAG_UTF8;                          tmp_gcp->flags |= GRID_FLAG_UTF8;
                         memset(&gu.data, 0xff, sizeof gu.data);                          memset(&gu.data, 0xff, sizeof gu.data);
                         *gu.data = tmp_gc2->data;                          *gu.data = tmp_gcp->data;
                         gu.width = 1;                          gu.width = 1;
                         grid_view_set_utf8(gd, s->cx - 1, s->cy, &gu);                          grid_view_set_utf8(gd, s->cx - 1, s->cy, &gu);
                 }                  }
Line 799 
Line 799 
          * already ensured there is enough room.           * already ensured there is enough room.
          */           */
         for (xx = s->cx + 1; xx < s->cx + width; xx++) {          for (xx = s->cx + 1; xx < s->cx + width; xx++) {
                 tmp_gc2 = grid_view_get_cell(gd, xx, s->cy);                  tmp_gcp = grid_view_get_cell(gd, xx, s->cy);
                 if (tmp_gc2 != NULL)                  if (tmp_gcp != NULL)
                         tmp_gc2->flags |= GRID_FLAG_PADDING;                          tmp_gcp->flags |= GRID_FLAG_PADDING;
         }          }
   
         /* Set the cell. */          /* Set the cell. */
Line 820 
Line 820 
         }          }
         ttyctx.utf8 = &gu;          ttyctx.utf8 = &gu;
         if (screen_check_selection(s, s->cx - width, s->cy)) {          if (screen_check_selection(s, s->cx - width, s->cy)) {
                 s->sel.cell.data = gc->data;                  memcpy(&tmp_gc2, &s->sel.cell, sizeof tmp_gc2);
                 ttyctx.cell = &s->sel.cell;                  tmp_gc2.data = gc->data;
                   tmp_gc2.flags = gc->flags;
                   ttyctx.cell = &tmp_gc2;
                 tty_write(tty_cmd_cell, &ttyctx);                  tty_write(tty_cmd_cell, &ttyctx);
         } else {          } else {
                 ttyctx.cell = gc;                  ttyctx.cell = gc;

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18