it->area = LEFT_MARGIN_AREA;
it->face_id = default_face->id;
while (it->glyph_row->used[LEFT_MARGIN_AREA]
- < WINDOW_LEFT_MARGIN_WIDTH (it->w))
+ < WINDOW_LEFT_MARGIN_WIDTH (it->w)
+ && g < it->glyph_row->glyphs[TEXT_AREA])
{
PRODUCE_GLYPHS (it);
/* term.c:produce_glyphs advances it->current_x only for
TEXT_AREA. */
it->current_x += it->pixel_width;
- ++it->glyph_row->used[LEFT_MARGIN_AREA];
+ g++;
}
it->current_x = saved_x;
it->area = RIGHT_MARGIN_AREA;
it->face_id = default_face->id;
while (it->glyph_row->used[RIGHT_MARGIN_AREA]
- < WINDOW_RIGHT_MARGIN_WIDTH (it->w))
+ < WINDOW_RIGHT_MARGIN_WIDTH (it->w)
+ && g < it->glyph_row->glyphs[LAST_AREA])
{
PRODUCE_GLYPHS (it);
it->current_x += it->pixel_width;
- ++it->glyph_row->used[RIGHT_MARGIN_AREA];
+ g++;
}
it->area = TEXT_AREA;