aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenichi Handa1998-03-03 01:29:16 +0000
committerKenichi Handa1998-03-03 01:29:16 +0000
commit93fdf93bc151e6679ec0d000ad040ec1daf70c61 (patch)
treebd0a083a78e081e2678d5fd464e814e7c650934c
parent61ee73836b850cd8efd5d959e20b6400e89d985c (diff)
downloademacs-93fdf93bc151e6679ec0d000ad040ec1daf70c61.tar.gz
emacs-93fdf93bc151e6679ec0d000ad040ec1daf70c61.zip
(try_window_id): Use DEC_BOTH unconditionally.
(display_text_line): Likewise.
-rw-r--r--src/xdisp.c26
1 files changed, 5 insertions, 21 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index 301bd50dc41..da3d10a77b2 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -2520,7 +2520,6 @@ try_window_id (window)
2520 int selective = (INTEGERP (current_buffer->selective_display) 2520 int selective = (INTEGERP (current_buffer->selective_display)
2521 ? XINT (current_buffer->selective_display) 2521 ? XINT (current_buffer->selective_display)
2522 : !NILP (current_buffer->selective_display) ? -1 : 0); 2522 : !NILP (current_buffer->selective_display) ? -1 : 0);
2523 int multibyte = !NILP (current_buffer->enable_multibyte_characters);
2524 struct position val, bp, ep, xp, pp; 2523 struct position val, bp, ep, xp, pp;
2525 int scroll_amount = 0; 2524 int scroll_amount = 0;
2526 int delta; 2525 int delta;
@@ -2599,11 +2598,7 @@ try_window_id (window)
2599 val.hpos = bp.prevhpos - width + lmargin; 2598 val.hpos = bp.prevhpos - width + lmargin;
2600 val.tab_offset = bp.tab_offset + bp.prevhpos - width; 2599 val.tab_offset = bp.tab_offset + bp.prevhpos - width;
2601 did_motion = 1; 2600 did_motion = 1;
2602 pos--; 2601 DEC_BOTH (pos, pos_byte);
2603 if (multibyte)
2604 DEC_POS (pos_byte);
2605 else
2606 pos_byte--;
2607 } 2602 }
2608 2603
2609 bp.vpos = vpos; 2604 bp.vpos = vpos;
@@ -2866,11 +2861,7 @@ try_window_id (window)
2866 { 2861 {
2867 val.hpos = xp.prevhpos - width + lmargin; 2862 val.hpos = xp.prevhpos - width + lmargin;
2868 val.tab_offset = xp.tab_offset + bp.prevhpos - width; 2863 val.tab_offset = xp.tab_offset + bp.prevhpos - width;
2869 pos--; 2864 DEC_BOTH (pos, pos_byte);
2870 if (multibyte)
2871 DEC_POS (pos_byte);
2872 else
2873 pos_byte--;
2874 } 2865 }
2875 2866
2876 blank_end_of_window = 1; 2867 blank_end_of_window = 1;
@@ -3277,12 +3268,9 @@ display_text_line (w, start, start_byte, vpos, hpos, taboffset, ovstr_done)
3277 if (left_edge->vpos > vpos 3268 if (left_edge->vpos > vpos
3278 || left_edge->hpos > 0) 3269 || left_edge->hpos > 0)
3279 { 3270 {
3280 pos = left_edge->bufpos - 1; 3271 pos = left_edge->bufpos;
3281 pos_byte = left_edge->bytepos; 3272 pos_byte = left_edge->bytepos;
3282 if (multibyte) 3273 DEC_BOTH (pos, pos_byte);
3283 DEC_POS (pos_byte);
3284 else
3285 pos_byte--;
3286 hpos = left_edge->prevhpos; 3274 hpos = left_edge->prevhpos;
3287 } 3275 }
3288 else 3276 else
@@ -3926,11 +3914,7 @@ display_text_line (w, start, start_byte, vpos, hpos, taboffset, ovstr_done)
3926 { 3914 {
3927 *p1++ = fix_glyph (f, continuer, 0); 3915 *p1++ = fix_glyph (f, continuer, 0);
3928 val.vpos = 0; 3916 val.vpos = 0;
3929 lastpos--; 3917 DEC_BOTH (lastpos, lastpos_byte);
3930 if (multibyte)
3931 DEC_POS (lastpos_byte);
3932 else
3933 lastpos_byte--;
3934 val.tab_offset = taboffset + width; 3918 val.tab_offset = taboffset + width;
3935 } 3919 }
3936 } 3920 }