aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog3
-rw-r--r--src/xterm.c49
2 files changed, 33 insertions, 19 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index e2058fe9164..e595f489911 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,8 @@
12001-10-29 Gerd Moellmann <gerd@gnu.org> 12001-10-29 Gerd Moellmann <gerd@gnu.org>
2 2
3 * xterm.c (x_after_update_window_line): Clear internal border
4 in different circumstances.
5
3 * xterm.c (XTread_socket) <KeyPress>: Don't use 6 * xterm.c (XTread_socket) <KeyPress>: Don't use
4 STRING_CHAR_AND_LENGTH if nchars == nbytes. From Kenichi Handa 7 STRING_CHAR_AND_LENGTH if nchars == nbytes. From Kenichi Handa
5 <handa@etl.go.jp>. 8 <handa@etl.go.jp>.
diff --git a/src/xterm.c b/src/xterm.c
index 3944556d57a..6893d294435 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -769,33 +769,44 @@ x_after_update_window_line (desired_row)
769 struct glyph_row *desired_row; 769 struct glyph_row *desired_row;
770{ 770{
771 struct window *w = updated_window; 771 struct window *w = updated_window;
772 struct frame *f;
773 int width;
772 774
773 xassert (w); 775 xassert (w);
774 776
775 if (!desired_row->mode_line_p && !w->pseudo_window_p) 777 if (!desired_row->mode_line_p && !w->pseudo_window_p)
776 { 778 {
777 struct frame *f;
778 int width;
779
780 BLOCK_INPUT; 779 BLOCK_INPUT;
781 x_draw_row_bitmaps (w, desired_row); 780 x_draw_row_bitmaps (w, desired_row);
782 781 UNBLOCK_INPUT;
783 /* When a window has disappeared, make sure that no rest of 782 }
784 full-width rows stays visible in the internal border. */ 783
785 if (windows_or_buffers_changed 784 /* When a window has disappeared, make sure that no rest of
786 && (f = XFRAME (w->frame), 785 full-width rows stays visible in the internal border. Could
787 width = FRAME_INTERNAL_BORDER_WIDTH (f), 786 check here if updated_window is the leftmost/rightmost window,
788 width != 0)) 787 but I guess it's not worth doing since vertically split windows
789 { 788 are almost never used, internal border is rarely set, and the
790 int height = desired_row->visible_height; 789 overhead is very small. */
791 int x = (window_box_right (w, -1) 790 if (windows_or_buffers_changed
792 + FRAME_X_RIGHT_FLAGS_AREA_WIDTH (f)); 791 && desired_row->full_width_p
793 int y = WINDOW_TO_FRAME_PIXEL_Y (w, max (0, desired_row->y)); 792 && (f = XFRAME (w->frame),
794 793 width = FRAME_INTERNAL_BORDER_WIDTH (f),
795 x_clear_area (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), 794 width != 0))
796 x, y, width, height, False); 795 {
797 } 796 int height = desired_row->visible_height;
797 int y = WINDOW_TO_FRAME_PIXEL_Y (w, max (0, desired_row->y));
798
799 /* Internal border is drawn below the tool bar. */
800 if (WINDOWP (f->tool_bar_window)
801 && w == XWINDOW (f->tool_bar_window))
802 y -= width;
798 803
804 BLOCK_INPUT;
805 x_clear_area (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f),
806 0, y, width, height, False);
807 x_clear_area (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f),
808 f->output_data.x->pixel_width - width,
809 y, width, height, False);
799 UNBLOCK_INPUT; 810 UNBLOCK_INPUT;
800 } 811 }
801} 812}