Lines Matching defs:ny

567     u_int px, u_int py, u_int nx, u_int ny)
576 if (nx == 0 || ny == 0)
580 for (yy = py; yy < py + ny; yy++) {
682 screen_write_vline(struct screen_write_ctx *ctx, u_int ny, int top, int bottom)
695 for (i = 1; i < ny - 1; i++) {
699 screen_write_set_cursor(ctx, cx, cy + ny - 1);
758 screen_write_box(struct screen_write_ctx *ctx, u_int nx, u_int ny,
786 screen_write_set_cursor(ctx, cx, cy + ny - 1);
797 for (i = 1; i < ny - 1; i++) {
821 u_int ny)
847 if (py < ny / 3)
850 py = py - ny / 3;
851 if (py + ny > screen_size_y(src)) {
852 if (ny > screen_size_y(src))
855 py = screen_size_y(src) - ny;
862 screen_write_fast_copy(ctx, src, px, src->grid->hsize + py, nx, ny);
897 /* Cursor up by ny. */
899 screen_write_cursorup(struct screen_write_ctx *ctx, u_int ny)
904 if (ny == 0)
905 ny = 1;
909 if (ny > cy)
910 ny = cy;
913 if (ny > cy - s->rupper)
914 ny = cy - s->rupper;
919 cy -= ny;
924 /* Cursor down by ny. */
926 screen_write_cursordown(struct screen_write_ctx *ctx, u_int ny)
931 if (ny == 0)
932 ny = 1;
936 if (ny > screen_size_y(s) - 1 - cy)
937 ny = screen_size_y(s) - 1 - cy;
940 if (ny > s->rlower - cy)
941 ny = s->rlower - cy;
945 else if (ny == 0)
948 cy += ny;
1127 /* Insert ny lines. */
1129 screen_write_insertline(struct screen_write_ctx *ctx, u_int ny, u_int bg)
1135 if (ny == 0)
1136 ny = 1;
1139 if (ny > screen_size_y(s) - s->cy)
1140 ny = screen_size_y(s) - s->cy;
1141 if (ny == 0)
1147 grid_view_insert_lines(gd, s->cy, ny, bg);
1150 ttyctx.num = ny;
1155 if (ny > s->rlower + 1 - s->cy)
1156 ny = s->rlower + 1 - s->cy;
1157 if (ny == 0)
1164 grid_view_insert_lines(gd, s->cy, ny, bg);
1166 grid_view_insert_lines_region(gd, s->rlower, s->cy, ny, bg);
1170 ttyctx.num = ny;
1174 /* Delete ny lines. */
1176 screen_write_deleteline(struct screen_write_ctx *ctx, u_int ny, u_int bg)
1183 if (ny == 0)
1184 ny = 1;
1187 if (ny > sy - s->cy)
1188 ny = sy - s->cy;
1189 if (ny == 0)
1195 grid_view_delete_lines(gd, s->cy, ny, bg);
1198 ttyctx.num = ny;
1203 if (ny > s->rlower + 1 - s->cy)
1204 ny = s->rlower + 1 - s->cy;
1205 if (ny == 0)
1212 grid_view_delete_lines(gd, s->cy, ny, bg);
1214 grid_view_delete_lines_region(gd, s->rlower, s->cy, ny, bg);
1217 ttyctx.num = ny;