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.220 by root, Mon Jan 9 23:18:49 2006 UTC vs.
Revision 1.224 by root, Thu Jan 12 03:32:56 2006 UTC

572 * Change the colour for following text 572 * Change the colour for following text
573 */ 573 */
574void 574void
575rxvt_term::scr_color (unsigned int color, int fgbg) 575rxvt_term::scr_color (unsigned int color, int fgbg)
576{ 576{
577 if (color > maxTermCOLOR) 577 if (!IN_RANGE_INC (color, minCOLOR, maxTermCOLOR))
578 color = fgbg; 578 color = fgbg;
579 579
580 if (fgbg == Color_fg) 580 if (fgbg == Color_fg)
581 rstyle = SET_FGCOLOR (rstyle, color); 581 rstyle = SET_FGCOLOR (rstyle, color);
582 else 582 else
2381 /* 2381 /*
2382 * H: cleanup selection 2382 * H: cleanup selection
2383 */ 2383 */
2384 scr_reverse_selection (); 2384 scr_reverse_selection ();
2385 2385
2386 if (refresh_type & SMOOTH_REFRESH)
2387 XFlush (display->display);
2388
2389 num_scr = 0; 2386 num_scr = 0;
2390 num_scr_allow = 1; 2387 num_scr_allow = 1;
2391} 2388}
2392 2389
2393void 2390void
3047void 3044void
3048rxvt_term::selection_click (int clicks, int x, int y) 3045rxvt_term::selection_click (int clicks, int x, int y)
3049{ 3046{
3050 clicks = ((clicks - 1) % 3) + 1; 3047 clicks = ((clicks - 1) % 3) + 1;
3051 selection.clicks = clicks; /* save clicks so extend will work */ 3048 selection.clicks = clicks; /* save clicks so extend will work */
3049
3050 if (clicks == 2 && !selection.rect
3051 && HOOK_INVOKE ((this, HOOK_SEL_EXTEND, DT_END)))
3052 {
3053 MEvent.clicks = 1; // what a mess
3054 return;
3055 }
3052 3056
3053 selection_start_colrow (Pixel2Col (x), Pixel2Row (y)); 3057 selection_start_colrow (Pixel2Col (x), Pixel2Row (y));
3054 3058
3055 if (clicks == 2 || clicks == 3) 3059 if (clicks == 2 || clicks == 3)
3056 selection_extend_colrow (selection.mark.col, 3060 selection_extend_colrow (selection.mark.col,
3352 else if (selection.clicks == 2) 3356 else if (selection.clicks == 2)
3353 { 3357 {
3354 if (ROWCOL_IS_AFTER (selection.end, selection.beg)) 3358 if (ROWCOL_IS_AFTER (selection.end, selection.beg))
3355 selection.end.col--; 3359 selection.end.col--;
3356 3360
3357 if (!HOOK_INVOKE ((this, HOOK_SEL_EXTEND, DT_END)))
3358 {
3359 selection_delimit_word (UP, &selection.beg, &selection.beg); 3361 selection_delimit_word (UP, &selection.beg, &selection.beg);
3360 selection_delimit_word (DN, &selection.end, &selection.end); 3362 selection_delimit_word (DN, &selection.end, &selection.end);
3361 }
3362 } 3363 }
3363 else if (selection.clicks == 3) 3364 else if (selection.clicks == 3)
3364 { 3365 {
3365#if ENABLE_FRILLS 3366#if ENABLE_FRILLS
3366 if (OPTION (Opt_tripleclickwords)) 3367 if (OPTION (Opt_tripleclickwords))

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines