mirror of
https://github.com/tmux/tmux.git
synced 2026-10-10 20:24:21 +00:00
Rebased on current master without conflicts and completed the cleanup: comments above new function in longer functions, metadata comments, aligned declarations and simpler guards, consistent braces and shorter lines.
This commit is contained in:
19
tty.c
19
tty.c
@@ -158,9 +158,10 @@ void
|
||||
tty_set_size(struct tty *tty, u_int sx, u_int sy, u_int xpixel, u_int ypixel)
|
||||
{
|
||||
#ifdef ENABLE_IMAGES
|
||||
int geometry_changed;
|
||||
int geometry_changed = 0;
|
||||
|
||||
geometry_changed = (tty->xpixel != xpixel || tty->ypixel != ypixel);
|
||||
if (tty->xpixel != xpixel || tty->ypixel != ypixel)
|
||||
geometry_changed = 1;
|
||||
#endif
|
||||
tty->sx = sx;
|
||||
tty->sy = sy;
|
||||
@@ -1940,14 +1941,12 @@ tty_cmd_cell(struct tty *tty, const struct tty_ctx *ctx)
|
||||
struct grid_cell placeholder_cell;
|
||||
struct kitty_placeholder placeholder;
|
||||
|
||||
if (kitty_cell_is_placeholder(cell)) {
|
||||
if (image_grid_get_placeholder(ctx->s->grid, ctx->ocx,
|
||||
ctx->s->grid->hsize + ctx->ocy, &placeholder)) {
|
||||
memcpy(&placeholder_cell, cell,
|
||||
sizeof placeholder_cell);
|
||||
utf8_set(&placeholder_cell.data, ' ');
|
||||
cell = &placeholder_cell;
|
||||
}
|
||||
if (kitty_cell_is_placeholder(cell) &&
|
||||
image_grid_get_placeholder(ctx->s->grid, ctx->ocx,
|
||||
ctx->s->grid->hsize + ctx->ocy, &placeholder)) {
|
||||
memcpy(&placeholder_cell, cell, sizeof placeholder_cell);
|
||||
utf8_set(&placeholder_cell.data, ' ');
|
||||
cell = &placeholder_cell;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user