version 1.104, 2020/03/31 17:13:20 |
version 1.105, 2020/04/09 13:53:50 |
|
|
void |
void |
grid_unwrap_position(struct grid *gd, u_int *px, u_int *py, u_int wx, u_int wy) |
grid_unwrap_position(struct grid *gd, u_int *px, u_int *py, u_int wx, u_int wy) |
{ |
{ |
u_int yy, ax = 0, ay = 0; |
u_int yy, ay = 0; |
|
|
for (yy = 0; yy < gd->hsize + gd->sy - 1; yy++) { |
for (yy = 0; yy < gd->hsize + gd->sy - 1; yy++) { |
if (ay == wy) |
if (ay == wy) |
break; |
break; |
if (gd->linedata[yy].flags & GRID_LINE_WRAPPED) |
if (~gd->linedata[yy].flags & GRID_LINE_WRAPPED) |
ax += gd->linedata[yy].cellused; |
|
else { |
|
ax = 0; |
|
ay++; |
ay++; |
} |
|
} |
} |
|
|
/* |
/* |