aboutsummaryrefslogtreecommitdiffstats
path: root/src/fringe.c
diff options
context:
space:
mode:
authorKaroly Lorentey2005-09-04 03:48:17 +0000
committerKaroly Lorentey2005-09-04 03:48:17 +0000
commitfbf349734468d48b421c3d03074bb66dfcf3115b (patch)
tree0a7d1ee844b6c591a5a499d23e35931945106e5a /src/fringe.c
parentf0caabd962b662cccbea472995d86af718cc8d0b (diff)
parent4b5fa40e1f1ba3cafde672863a0331311d1c2695 (diff)
downloademacs-fbf349734468d48b421c3d03074bb66dfcf3115b.tar.gz
emacs-fbf349734468d48b421c3d03074bb66dfcf3115b.zip
Merged in changes from CVS trunk. Plus added lisp/term tweaks.
Patches applied: * lorentey@elte.hu--2004/emacs--cvs-trunk--0--base-0 tag of miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-474 * lorentey@elte.hu--2004/emacs--cvs-trunk--0--patch-1 Add CVS metadata files. * lorentey@elte.hu--2004/emacs--cvs-trunk--0--patch-2 Update from CVS. git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-393
Diffstat (limited to 'src/fringe.c')
-rw-r--r--src/fringe.c39
1 files changed, 23 insertions, 16 deletions
diff --git a/src/fringe.c b/src/fringe.c
index 7731c0302e9..25de5aa604e 100644
--- a/src/fringe.c
+++ b/src/fringe.c
@@ -1,6 +1,7 @@
1/* Fringe handling (split from xdisp.c). 1/* Fringe handling (split from xdisp.c).
2 Copyright (C) 1985,86,87,88,93,94,95,97,98,99,2000,01,02,03,04 2 Copyright (C) 1985, 1986, 1987, 1988, 1993, 1994, 1995, 1997,
3 Free Software Foundation, Inc. 3 1998, 1999, 2000, 2000, 2001, 2002, 2003, 2004,
4 2005 Free Software Foundation, Inc.
4 5
5This file is part of GNU Emacs. 6This file is part of GNU Emacs.
6 7
@@ -777,13 +778,14 @@ draw_window_fringes (w, no_fringe)
777 778
778 779
779/* Recalculate the bitmaps to show in the fringes of window W. 780/* Recalculate the bitmaps to show in the fringes of window W.
780 If FORCE_P is 0, only mark rows with modified bitmaps for update in 781 Only mark rows with modified bitmaps for update in redraw_fringe_bitmaps_p.
781 redraw_fringe_bitmaps_p; else mark all rows for update. */ 782
783 If KEEP_CURRENT_P is 0, update current_matrix too. */
782 784
783int 785int
784update_window_fringes (w, force_p) 786update_window_fringes (w, keep_current_p)
785 struct window *w; 787 struct window *w;
786 int force_p; 788 int keep_current_p;
787{ 789{
788 struct glyph_row *row, *cur = 0; 790 struct glyph_row *row, *cur = 0;
789 int yb = window_text_bottom_y (w); 791 int yb = window_text_bottom_y (w);
@@ -849,7 +851,8 @@ update_window_fringes (w, force_p)
849 { 851 {
850 if (!done_top) 852 if (!done_top)
851 { 853 {
852 if (MATRIX_ROW_START_CHARPOS (row) <= BUF_BEGV (XBUFFER (w->buffer))) 854 if (MATRIX_ROW_START_CHARPOS (row) <= BUF_BEGV (XBUFFER (w->buffer))
855 && !MATRIX_ROW_PARTIALLY_VISIBLE_AT_TOP_P (w, row))
853 row->indicate_bob_p = !NILP (boundary_top); 856 row->indicate_bob_p = !NILP (boundary_top);
854 else 857 else
855 row->indicate_top_line_p = !NILP (arrow_top); 858 row->indicate_top_line_p = !NILP (arrow_top);
@@ -858,7 +861,8 @@ update_window_fringes (w, force_p)
858 861
859 if (!done_bot) 862 if (!done_bot)
860 { 863 {
861 if (MATRIX_ROW_END_CHARPOS (row) >= BUF_ZV (XBUFFER (w->buffer))) 864 if (MATRIX_ROW_END_CHARPOS (row) >= BUF_ZV (XBUFFER (w->buffer))
865 && !MATRIX_ROW_PARTIALLY_VISIBLE_AT_BOTTOM_P (w, row))
862 row->indicate_eob_p = !NILP (boundary_bot), done_bot = 1; 866 row->indicate_eob_p = !NILP (boundary_bot), done_bot = 1;
863 else if (y + row->height >= yb) 867 else if (y + row->height >= yb)
864 row->indicate_bottom_line_p = !NILP (arrow_bot), done_bot = 1; 868 row->indicate_bottom_line_p = !NILP (arrow_bot), done_bot = 1;
@@ -943,8 +947,7 @@ update_window_fringes (w, force_p)
943 else 947 else
944 right = NO_FRINGE_BITMAP; 948 right = NO_FRINGE_BITMAP;
945 949
946 if (force_p 950 if (row->y != cur->y
947 || row->y != cur->y
948 || row->visible_height != cur->visible_height 951 || row->visible_height != cur->visible_height
949 || row->ends_at_zv_p != cur->ends_at_zv_p 952 || row->ends_at_zv_p != cur->ends_at_zv_p
950 || left != cur->left_fringe_bitmap 953 || left != cur->left_fringe_bitmap
@@ -953,11 +956,15 @@ update_window_fringes (w, force_p)
953 || right_face_id != cur->right_fringe_face_id 956 || right_face_id != cur->right_fringe_face_id
954 || cur->redraw_fringe_bitmaps_p) 957 || cur->redraw_fringe_bitmaps_p)
955 { 958 {
956 redraw_p = row->redraw_fringe_bitmaps_p = cur->redraw_fringe_bitmaps_p = 1; 959 redraw_p = row->redraw_fringe_bitmaps_p = 1;
957 cur->left_fringe_bitmap = left; 960 if (!keep_current_p)
958 cur->right_fringe_bitmap = right; 961 {
959 cur->left_fringe_face_id = left_face_id; 962 cur->redraw_fringe_bitmaps_p = 1;
960 cur->right_fringe_face_id = right_face_id; 963 cur->left_fringe_bitmap = left;
964 cur->right_fringe_bitmap = right;
965 cur->left_fringe_face_id = left_face_id;
966 cur->right_fringe_face_id = right_face_id;
967 }
961 } 968 }
962 969
963 if (row->overlay_arrow_bitmap != cur->overlay_arrow_bitmap) 970 if (row->overlay_arrow_bitmap != cur->overlay_arrow_bitmap)
@@ -975,7 +982,7 @@ update_window_fringes (w, force_p)
975 row[-1].redraw_fringe_bitmaps_p = cur[-1].redraw_fringe_bitmaps_p = 1; 982 row[-1].redraw_fringe_bitmaps_p = cur[-1].redraw_fringe_bitmaps_p = 1;
976 } 983 }
977 984
978 return redraw_p; 985 return redraw_p && !keep_current_p;
979} 986}
980 987
981 988