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.453 by root, Sat Dec 13 12:24:33 2014 UTC vs.
Revision 1.454 by sf-exg, Sun Jan 18 13:08:46 2015 UTC

2118 ccol2 = bgcolor_of (rstyle); 2118 ccol2 = bgcolor_of (rstyle);
2119#else 2119#else
2120 ccol2 = Color_bg; 2120 ccol2 = Color_bg;
2121#endif 2121#endif
2122 2122
2123 if (focus && cursor_type != 2) 2123 if (focus && cursor_type == 0)
2124 { 2124 {
2125 rend_t rend = cur_rend; 2125 rend_t rend = cur_rend;
2126 2126
2127 if (cursor_type == 1)
2128 rend ^= RS_Uline;
2129 else
2130 {
2131 rend ^= RS_RVid; 2127 rend ^= RS_RVid;
2132 rend = SET_FGCOLOR (rend, ccol1); 2128 rend = SET_FGCOLOR (rend, ccol1);
2133 rend = SET_BGCOLOR (rend, ccol2); 2129 rend = SET_BGCOLOR (rend, ccol2);
2134 }
2135 2130
2136 scr_set_char_rend (ROW(screen.cur.row), cur_col, rend); 2131 scr_set_char_rend (ROW(screen.cur.row), cur_col, rend);
2137 } 2132 }
2138 } 2133 }
2139 2134
2141 if (ocrow != -1 && ocrow < nrow && oldcursor.col < ncol) 2136 if (ocrow != -1 && ocrow < nrow && oldcursor.col < ncol)
2142 drawn_buf[ocrow].r[oldcursor.col] ^= (RS_RVid | RS_Uline); 2137 drawn_buf[ocrow].r[oldcursor.col] ^= (RS_RVid | RS_Uline);
2143 2138
2144 // save the current cursor coordinates if the cursor is visible 2139 // save the current cursor coordinates if the cursor is visible
2145 // and either the window is unfocused or the cursor style is 2140 // and either the window is unfocused or the cursor style is
2146 // vertical bar, so as to clear the outline cursor in the next 2141 // underline or vertical bar, so as to clear the outline cursor in
2147 // refresh if the cursor moves or becomes invisible 2142 // the next refresh if the cursor moves or becomes invisible
2148 if (showcursor && (!focus || cursor_type == 2) && screen.cur.row - view_start < nrow) 2143 if (showcursor && (!focus || cursor_type != 0) && screen.cur.row - view_start < nrow)
2149 { 2144 {
2150 oldcursor.row = screen.cur.row - view_start; 2145 oldcursor.row = screen.cur.row - view_start;
2151 oldcursor.col = screen.cur.col; 2146 oldcursor.col = screen.cur.col;
2152 } 2147 }
2153 else 2148 else
2447 */ 2442 */
2448 if (showcursor) 2443 if (showcursor)
2449 { 2444 {
2450 if (focus) 2445 if (focus)
2451 { 2446 {
2452 if (cursor_type != 2) 2447 if (cursor_type == 0)
2453 scr_set_char_rend (ROW(screen.cur.row), cur_col, cur_rend); 2448 scr_set_char_rend (ROW(screen.cur.row), cur_col, cur_rend);
2454 else if (oldcursor.row >= 0) 2449 else if (oldcursor.row >= 0)
2455 { 2450 {
2456 XSetForeground (dpy, gc, pix_colors[ccol1]); 2451 XSetForeground (dpy, gc, pix_colors[ccol1]);
2452 if (cursor_type == 1)
2457 XFillRectangle (dpy, vt, gc, 2453 XFillRectangle (dpy, vt, gc,
2458 Col2Pixel (cur_col), 2454 Col2Pixel (cur_col),
2455 Row2Pixel (oldcursor.row + 1) - 2,
2456 Width2Pixel (1),
2457 2);
2458 else
2459 XFillRectangle (dpy, vt, gc,
2460 Col2Pixel (cur_col),
2459 Row2Pixel (oldcursor.row), 2461 Row2Pixel (oldcursor.row),
2460 1, 2462 2,
2461 Height2Pixel (1)); 2463 Height2Pixel (1));
2462 } 2464 }
2463 } 2465 }
2464 else if (oldcursor.row >= 0) 2466 else if (oldcursor.row >= 0)
2465 { 2467 {
2466 XSetForeground (dpy, gc, pix_colors[ccol1]); 2468 XSetForeground (dpy, gc, pix_colors[ccol1]);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines