diff options
| author | YAMAMOTO Mitsuharu | 2006-02-23 09:07:23 +0000 |
|---|---|---|
| committer | YAMAMOTO Mitsuharu | 2006-02-23 09:07:23 +0000 |
| commit | 7889775856af24b29d4613231e7d8be0217064c0 (patch) | |
| tree | 8628dfecf52c497080ed8279a8437c9903631683 /src | |
| parent | 7efc64d4be1c4529cde72a215ef59ff17c497a7d (diff) | |
| download | emacs-7889775856af24b29d4613231e7d8be0217064c0.tar.gz emacs-7889775856af24b29d4613231e7d8be0217064c0.zip | |
(update_text_area): Avoid needless redraw of rightmost
glyph whose face is extended to the text area end.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/dispnew.c | 13 |
2 files changed, 15 insertions, 3 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 2630efe73b7..df85b407911 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2006-02-23 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | ||
| 2 | |||
| 3 | * dispnew.c (update_text_area): Avoid needless redraw of rightmost | ||
| 4 | glyph whose face is extended to the text area end. | ||
| 5 | |||
| 1 | 2006-02-22 Stefan Monnier <monnier@iro.umontreal.ca> | 6 | 2006-02-22 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 7 | ||
| 3 | * window.c (Fwindow_list): Check `window' before doing XWINDOW. | 8 | * window.c (Fwindow_list): Check `window' before doing XWINDOW. |
diff --git a/src/dispnew.c b/src/dispnew.c index 52d5b989800..f6ce8eb43f4 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -4358,10 +4358,14 @@ update_text_area (w, vpos) | |||
| 4358 | int overlapping_glyphs_p = current_row->contains_overlapping_glyphs_p; | 4358 | int overlapping_glyphs_p = current_row->contains_overlapping_glyphs_p; |
| 4359 | int desired_stop_pos = desired_row->used[TEXT_AREA]; | 4359 | int desired_stop_pos = desired_row->used[TEXT_AREA]; |
| 4360 | 4360 | ||
| 4361 | /* If the desired row extends its face to the text area end, | 4361 | /* If the desired row extends its face to the text area end, and |
| 4362 | unless the current row also does so at the same position, | ||
| 4362 | make sure we write at least one glyph, so that the face | 4363 | make sure we write at least one glyph, so that the face |
| 4363 | extension actually takes place. */ | 4364 | extension actually takes place. */ |
| 4364 | if (MATRIX_ROW_EXTENDS_FACE_P (desired_row)) | 4365 | if (MATRIX_ROW_EXTENDS_FACE_P (desired_row) |
| 4366 | && (desired_stop_pos < current_row->used[TEXT_AREA] | ||
| 4367 | || (desired_stop_pos == current_row->used[TEXT_AREA] | ||
| 4368 | && !MATRIX_ROW_EXTENDS_FACE_P (current_row)))) | ||
| 4365 | --desired_stop_pos; | 4369 | --desired_stop_pos; |
| 4366 | 4370 | ||
| 4367 | stop = min (current_row->used[TEXT_AREA], desired_stop_pos); | 4371 | stop = min (current_row->used[TEXT_AREA], desired_stop_pos); |
| @@ -4480,7 +4484,10 @@ update_text_area (w, vpos) | |||
| 4480 | has to be cleared, if and only if we did a write_glyphs | 4484 | has to be cleared, if and only if we did a write_glyphs |
| 4481 | above. This is made sure by setting desired_stop_pos | 4485 | above. This is made sure by setting desired_stop_pos |
| 4482 | appropriately above. */ | 4486 | appropriately above. */ |
| 4483 | xassert (i < desired_row->used[TEXT_AREA]); | 4487 | xassert (i < desired_row->used[TEXT_AREA] |
| 4488 | || ((desired_row->used[TEXT_AREA] | ||
| 4489 | == current_row->used[TEXT_AREA]) | ||
| 4490 | && MATRIX_ROW_EXTENDS_FACE_P (current_row))); | ||
| 4484 | } | 4491 | } |
| 4485 | else if (MATRIX_ROW_EXTENDS_FACE_P (current_row)) | 4492 | else if (MATRIX_ROW_EXTENDS_FACE_P (current_row)) |
| 4486 | { | 4493 | { |