… | |
… | |
234 | selection.text = NULL; |
234 | selection.text = NULL; |
235 | selection.len = 0; |
235 | selection.len = 0; |
236 | selection.op = SELECTION_CLEAR; |
236 | selection.op = SELECTION_CLEAR; |
237 | selection.screen = PRIMARY; |
237 | selection.screen = PRIMARY; |
238 | selection.clicks = 0; |
238 | selection.clicks = 0; |
239 | CLEAR_ALL_SELECTION (); |
|
|
240 | rvideo = 0; |
239 | rvideo = 0; |
241 | } |
240 | } |
242 | else |
241 | else |
243 | { |
242 | { |
244 | CLEAR_ALL_SELECTION (); |
|
|
245 | |
|
|
246 | /* |
243 | /* |
247 | * add or delete rows as appropriate |
244 | * add or delete rows as appropriate |
248 | */ |
245 | */ |
249 | |
246 | |
250 | rxvt_salloc *old_ta = talloc; talloc = new rxvt_salloc (ncol * sizeof (text_t)); |
247 | rxvt_salloc *old_ta = talloc; talloc = new rxvt_salloc (ncol * sizeof (text_t)); |
… | |
… | |
350 | |
347 | |
351 | line_t &pline = old_buf [prow]; |
348 | line_t &pline = old_buf [prow]; |
352 | |
349 | |
353 | int len = min (min (prev_ncol - pcol, ncol - qcol), llen - lofs); |
350 | int len = min (min (prev_ncol - pcol, ncol - qcol), llen - lofs); |
354 | |
351 | |
|
|
352 | #if DEBUG_STRICT |
355 | assert (len); |
353 | assert (len); |
356 | assert (pline.t); |
354 | assert (pline.t); |
|
|
355 | #endif |
357 | |
356 | |
358 | memcpy (qline->t + qcol, pline.t + pcol, len * sizeof (text_t)); |
357 | memcpy (qline->t + qcol, pline.t + pcol, len * sizeof (text_t)); |
359 | memcpy (qline->r + qcol, pline.r + pcol, len * sizeof (rend_t)); |
358 | memcpy (qline->r + qcol, pline.r + pcol, len * sizeof (rend_t)); |
360 | |
359 | |
361 | lofs += len; |
360 | lofs += len; |
… | |
… | |
406 | |
405 | |
407 | if (tabs) |
406 | if (tabs) |
408 | free (tabs); |
407 | free (tabs); |
409 | } |
408 | } |
410 | |
409 | |
|
|
410 | CLEAR_ALL_SELECTION (); |
|
|
411 | |
411 | prev_nrow = nrow; |
412 | prev_nrow = nrow; |
412 | prev_ncol = ncol; |
413 | prev_ncol = ncol; |
413 | |
414 | |
414 | tabs = (char *)rxvt_malloc (ncol * sizeof (char)); |
415 | tabs = (char *)rxvt_malloc (ncol * sizeof (char)); |
415 | |
416 | |
… | |
… | |
461 | * Save and Restore cursor |
462 | * Save and Restore cursor |
462 | * XTERM_SEQ: Save cursor : ESC 7 |
463 | * XTERM_SEQ: Save cursor : ESC 7 |
463 | * XTERM_SEQ: Restore cursor: ESC 8 |
464 | * XTERM_SEQ: Restore cursor: ESC 8 |
464 | */ |
465 | */ |
465 | void |
466 | void |
466 | rxvt_term::scr_cursor (int mode) |
467 | rxvt_term::scr_cursor (cursor_mode mode) |
467 | { |
468 | { |
468 | screen_t *s; |
469 | screen_t *s; |
469 | |
470 | |
470 | #if NSCREENS && !defined(NO_SECONDARY_SCREEN_CURSOR) |
471 | #if NSCREENS && !defined(NO_SECONDARY_SCREEN_CURSOR) |
471 | if (current_screen == SECONDARY) |
472 | if (current_screen == SECONDARY) |