diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/xdisp.c | 89 |
2 files changed, 5 insertions, 89 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index c6a10fc978b..af619a9a26a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -5,6 +5,11 @@ | |||
| 5 | 5 | ||
| 6 | 2009-06-28 Chong Yidong <cyd@stupidchicken.com> | 6 | 2009-06-28 Chong Yidong <cyd@stupidchicken.com> |
| 7 | 7 | ||
| 8 | * xdisp.c (start_display, handle_face_prop) | ||
| 9 | (move_it_vertically_backward, cursor_row_fully_visible_p) | ||
| 10 | (redisplay_window, try_window_id, produce_image_glyph): Delete | ||
| 11 | some #ifdef-ed out code chunks that are now obsolete. | ||
| 12 | |||
| 8 | * xterm.c (x_update_window_begin, x_new_focus_frame) | 13 | * xterm.c (x_update_window_begin, x_new_focus_frame) |
| 9 | (x_scroll_bar_handle_click, handle_one_xevent) | 14 | (x_scroll_bar_handle_click, handle_one_xevent) |
| 10 | (handle_one_xevent, XTread_socket, x_focus_on_frame) | 15 | (handle_one_xevent, XTread_socket, x_focus_on_frame) |
diff --git a/src/xdisp.c b/src/xdisp.c index 5fc634b20ea..ffe1e9ede2e 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -2897,16 +2897,6 @@ start_display (it, w, pos) | |||
| 2897 | it->current_x = it->hpos = 0; | 2897 | it->current_x = it->hpos = 0; |
| 2898 | } | 2898 | } |
| 2899 | } | 2899 | } |
| 2900 | |||
| 2901 | #if 0 /* Don't assert the following because start_display is sometimes | ||
| 2902 | called intentionally with a window start that is not at a | ||
| 2903 | line start. Please leave this code in as a comment. */ | ||
| 2904 | |||
| 2905 | /* Window start should be on a line start, now. */ | ||
| 2906 | xassert (it->continuation_lines_width | ||
| 2907 | || IT_CHARPOS (it) == BEGV | ||
| 2908 | || FETCH_BYTE (IT_BYTEPOS (it) - 1) == '\n'); | ||
| 2909 | #endif /* 0 */ | ||
| 2910 | } | 2900 | } |
| 2911 | 2901 | ||
| 2912 | 2902 | ||
| @@ -3546,14 +3536,6 @@ handle_face_prop (it) | |||
| 3546 | &next_stop, | 3536 | &next_stop, |
| 3547 | base_face_id, 0); | 3537 | base_face_id, 0); |
| 3548 | 3538 | ||
| 3549 | #if 0 /* This shouldn't be neccessary. Let's check it. */ | ||
| 3550 | /* If IT is used to display a mode line we would really like to | ||
| 3551 | use the mode line face instead of the frame's default face. */ | ||
| 3552 | if (it->glyph_row == MATRIX_MODE_LINE_ROW (it->w->desired_matrix) | ||
| 3553 | && new_face_id == DEFAULT_FACE_ID) | ||
| 3554 | new_face_id = CURRENT_MODE_LINE_FACE_ID (it->w); | ||
| 3555 | #endif | ||
| 3556 | |||
| 3557 | /* Is this a start of a run of characters with box? Caveat: | 3539 | /* Is this a start of a run of characters with box? Caveat: |
| 3558 | this can be called for a freshly allocated iterator; face_id | 3540 | this can be called for a freshly allocated iterator; face_id |
| 3559 | is -1 is this case. We know that the new face will not | 3541 | is -1 is this case. We know that the new face will not |
| @@ -7414,11 +7396,6 @@ move_it_vertically_backward (it, dy) | |||
| 7414 | value of nlines is > 0 if continuation lines were involved. */ | 7396 | value of nlines is > 0 if continuation lines were involved. */ |
| 7415 | if (nlines > 0) | 7397 | if (nlines > 0) |
| 7416 | move_it_by_lines (it, nlines, 1); | 7398 | move_it_by_lines (it, nlines, 1); |
| 7417 | #if 0 | ||
| 7418 | /* I think this assert is bogus if buffer contains | ||
| 7419 | invisible text or images. KFS. */ | ||
| 7420 | xassert (IT_CHARPOS (*it) <= start_pos); | ||
| 7421 | #endif | ||
| 7422 | } | 7399 | } |
| 7423 | else | 7400 | else |
| 7424 | { | 7401 | { |
| @@ -7466,12 +7443,6 @@ move_it_vertically_backward (it, dy) | |||
| 7466 | } | 7443 | } |
| 7467 | while (target_y >= line_bottom_y (it) && IT_CHARPOS (*it) < ZV); | 7444 | while (target_y >= line_bottom_y (it) && IT_CHARPOS (*it) < ZV); |
| 7468 | } | 7445 | } |
| 7469 | |||
| 7470 | #if 0 | ||
| 7471 | /* I think this assert is bogus if buffer contains | ||
| 7472 | invisible text or images. KFS. */ | ||
| 7473 | xassert (IT_CHARPOS (*it) >= BEGV); | ||
| 7474 | #endif | ||
| 7475 | } | 7446 | } |
| 7476 | } | 7447 | } |
| 7477 | } | 7448 | } |
| @@ -11456,7 +11427,6 @@ redisplay_internal (preserve_echo_area) | |||
| 11456 | } | 11427 | } |
| 11457 | } | 11428 | } |
| 11458 | 11429 | ||
| 11459 | |||
| 11460 | /* Notice any pending interrupt request to change frame size. */ | 11430 | /* Notice any pending interrupt request to change frame size. */ |
| 11461 | do_pending_window_change (1); | 11431 | do_pending_window_change (1); |
| 11462 | 11432 | ||
| @@ -12589,44 +12559,6 @@ cursor_row_fully_visible_p (w, force_p, current_matrix_p) | |||
| 12589 | return 1; | 12559 | return 1; |
| 12590 | } | 12560 | } |
| 12591 | return 0; | 12561 | return 0; |
| 12592 | |||
| 12593 | #if 0 | ||
| 12594 | /* This code used to try to scroll the window just enough to make | ||
| 12595 | the line visible. It returned 0 to say that the caller should | ||
| 12596 | allocate larger glyph matrices. */ | ||
| 12597 | |||
| 12598 | if (MATRIX_ROW_PARTIALLY_VISIBLE_AT_TOP_P (w, row)) | ||
| 12599 | { | ||
| 12600 | int dy = row->height - row->visible_height; | ||
| 12601 | w->vscroll = 0; | ||
| 12602 | w->cursor.y += dy; | ||
| 12603 | shift_glyph_matrix (w, matrix, 0, matrix->nrows, dy); | ||
| 12604 | } | ||
| 12605 | else /* MATRIX_ROW_PARTIALLY_VISIBLE_AT_BOTTOM_P (w, row)) */ | ||
| 12606 | { | ||
| 12607 | int dy = - (row->height - row->visible_height); | ||
| 12608 | w->vscroll = dy; | ||
| 12609 | w->cursor.y += dy; | ||
| 12610 | shift_glyph_matrix (w, matrix, 0, matrix->nrows, dy); | ||
| 12611 | } | ||
| 12612 | |||
| 12613 | /* When we change the cursor y-position of the selected window, | ||
| 12614 | change this_line_y as well so that the display optimization for | ||
| 12615 | the cursor line of the selected window in redisplay_internal uses | ||
| 12616 | the correct y-position. */ | ||
| 12617 | if (w == XWINDOW (selected_window)) | ||
| 12618 | this_line_y = w->cursor.y; | ||
| 12619 | |||
| 12620 | /* If vscrolling requires a larger glyph matrix, arrange for a fresh | ||
| 12621 | redisplay with larger matrices. */ | ||
| 12622 | if (matrix->nrows < required_matrix_height (w)) | ||
| 12623 | { | ||
| 12624 | fonts_changed_p = 1; | ||
| 12625 | return 0; | ||
| 12626 | } | ||
| 12627 | |||
| 12628 | return 1; | ||
| 12629 | #endif /* 0 */ | ||
| 12630 | } | 12562 | } |
| 12631 | 12563 | ||
| 12632 | 12564 | ||
| @@ -13595,11 +13527,6 @@ redisplay_window (window, just_this_one_p) | |||
| 13595 | used_current_matrix_p = 1; | 13527 | used_current_matrix_p = 1; |
| 13596 | goto done; | 13528 | goto done; |
| 13597 | 13529 | ||
| 13598 | #if 0 /* try_cursor_movement never returns this value. */ | ||
| 13599 | case CURSOR_MOVEMENT_NEED_LARGER_MATRICES: | ||
| 13600 | goto need_larger_matrices; | ||
| 13601 | #endif | ||
| 13602 | |||
| 13603 | case CURSOR_MOVEMENT_MUST_SCROLL: | 13530 | case CURSOR_MOVEMENT_MUST_SCROLL: |
| 13604 | goto try_to_scroll; | 13531 | goto try_to_scroll; |
| 13605 | 13532 | ||
| @@ -15569,15 +15496,6 @@ try_window_id (w) | |||
| 15569 | else | 15496 | else |
| 15570 | abort (); | 15497 | abort (); |
| 15571 | 15498 | ||
| 15572 | #if 0 /* This leads to problems, for instance when the cursor is | ||
| 15573 | at ZV, and the cursor line displays no text. */ | ||
| 15574 | /* Disable rows below what's displayed in the window. This makes | ||
| 15575 | debugging easier. */ | ||
| 15576 | enable_glyph_matrix_rows (current_matrix, | ||
| 15577 | XFASTINT (w->window_end_vpos) + 1, | ||
| 15578 | bottom_vpos, 0); | ||
| 15579 | #endif | ||
| 15580 | |||
| 15581 | IF_DEBUG (debug_end_pos = XFASTINT (w->window_end_pos); | 15499 | IF_DEBUG (debug_end_pos = XFASTINT (w->window_end_pos); |
| 15582 | debug_end_vpos = XFASTINT (w->window_end_vpos)); | 15500 | debug_end_vpos = XFASTINT (w->window_end_vpos)); |
| 15583 | 15501 | ||
| @@ -20795,13 +20713,6 @@ produce_image_glyph (it) | |||
| 20795 | if (it->descent < 0) | 20713 | if (it->descent < 0) |
| 20796 | it->descent = 0; | 20714 | it->descent = 0; |
| 20797 | 20715 | ||
| 20798 | #if 0 /* this breaks image tiling */ | ||
| 20799 | /* If this glyph is alone on the last line, adjust it.ascent to minimum row ascent. */ | ||
| 20800 | int face_ascent = face->font ? FONT_BASE (face->font) : FRAME_BASELINE_OFFSET (it->f); | ||
| 20801 | if (face_ascent > it->ascent) | ||
| 20802 | it->ascent = it->phys_ascent = face_ascent; | ||
| 20803 | #endif | ||
| 20804 | |||
| 20805 | it->nglyphs = 1; | 20716 | it->nglyphs = 1; |
| 20806 | 20717 | ||
| 20807 | if (face->box != FACE_NO_BOX) | 20718 | if (face->box != FACE_NO_BOX) |