aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerd Moellmann1999-08-06 13:59:29 +0000
committerGerd Moellmann1999-08-06 13:59:29 +0000
commit2febf6e0335cb2e6ae5aff51cd1b356e0a8e2629 (patch)
tree38f61acf20dafd4bf5218d792aa9ac6f02d82a63
parent413e06a447a92e7cdb727db8e0e15fedce504871 (diff)
downloademacs-2febf6e0335cb2e6ae5aff51cd1b356e0a8e2629.tar.gz
emacs-2febf6e0335cb2e6ae5aff51cd1b356e0a8e2629.zip
(struct glyph_row): Add overlapping_p.
(MATRIX_ROW_OVERLAPS_PRED_P): New. (MATRIX_ROW_OVERLAPS_SUCC_P): New. (struct glyph_row): Add flag overlapped_p. (MATRIX_ROW_OVERLAPPING_P): New. (struct redisplay_interface): Add fix_overlapping_area. (struct glyph): Add overlaps_vertically_p. (struct glyph_row): Add phys_ascent and phys_height. (struct it): Add phys_ascent, phys_descent, max_phys_ascent, max_phys_descent.
-rw-r--r--src/dispextern.h43
1 files changed, 38 insertions, 5 deletions
diff --git a/src/dispextern.h b/src/dispextern.h
index 5f62cef1432..1e81f05f751 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -262,6 +262,11 @@ struct glyph
262 unsigned left_box_line_p : 1; 262 unsigned left_box_line_p : 1;
263 unsigned right_box_line_p : 1; 263 unsigned right_box_line_p : 1;
264 264
265 /* Non-zero means this glyph's physical ascent or descent is greater
266 than its logical ascent/descent, i.e. it may potentially overlap
267 glyphs above or below it. */
268 unsigned overlaps_vertically_p : 1;
269
265 /* A union of sub-structures for different glyph types. */ 270 /* A union of sub-structures for different glyph types. */
266 union 271 union
267 { 272 {
@@ -563,10 +568,15 @@ struct glyph_row
563 end of the row into account. */ 568 end of the row into account. */
564 int pixel_width; 569 int pixel_width;
565 570
566 /* Height information. The value of ascent is zero and height is 1 571 /* Logical ascent/height of this line. The value of ascent is zero
567 on terminal frames. */ 572 and height is 1 on terminal frames. */
568 int ascent, height; 573 int ascent, height;
569 574
575 /* Physical ascent/height of this line. If max_ascent > ascent,
576 this line overlaps the line above it on the display. Otherwise,
577 if max_height > height, this line overlaps the line beneath it. */
578 int phys_ascent, phys_height;
579
570 /* Portion of row that is visible. Partially visible rows may be 580 /* Portion of row that is visible. Partially visible rows may be
571 found at the top and bottom of a window. This is 1 for tty 581 found at the top and bottom of a window. This is 1 for tty
572 frames. It may be < 0 in case of completely invisible rows. */ 582 frames. It may be < 0 in case of completely invisible rows. */
@@ -639,6 +649,12 @@ struct glyph_row
639 /* Non-zero means row is a mode or top-line. */ 649 /* Non-zero means row is a mode or top-line. */
640 unsigned mode_line_p : 1; 650 unsigned mode_line_p : 1;
641 651
652 /* 1 in a current row means this row is overlapped by another row. */
653 unsigned overlapped_p : 1;
654
655 /* 1 in a current row means this row overlaps others. */
656 unsigned overlapping_p : 1;
657
642 /* Continuation lines width at the start of the row. */ 658 /* Continuation lines width at the start of the row. */
643 int continuation_lines_width; 659 int continuation_lines_width;
644}; 660};
@@ -778,7 +794,17 @@ struct glyph_row *matrix_row P_ ((struct glyph_matrix *, int));
778 || ((ROW)->start.overlay_string_index >= 0 \ 794 || ((ROW)->start.overlay_string_index >= 0 \
779 && (ROW)->start.string_pos.charpos > 0)) 795 && (ROW)->start.string_pos.charpos > 0))
780 796
781 797/* Non-zero means ROW overlaps its predecessor. */
798
799#define MATRIX_ROW_OVERLAPS_PRED_P(ROW) \
800 ((ROW)->phys_ascent > (ROW)->ascent)
801
802/* Non-zero means ROW overlaps its successor. */
803
804#define MATRIX_ROW_OVERLAPS_SUCC_P(ROW) \
805 ((ROW)->phys_height - (ROW)->phys_ascent \
806 > (ROW)->height - (ROW)->ascent)
807
782/* Non-zero means that fonts have been loaded since the last glyph 808/* Non-zero means that fonts have been loaded since the last glyph
783 matrix adjustments. The function redisplay_internal adjusts glyph 809 matrix adjustments. The function redisplay_internal adjusts glyph
784 matrices when this flag is non-zero. */ 810 matrices when this flag is non-zero. */
@@ -1638,9 +1664,10 @@ struct it
1638 produce_glyphs. */ 1664 produce_glyphs. */
1639 int pixel_width; 1665 int pixel_width;
1640 1666
1641 /* Current and maximum line height information. Result of 1667 /* Current, maximum logical, and maximum physical line height
1642 produce_glyphs. */ 1668 information. Result of produce_glyphs. */
1643 int ascent, descent, max_ascent, max_descent; 1669 int ascent, descent, max_ascent, max_descent;
1670 int phys_ascent, phys_descent, max_phys_ascent, max_phys_descent;
1644 1671
1645 /* Current x pixel position within the display line. This value 1672 /* Current x pixel position within the display line. This value
1646 does not include the width of continuation lines in front of the 1673 does not include the width of continuation lines in front of the
@@ -1781,6 +1808,12 @@ struct redisplay_interface
1781 frame F. */ 1808 frame F. */
1782 void (*get_glyph_overhangs) P_ ((struct glyph *glyph, struct frame *f, 1809 void (*get_glyph_overhangs) P_ ((struct glyph *glyph, struct frame *f,
1783 int *left, int *right)); 1810 int *left, int *right));
1811
1812 /* Fix the display of AREA of ROW in window W for overlapping rows.
1813 This function is called from redraw_overlapping_rows after
1814 desired rows have been made current. */
1815 void (*fix_overlapping_area) P_ ((struct window *w, struct glyph_row *row,
1816 enum glyph_row_area area));
1784}; 1817};
1785 1818
1786/* The current interface for window-based redisplay. */ 1819/* The current interface for window-based redisplay. */