version 1.110, 2014/05/14 06:39:58 |
version 1.111, 2014/06/19 07:37:59 |
|
|
struct screen *s = &data->screen; |
struct screen *s = &data->screen; |
char *buf; |
char *buf; |
size_t off; |
size_t off; |
u_int i, xx, yy, sx, sy, ex, ey; |
u_int i, xx, yy, sx, sy, ex, ey, ey_last; |
u_int firstsx, lastex, restex, restsx; |
u_int firstsx, lastex, restex, restsx; |
int keys; |
int keys; |
|
|
|
|
} |
} |
|
|
/* Trim ex to end of line. */ |
/* Trim ex to end of line. */ |
xx = window_copy_find_length(wp, ey); |
ey_last = window_copy_find_length(wp, ey); |
if (ex > xx) |
if (ex > ey_last) |
ex = xx; |
ex = ey_last; |
|
|
/* |
/* |
* Deal with rectangle-copy if necessary; four situations: start of |
* Deal with rectangle-copy if necessary; four situations: start of |
|
|
free(buf); |
free(buf); |
return (NULL); |
return (NULL); |
} |
} |
*len = off - 1; /* remove final \n */ |
if (keys == MODEKEY_EMACS || lastex <= ey_last) |
|
off -= 1; /* remove final \n (unless at end in vi mode) */ |
|
*len = off; |
return (buf); |
return (buf); |
} |
} |
|
|