comparison src/xterm.c @ 25633:ddf2e1fef00b

(XTread_socket): In XSetInputFocus, use RevertToParent, not RevertToPointerRoot. (XTset_vertical_scroll_bar) [!USE_TOOLKIT_SCROLL_BARS]: Fix the code to clear around the scroll bar.
author Richard M. Stallman <rms@gnu.org>
date Sat, 11 Sep 1999 01:15:25 +0000
parents e98819a94512
children 9154af188477
comparison
equal deleted inserted replaced
25632:82ebdf9967da 25633:ddf2e1fef00b
8002 sb_width - VERTICAL_SCROLL_BAR_WIDTH_TRIM * 2, 8002 sb_width - VERTICAL_SCROLL_BAR_WIDTH_TRIM * 2,
8003 height, 0); 8003 height, 0);
8004 8004
8005 #else /* not USE_TOOLKIT_SCROLL_BARS */ 8005 #else /* not USE_TOOLKIT_SCROLL_BARS */
8006 8006
8007 /* Clear areas not covered by the scroll bar. This makes sure a 8007 if (VERTICAL_SCROLL_BAR_WIDTH_TRIM)
8008 previous mode line display is cleared after C-x 2 C-x 1, for 8008 {
8009 example. Non-toolkit scroll bars are as wide as the area 8009 /* Clear areas not covered by the scroll bar. This makes sure a
8010 reserved for scroll bars - trim at both sides. */ 8010 previous mode line display is cleared after C-x 2 C-x 1, for
8011 XClearArea (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), 8011 example. Non-toolkit scroll bars are as wide as the area
8012 left, top, VERTICAL_SCROLL_BAR_WIDTH_TRIM, 8012 reserved for scroll bars - trim at both sides. */
8013 height, False); 8013 XClearArea (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f),
8014 XClearArea (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), 8014 left, top, VERTICAL_SCROLL_BAR_WIDTH_TRIM,
8015 left + width - VERTICAL_SCROLL_BAR_WIDTH_TRIM, 8015 height, False);
8016 top, VERTICAL_SCROLL_BAR_WIDTH_TRIM, 8016 XClearArea (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f),
8017 height, False); 8017 left + width - VERTICAL_SCROLL_BAR_WIDTH_TRIM,
8018 top, VERTICAL_SCROLL_BAR_WIDTH_TRIM,
8019 height, False);
8020 }
8018 8021
8019 /* Move/size the scroll bar window. */ 8022 /* Move/size the scroll bar window. */
8020 if (mask) 8023 if (mask)
8021 { 8024 {
8022 XWindowChanges wc; 8025 XWindowChanges wc;
8734 Display *d = event.xclient.display; 8737 Display *d = event.xclient.display;
8735 /* Catch and ignore errors, in case window has been 8738 /* Catch and ignore errors, in case window has been
8736 iconified by a window manager such as GWM. */ 8739 iconified by a window manager such as GWM. */
8737 int count = x_catch_errors (d); 8740 int count = x_catch_errors (d);
8738 XSetInputFocus (d, event.xclient.window, 8741 XSetInputFocus (d, event.xclient.window,
8739 RevertToPointerRoot, 8742 /* The ICCCM says this is
8743 the only valid choice. */
8744 RevertToParent,
8740 event.xclient.data.l[1]); 8745 event.xclient.data.l[1]);
8741 /* This is needed to detect the error 8746 /* This is needed to detect the error
8742 if there is an error. */ 8747 if there is an error. */
8743 XSync (d, False); 8748 XSync (d, False);
8744 x_uncatch_errors (d, count); 8749 x_uncatch_errors (d, count);