version 1.136, 2018/01/12 16:43:47 |
version 1.137, 2018/07/04 09:44:07 |
|
|
break; |
break; |
cx = s->cx; |
cx = s->cx; |
for (xx = px; xx < px + nx; xx++) { |
for (xx = px; xx < px + nx; xx++) { |
if (xx >= gd->linedata[yy].cellsize) |
if (xx >= grid_get_line(gd, yy)->cellsize) |
break; |
break; |
grid_get_cell(gd, xx, yy, &gc); |
grid_get_cell(gd, xx, yy, &gc); |
if (xx + gc.data.width > px + nx) |
if (xx + gc.data.width > px + nx) |
|
|
if (s->cx == 0) { |
if (s->cx == 0) { |
if (s->cy == 0) |
if (s->cy == 0) |
return; |
return; |
gl = &s->grid->linedata[s->grid->hsize + s->cy - 1]; |
gl = grid_get_line(s->grid, s->grid->hsize + s->cy - 1); |
if (gl->flags & GRID_LINE_WRAPPED) { |
if (gl->flags & GRID_LINE_WRAPPED) { |
s->cy--; |
s->cy--; |
s->cx = screen_size_x(s) - 1; |
s->cx = screen_size_x(s) - 1; |
|
|
struct tty_ctx ttyctx; |
struct tty_ctx ttyctx; |
u_int sx = screen_size_x(s); |
u_int sx = screen_size_x(s); |
|
|
gl = &s->grid->linedata[s->grid->hsize + s->cy]; |
gl = grid_get_line(s->grid, s->grid->hsize + s->cy); |
if (gl->cellsize == 0 && bg == 8) |
if (gl->cellsize == 0 && bg == 8) |
return; |
return; |
|
|
|
|
struct tty_ctx ttyctx; |
struct tty_ctx ttyctx; |
u_int sx = screen_size_x(s); |
u_int sx = screen_size_x(s); |
|
|
gl = &s->grid->linedata[s->grid->hsize + s->cy]; |
gl = grid_get_line(s->grid, s->grid->hsize + s->cy); |
if (s->cx > sx - 1 || (s->cx >= gl->cellsize && bg == 8)) |
if (s->cx > sx - 1 || (s->cx >= gl->cellsize && bg == 8)) |
return; |
return; |
|
|
|
|
struct grid *gd = s->grid; |
struct grid *gd = s->grid; |
struct grid_line *gl; |
struct grid_line *gl; |
|
|
gl = &gd->linedata[gd->hsize + s->cy]; |
gl = grid_get_line(gd, gd->hsize + s->cy); |
if (wrapped) |
if (wrapped) |
gl->flags |= GRID_LINE_WRAPPED; |
gl->flags |= GRID_LINE_WRAPPED; |
else |
else |
|
|
screen_write_initctx(ctx, &ttyctx); |
screen_write_initctx(ctx, &ttyctx); |
|
|
/* Handle overwriting of UTF-8 characters. */ |
/* Handle overwriting of UTF-8 characters. */ |
gl = &s->grid->linedata[s->grid->hsize + s->cy]; |
gl = grid_get_line(s->grid, s->grid->hsize + s->cy); |
if (gl->flags & GRID_LINE_EXTENDED) { |
if (gl->flags & GRID_LINE_EXTENDED) { |
grid_view_get_cell(gd, s->cx, s->cy, &now_gc); |
grid_view_get_cell(gd, s->cx, s->cy, &now_gc); |
if (screen_write_overwrite(ctx, &now_gc, width)) |
if (screen_write_overwrite(ctx, &now_gc, width)) |