ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/screen.C
(Generate patch)

Comparing rxvt-unicode/src/screen.C (file contents):
Revision 1.318 by root, Tue Nov 4 22:44:09 2008 UTC vs.
Revision 1.323 by root, Tue Nov 4 23:53:29 2008 UTC

158 * ------------------------------------------------------------------------- */ 158 * ------------------------------------------------------------------------- */
159 159
160void 160void
161rxvt_term::scr_reset () 161rxvt_term::scr_reset ()
162{ 162{
163 scr_soft_reset ();
164
163 view_start = 0; 165 view_start = 0;
164 num_scr = 0; 166 num_scr = 0;
165 167
166 if (ncol == 0) 168 if (ncol == 0)
167 ncol = 80; 169 ncol = 80;
434void 436void
435rxvt_term::scr_poweron () 437rxvt_term::scr_poweron ()
436{ 438{
437 scr_release (); 439 scr_release ();
438 prev_nrow = prev_ncol = 0; 440 prev_nrow = prev_ncol = 0;
439 scr_soft_reset ();
440 scr_reset (); 441 scr_reset ();
441 442
442 scr_clear (true); 443 scr_clear (true);
443 scr_refresh (); 444 scr_refresh ();
444} 445}
459 free (tabs); 460 free (tabs);
460 tabs = (char *)rxvt_malloc (ncol); 461 tabs = (char *)rxvt_malloc (ncol);
461 462
462 for (int col = ncol; --col; ) 463 for (int col = ncol; --col; )
463 tabs [col] = col % TABSIZE == 0; 464 tabs [col] = col % TABSIZE == 0;
464
465 if (current_screen != PRIMARY)
466 scr_swap_screen ();
467 465
468 scr_scroll_region (0, MAX_ROWS - 1); 466 scr_scroll_region (0, MAX_ROWS - 1);
469 scr_rendition (0, ~RS_None); 467 scr_rendition (0, ~RS_None);
470 scr_insert_mode (0); 468 scr_insert_mode (0);
471} 469}
1351 ren = (rend_t) ~RS_None; 1349 ren = (rend_t) ~RS_None;
1352 else if (GET_BASEBG (rstyle) == Color_bg) 1350 else if (GET_BASEBG (rstyle) == Color_bg)
1353 { 1351 {
1354 ren = DEFAULT_RSTYLE; 1352 ren = DEFAULT_RSTYLE;
1355 1353
1356 if (mapped) 1354 if (mapped && !view_start)
1357 XClearArea (dpy, vt, 0, 1355 XClearArea (dpy, vt, 0,
1358 Row2Pixel (row), (unsigned int)width, 1356 Row2Pixel (row - view_start), (unsigned int)width,
1359 (unsigned int)Height2Pixel (num), False); 1357 (unsigned int)Height2Pixel (num), False);
1360 } 1358 }
1361 else 1359 else
1362 { 1360 {
1363 ren = rstyle & (RS_fgMask | RS_bgMask); 1361 ren = rstyle & (RS_fgMask | RS_bgMask);
1364 1362
1363 if (mapped && !view_start)
1364 {
1365 gcvalue.foreground = pix_colors[bgcolor_of (rstyle)]; 1365 gcvalue.foreground = pix_colors[bgcolor_of (rstyle)];
1366 XChangeGC (dpy, gc, GCForeground, &gcvalue); 1366 XChangeGC (dpy, gc, GCForeground, &gcvalue);
1367 XFillRectangle (dpy, vt, gc, 1367 XFillRectangle (dpy, vt, gc,
1368 0, Row2Pixel (row), 1368 0, Row2Pixel (row - view_start),
1369 (unsigned int)width, 1369 (unsigned int)width,
1370 (unsigned int)Height2Pixel (num)); 1370 (unsigned int)Height2Pixel (num));
1371 gcvalue.foreground = pix_colors[Color_fg]; 1371 gcvalue.foreground = pix_colors[Color_fg];
1372 XChangeGC (dpy, gc, GCForeground, &gcvalue); 1372 XChangeGC (dpy, gc, GCForeground, &gcvalue);
1373 }
1373 } 1374 }
1374 1375
1375 for (; num--; row++) 1376 for (; num--; row++)
1376 { 1377 {
1377 scr_blank_screen_mem (ROW(row), rstyle); 1378 scr_blank_screen_mem (ROW(row), rstyle);
1379 if (!view_start)
1378 scr_blank_line (drawn_buf [row], 0, ncol, ren); 1380 scr_blank_line (drawn_buf [row], 0, ncol, ren);
1379 } 1381 }
1380} 1382}
1381 1383
1382#if !ENABLE_MINIMAL 1384#if !ENABLE_MINIMAL
1383void 1385void

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines