… | |
… | |
2433 | #endif |
2433 | #endif |
2434 | } |
2434 | } |
2435 | } |
2435 | } |
2436 | else if (oldcursor.row >= 0) |
2436 | else if (oldcursor.row >= 0) |
2437 | { |
2437 | { |
|
|
2438 | int cursorwidth = 1; |
|
|
2439 | int col = oldcursor.col; |
|
|
2440 | |
|
|
2441 | while (col && screen.text[screen.cur.row + TermWin.saveLines][col] == NOCHAR) |
|
|
2442 | col--; |
|
|
2443 | |
|
|
2444 | while (col + cursorwidth < TermWin.ncol |
|
|
2445 | && drawn_text[oldcursor.row][col + cursorwidth] == NOCHAR) |
|
|
2446 | cursorwidth++; |
|
|
2447 | |
2438 | #ifndef NO_CURSORCOLOR |
2448 | #ifndef NO_CURSORCOLOR |
2439 | if (ISSET_PIXCOLOR (Color_cursor)) |
2449 | if (ISSET_PIXCOLOR (Color_cursor)) |
2440 | XSetForeground (display->display, TermWin.gc, pix_colors[Color_cursor]); |
2450 | XSetForeground (display->display, TermWin.gc, pix_colors[Color_cursor]); |
2441 | #endif |
2451 | #endif |
2442 | int cursorwidth = 1; |
|
|
2443 | while (oldcursor.col + cursorwidth < TermWin.ncol |
|
|
2444 | && drawn_text[oldcursor.row][oldcursor.col + cursorwidth] == NOCHAR) |
|
|
2445 | cursorwidth++; |
|
|
2446 | |
2452 | |
2447 | XDrawRectangle (display->display, drawBuffer, TermWin.gc, |
2453 | XDrawRectangle (display->display, drawBuffer, TermWin.gc, |
2448 | Col2Pixel (oldcursor.col), |
2454 | Col2Pixel (col), |
2449 | Row2Pixel (oldcursor.row), |
2455 | Row2Pixel (oldcursor.row), |
2450 | (unsigned int) (Width2Pixel (cursorwidth) - 1), |
2456 | (unsigned int) (Width2Pixel (cursorwidth) - 1), |
2451 | (unsigned int) (Height2Pixel (1) - TermWin.lineSpace - 1)); |
2457 | (unsigned int) (Height2Pixel (1) - TermWin.lineSpace - 1)); |
2452 | } |
2458 | } |
2453 | } |
2459 | } |