ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/command.C
(Generate patch)

Comparing rxvt-unicode/src/command.C (file contents):
Revision 1.116 by root, Wed Aug 4 03:29:28 2004 UTC vs.
Revision 1.120 by root, Tue Aug 10 22:36:30 2004 UTC

306 newlen = 0; 306 newlen = 0;
307 } 307 }
308 break; 308 break;
309 309
310#ifdef XK_KP_Left 310#ifdef XK_KP_Left
311 case XK_KP_Up: /* \033Ox or standard */ 311 case XK_KP_Up: /* \033Ox or standard */
312 case XK_KP_Down: /* \033Or or standard */ 312 case XK_KP_Down: /* \033Or or standard */
313 case XK_KP_Right: /* \033Ov or standard */ 313 case XK_KP_Right: /* \033Ov or standard */
314 case XK_KP_Left: /* \033Ot or standard */ 314 case XK_KP_Left: /* \033Ot or standard */
315 if ((PrivateModes & PrivMode_aplKP) ? !shft : shft) 315 if ((PrivateModes & PrivMode_aplKP) ? !shft : shft)
316 { 316 {
661 if (want_full_refresh) 661 if (want_full_refresh)
662 { 662 {
663 want_full_refresh = 0; 663 want_full_refresh = 0;
664 scr_clear (); 664 scr_clear ();
665 scr_touch (false); 665 scr_touch (false);
666 want_refresh = 1;
667 } 666 }
668#endif 667#endif
669 668
670 if (want_refresh) 669 if (want_refresh)
671 { 670 {
687 SET_R (this); 686 SET_R (this);
688 SET_LOCALE (locale); 687 SET_LOCALE (locale);
689 688
690 display->flush (); 689 display->flush ();
691 690
692 if (!flush_ev.active) 691 if (want_refresh && !flush_ev.active)
693 flush_ev.start (NOW + 0.01); 692 flush_ev.start (NOW + 0.01);
694} 693}
695 694
696void 695void
697rxvt_term::flush_cb (time_watcher &w) 696rxvt_term::flush_cb (time_watcher &w)
1192#ifdef TRANSPARENT /* XXX: maybe not needed - leave in for now */ 1191#ifdef TRANSPARENT /* XXX: maybe not needed - leave in for now */
1193 if (Options & Opt_transparent) 1192 if (Options & Opt_transparent)
1194 { 1193 {
1195 check_our_parents (); 1194 check_our_parents ();
1196 if (am_transparent) 1195 if (am_transparent)
1197 want_full_refresh = 1; 1196 want_refresh = want_full_refresh = 1;
1198 } 1197 }
1199#endif 1198#endif
1200 } 1199 }
1201 break; 1200 break;
1202 1201
1413 } 1412 }
1414 1413
1415 /* FALLTHROUGH */ 1414 /* FALLTHROUGH */
1416 case ReparentNotify: 1415 case ReparentNotify:
1417 if ((Options & Opt_transparent) && check_our_parents () && am_transparent) 1416 if ((Options & Opt_transparent) && check_our_parents () && am_transparent)
1418 want_full_refresh = 1; 1417 want_refresh = want_full_refresh = 1;
1419 break; 1418 break;
1420#endif 1419#endif
1421 } 1420 }
1422} 1421}
1423 1422
1605 break; 1604 break;
1606 case R_SB_ALIGN_BOTTOM: 1605 case R_SB_ALIGN_BOTTOM:
1607 csrO = scrollBar.bot - scrollBar.top; 1606 csrO = scrollBar.bot - scrollBar.top;
1608 break; 1607 break;
1609 } 1608 }
1609
1610 if (scrollBar.style == R_SB_XTERM 1610 if (scrollBar.style == R_SB_XTERM
1611 || scrollbar_above_slider (ev.y) 1611 || scrollbar_above_slider (ev.y)
1612 || scrollbar_below_slider (ev.y)) 1612 || scrollbar_below_slider (ev.y))
1613 scr_move_to ( scrollbar_position (ev.y) - csrO, 1613 scr_move_to (scrollbar_position (ev.y) - csrO, scrollbar_size ());
1614 scrollbar_size ()); 1614
1615 scrollBar.setMotion (); 1615 scrollBar.setMotion ();
1616 break; 1616 break;
1617 1617
1618 case Button1: 1618 case Button1:
1619 if (scrollbar_align == R_SB_ALIGN_CENTRE) 1619 if (scrollbar_align == R_SB_ALIGN_CENTRE)
1643 scr_page ((ev.button == Button1 ? DN : UP), 1643 scr_page ((ev.button == Button1 ? DN : UP),
1644 (TermWin.nrow 1644 (TermWin.nrow
1645 * scrollbar_position (ev.y) 1645 * scrollbar_position (ev.y)
1646 / scrollbar_size ())); 1646 / scrollbar_size ()));
1647 } 1647 }
1648
1648 break; 1649 break;
1649 } 1650 }
1650 } 1651 }
1651 return; 1652 return;
1652 } 1653 }
2283 unicode_t buf[UBUFSIZ]; 2284 unicode_t buf[UBUFSIZ];
2284 bool refreshnow = false; 2285 bool refreshnow = false;
2285 int nlines = 0; 2286 int nlines = 0;
2286 unicode_t *str = buf; 2287 unicode_t *str = buf;
2287 2288
2288 *str++ = ch;
2289
2290 for (;;) 2289 for (;;)
2291 { 2290 {
2292 seq_begin = cmdbuf_ptr;
2293 ch = next_char ();
2294
2295 if (ch == NOCHAR || (IS_CONTROL (ch) && ch != C0_LF && ch != C0_CR && ch != C0_HT)) 2291 if (ch == NOCHAR || (IS_CONTROL (ch) && ch != C0_LF && ch != C0_CR && ch != C0_HT))
2296 break; 2292 break;
2297 2293
2298 *str++ = ch; 2294 *str++ = ch;
2299 2295
2300 if (ch == C0_LF) 2296 if (ch == C0_LF)
2301 { 2297 {
2302 nlines++; 2298 nlines++;
2303 refresh_count++; 2299 refresh_count++;
2304 2300
2305 if (! (Options & Opt_jumpScroll) 2301 if (!(Options & Opt_jumpScroll)
2306 || (refresh_count >= refresh_limit * (TermWin.nrow - 1))) 2302 || (refresh_count >= refresh_limit * (TermWin.nrow - 1)))
2307 { 2303 {
2308 refreshnow = true; 2304 refreshnow = true;
2309 ch = NOCHAR; 2305 ch = NOCHAR;
2310 break; 2306 break;
2311 } 2307 }
2312 2308
2313 // scr_add_lines only works for nlines < TermWin.nrow - 1. 2309 // scr_add_lines only works for nlines <= TermWin.nrow - 1.
2314 if (nlines >= TermWin.nrow - 1) 2310 if (nlines >= TermWin.nrow - 1)
2315 { 2311 {
2316 scr_add_lines (buf, nlines, str - buf); 2312 scr_add_lines (buf, nlines, str - buf);
2317 nlines = 0; 2313 nlines = 0;
2318 str = buf; 2314 str = buf;
2322 if (str >= buf + UBUFSIZ) 2318 if (str >= buf + UBUFSIZ)
2323 { 2319 {
2324 ch = NOCHAR; 2320 ch = NOCHAR;
2325 break; 2321 break;
2326 } 2322 }
2323
2324 seq_begin = cmdbuf_ptr;
2325 ch = next_char ();
2327 } 2326 }
2328 2327
2329 scr_add_lines (buf, nlines, str - buf); 2328 scr_add_lines (buf, nlines, str - buf);
2330 2329
2331 /* 2330 /*

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines