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.166 by root, Sun Jun 26 20:06:52 2005 UTC vs.
Revision 1.170 by root, Mon Nov 28 19:35:04 2005 UTC

441 */ 441 */
442void 442void
443rxvt_term::scr_release () 443rxvt_term::scr_release ()
444{ 444{
445 unsigned int total_rows; 445 unsigned int total_rows;
446 int i;
447 446
448 total_rows = TermWin.nrow + TermWin.saveLines; 447 total_rows = TermWin.nrow + TermWin.saveLines;
449 448
450 delete talloc; talloc = 0; 449 delete talloc; talloc = 0;
451 delete ralloc; ralloc = 0; 450 delete ralloc; ralloc = 0;
778 if (len <= 0) /* sanity */ 777 if (len <= 0) /* sanity */
779 return; 778 return;
780 779
781 unsigned char checksel; 780 unsigned char checksel;
782 unicode_t c; 781 unicode_t c;
783 int i, row, last_col; 782 int row, last_col;
784 text_t *stp; 783 text_t *stp;
785 rend_t *srp; 784 rend_t *srp;
786 const unicode_t *strend = str + len; 785 const unicode_t *strend = str + len;
787 786
788 want_refresh = 1; 787 want_refresh = 1;
1948/* ------------------------------------------------------------------------- */ 1947/* ------------------------------------------------------------------------- */
1949void 1948void
1950rxvt_term::scr_bell () 1949rxvt_term::scr_bell ()
1951{ 1950{
1952#ifndef NO_BELL 1951#ifndef NO_BELL
1952
1953# ifndef NO_MAPALERT 1953# ifndef NO_MAPALERT
1954# ifdef MAPALERT_OPTION 1954# ifdef MAPALERT_OPTION
1955 if (options & Opt_mapAlert) 1955 if (options & Opt_mapAlert)
1956# endif 1956# endif
1957 XMapWindow (display->display, TermWin.parent[0]); 1957 XMapWindow (display->display, TermWin.parent[0]);
1958# endif 1958# endif
1959
1959 if (options & Opt_visualBell) 1960 if (options & Opt_visualBell)
1960 { 1961 {
1961 scr_rvideo_mode (!rvideo); /* refresh also done */ 1962 scr_rvideo_mode (!rvideo); /* refresh also done */
1963 rxvt_usleep (VISUAL_BELL_DURATION);
1962 scr_rvideo_mode (!rvideo); /* refresh also done */ 1964 scr_rvideo_mode (!rvideo); /* refresh also done */
1963 } 1965 }
1964 else 1966 else
1965 XBell (display->display, 0); 1967 XBell (display->display, 0);
1968
1966#endif 1969#endif
1967} 1970}
1968 1971
1969/* ------------------------------------------------------------------------- */ 1972/* ------------------------------------------------------------------------- */
1970/* ARGSUSED */ 1973/* ARGSUSED */
2157 2160
2158#if ENABLE_OVERLAY 2161#if ENABLE_OVERLAY
2159 scr_swap_overlay (); 2162 scr_swap_overlay ();
2160#endif 2163#endif
2161 2164
2162 rend_t *drp, *srp; /* drawn-rend-pointer, screen-rend-pointer */
2163 text_t *dtp, *stp; /* drawn-text-pointer, screen-text-pointer */
2164
2165#ifndef NO_SLOW_LINK_SUPPORT 2165#ifndef NO_SLOW_LINK_SUPPORT
2166 /* 2166 /*
2167 * D: CopyArea pass - very useful for slower links 2167 * D: CopyArea pass - very useful for slower links
2168 * This has been deliberately kept simple. 2168 * This has been deliberately kept simple.
2169 */ 2169 */
2304 2304
2305 // sometimes we optimize away the trailing NOCHAR's, add them back 2305 // sometimes we optimize away the trailing NOCHAR's, add them back
2306 while (i && text[count] == NOCHAR) 2306 while (i && text[count] == NOCHAR)
2307 count++, i--; 2307 count++, i--;
2308 2308
2309#if ENABLE_STYLES
2310 // force redraw after "careful" characters to avoid pixel droppings
2311 if (srp[col] & RS_Careful && col < TermWin.ncol - 1 && 0)
2312 drp[col + 1] = ~srp[col + 1];
2313
2314 // include previous careful character(s) if possible, looks nicer (best effort...)
2315 while (text > stp
2316 && srp[text - stp - 1] & RS_Careful
2317 && RS_SAME (rend, srp[text - stp - 1]))
2318 text--, count++, xpixel -= TermWin.fwidth;
2319#endif
2320
2321 /* 2309 /*
2322 * Determine the attributes for the string 2310 * Determine the attributes for the string
2323 */ 2311 */
2324 int fore = GET_FGCOLOR (rend); // desired foreground 2312 int fore = GET_FGCOLOR (rend); // desired foreground
2325 int back = GET_BGCOLOR (rend); // desired background 2313 int back = GET_BGCOLOR (rend); // desired background
2326 2314
2327 // only do special processing if ana attributes are set, which is rare 2315 // only do special processing if any attributes are set, which is rare
2328 if (rend & (RS_Bold | RS_Italic | RS_Uline | RS_RVid | RS_Blink)) 2316 if (rend & (RS_Bold | RS_Italic | RS_Uline | RS_RVid | RS_Blink | RS_Careful))
2329 { 2317 {
2318#if ENABLE_STYLES
2319 // force redraw after "careful" characters to avoid pixel droppings
2320 if (srp[col] & RS_Careful && col < TermWin.ncol - 1 && 0)
2321 drp[col + 1] = ~srp[col + 1];
2322
2323 // include previous careful character(s) if possible, looks nicer (best effort...)
2324 while (text > stp
2325 && srp[text - stp - 1] & RS_Careful
2326 && RS_SAME (rend, srp[text - stp - 1]))
2327 text--, count++, xpixel -= TermWin.fwidth;
2328#endif
2329
2330 bool invert = rend & RS_RVid; 2330 bool invert = rend & RS_RVid;
2331 2331
2332#ifndef NO_BOLD_UNDERLINE_REVERSE 2332#ifndef NO_BOLD_UNDERLINE_REVERSE
2333 if (rend & RS_Bold 2333 if (rend & RS_Bold
2334 && fore == Color_fg) 2334 && fore == Color_fg)
2361 SWAP_IT (fore, back, int); 2361 SWAP_IT (fore, back, int);
2362 2362
2363#ifndef NO_BOLD_UNDERLINE_REVERSE 2363#ifndef NO_BOLD_UNDERLINE_REVERSE
2364 if (ISSET_PIXCOLOR (Color_RV)) 2364 if (ISSET_PIXCOLOR (Color_RV))
2365 back = Color_RV; 2365 back = Color_RV;
2366
2367 if (fore == back)
2368 {
2369 fore = Color_bg;
2370 back = Color_fg;
2371 }
2366#endif 2372#endif
2367 } 2373 }
2368 2374
2369#ifdef TEXT_BLINK 2375#ifdef TEXT_BLINK
2370 if (rend & RS_Blink && (back == Color_bg || fore == Color_bg)) 2376 if (rend & RS_Blink && (back == Color_bg || fore == Color_bg))
2542 if (!TermWin.mapped) 2548 if (!TermWin.mapped)
2543 return; 2549 return;
2544 2550
2545 num_scr_allow = 0; 2551 num_scr_allow = 0;
2546 want_refresh = 1; 2552 want_refresh = 1;
2547
2548#if TRANSPARENT
2549 if ((options & Opt_transparent) && (am_pixmap_trans == 0))
2550 {
2551 int i;
2552
2553 if (!(options & Opt_transparent_all))
2554 i = 0;
2555 else
2556 i = (int) (sizeof (TermWin.parent) / sizeof (Window));
2557
2558 while (i--)
2559 if (TermWin.parent[i] != None)
2560 XClearWindow (display->display, TermWin.parent[i]);
2561 }
2562#endif
2563 2553
2564 if (really) 2554 if (really)
2565 XClearWindow (display->display, TermWin.vt); 2555 XClearWindow (display->display, TermWin.vt);
2566} 2556}
2567 2557

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines