&& indented_beyond_p (IT_CHARPOS (*it), IT_BYTEPOS (*it),
it->selective))
visible_p = 0;
-#ifdef USE_TEXT_PROPERTIES
else
{
Lisp_Object prop;
if (TEXT_PROP_MEANS_INVISIBLE (prop))
visible_p = 0;
}
-#endif /* USE_TEXT_PROPERTIES */
/* Back one more newline if the current one is invisible. */
if (!visible_p)
struct it *it;
int start_charpos, end_charpos;
{
-#ifdef USE_TEXT_PROPERTIES
Lisp_Object prop, limit;
int invisible_found_p;
}
return invisible_found_p;
-
-#else /* not USE_TEXT_PROPERTIES */
- return 0;
-#endif /* not USE_TEXT_PROPERTIES */
}
max_height = min (total_height, max_height);
/* Find out the height of the text in the window. */
+ last_height = 0;
move_it_to (&it, ZV, -1, -1, -1, MOVE_TO_POS);
- height = (unit - 1 + it.current_y + last_height) / unit;
- height = max (1, height);
+ if (it.max_ascent == 0 && it.max_descent == 0)
+ height = it.current_y + last_height;
+ else
+ height = it.current_y + it.max_ascent + it.max_descent;
+ height = (height + unit - 1) / unit;
/* Compute a suitable window start. */
if (height > max_height)
if (!get_next_display_element (it))
{
/* Maybe add a space at the end of this line that is used to
- display the cursor there under X. */
- if (append_space (it, 1) && row->used[TEXT_AREA] == 1)
+ display the cursor there under X. Set the charpos of the
+ first glyph of blank lines not corresponding to any text
+ to -1. */
+ if ((append_space (it, 1) && row->used[TEXT_AREA] == 1)
+ || row->used[TEXT_AREA] == 0)
{
- /* The position -1 below indicates a blank line not
- corresponding to any text, as opposed to an empty line
- corresponding to a line end. */
row->glyphs[TEXT_AREA]->charpos = -1;
row->displays_text_p = 0;