aboutsummaryrefslogtreecommitdiffstats
path: root/src/fringe.c
diff options
context:
space:
mode:
authorEli Zaretskii2012-09-09 23:10:36 +0300
committerEli Zaretskii2012-09-09 23:10:36 +0300
commitaba05ce9b6381e3538cfc22dbce7dd7df4ad7342 (patch)
tree4b1e7951aa0fdf74e70b470f3e4841d8a3b31a26 /src/fringe.c
parente99579563e157a993cef09ee61ea3d0027358f1a (diff)
downloademacs-aba05ce9b6381e3538cfc22dbce7dd7df4ad7342.tar.gz
emacs-aba05ce9b6381e3538cfc22dbce7dd7df4ad7342.zip
Avoid leaving traces of cursor when entering linum-mode.
src/fringe.c (draw_fringe_bitmap_1): Don't reduce the width of the left fringe if the window has a left margin. This avoids leaving traces of the cursor because its leftmost pixel is not drawn over.
Diffstat (limited to 'src/fringe.c')
-rw-r--r--src/fringe.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/fringe.c b/src/fringe.c
index 97d03a2bfae..0c2109a0f8e 100644
--- a/src/fringe.c
+++ b/src/fringe.c
@@ -659,7 +659,14 @@ draw_fringe_bitmap_1 (struct window *w, struct glyph_row *row, int left_p, int o
659 { 659 {
660 /* If W has a vertical border to its left, don't draw over it. */ 660 /* If W has a vertical border to its left, don't draw over it. */
661 wd -= ((!WINDOW_LEFTMOST_P (w) 661 wd -= ((!WINDOW_LEFTMOST_P (w)
662 && !WINDOW_HAS_VERTICAL_SCROLL_BAR (w)) 662 && !WINDOW_HAS_VERTICAL_SCROLL_BAR (w)
663 /* But don't reduce the fringe width if the window
664 has a left margin, because that means we are not
665 in danger of drawing over the vertical border,
666 and OTOH leaving out that one pixel leaves behind
667 traces of the cursor, if it was in column zero
668 before drawing non-empty margin area. */
669 && NILP (w->left_margin_cols))
663 ? 1 : 0); 670 ? 1 : 0);
664 p.bx = x - wd; 671 p.bx = x - wd;
665 p.nx = wd; 672 p.nx = wd;