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.176 by root, Tue Dec 20 20:58:31 2005 UTC vs.
Revision 1.178 by root, Tue Dec 20 22:27:49 2005 UTC

83#define ROWCOL_IN_ROW_AT_OR_AFTER(X, Y) \ 83#define ROWCOL_IN_ROW_AT_OR_AFTER(X, Y) \
84 ROW_AND_COL_IN_ROW_AT_OR_AFTER ((X).row, (X).col, (Y).row, (Y).col) 84 ROW_AND_COL_IN_ROW_AT_OR_AFTER ((X).row, (X).col, (Y).row, (Y).col)
85#define ROWCOL_IN_ROW_AT_OR_BEFORE(X, Y) \ 85#define ROWCOL_IN_ROW_AT_OR_BEFORE(X, Y) \
86 ROW_AND_COL_IN_ROW_AT_OR_BEFORE ((X).row, (X).col, (Y).row, (Y).col) 86 ROW_AND_COL_IN_ROW_AT_OR_BEFORE ((X).row, (X).col, (Y).row, (Y).col)
87 87
88#define LINENO(n) (((n) + term_start + total_rows) % total_rows)
89#define ROW(n) (save [LINENO (n)])
90
91/* 88/*
92 * CLEAR_ROWS : clear <num> rows starting from row <row> 89 * CLEAR_ROWS : clear <num> rows starting from row <row>
93 * CLEAR_CHARS: clear <num> chars starting from pixel position <x,y> 90 * CLEAR_CHARS: clear <num> chars starting from pixel position <x,y>
94 * ERASE_ROWS : set <num> rows starting from row <row> to the foreground colour 91 * ERASE_ROWS : set <num> rows starting from row <row> to the foreground colour
95 */ 92 */
639 return 0; 636 return 0;
640 637
641 want_refresh = 1; 638 want_refresh = 1;
642 num_scr += count; 639 num_scr += count;
643 640
644 if (row1 == 0 && count > 0 641 if (count > 0
642 && row1 == 0
643 && row2 == nrow - 1
645 && (current_screen == PRIMARY || options & Opt_secondaryScroll)) 644 && (current_screen == PRIMARY || options & Opt_secondaryScroll))
646 { 645 {
647 nsaved = min (nsaved + count, saveLines); 646 nsaved = min (nsaved + count, saveLines);
648 term_start = (term_start + count) % total_rows; 647 term_start = (term_start + count) % total_rows;
649 648
3145 * flag == 2 ==> button 3 motion 3144 * flag == 2 ==> button 3 motion
3146 */ 3145 */
3147void 3146void
3148rxvt_term::selection_extend (int x, int y, int flag) 3147rxvt_term::selection_extend (int x, int y, int flag)
3149{ 3148{
3150 int col = min (max (Pixel2Col (x), 0), nrow - 1); 3149 int col = min (max (Pixel2Col (x), 0), ncol);
3151 int row = min (max (Pixel2Row (y), 0), ncol); 3150 int row = min (max (Pixel2Row (y), 0), nrow - 1);
3152 3151
3153 /* 3152 /*
3154 * If we're selecting characters (single click) then we must check first 3153 * If we're selecting characters (single click) then we must check first
3155 * if we are at the same place as the original mark. If we are then 3154 * if we are at the same place as the original mark. If we are then
3156 * select nothing. Otherwise, if we're to the right of the mark, you have to 3155 * select nothing. Otherwise, if we're to the right of the mark, you have to

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines