+2000-07-07 Juergen Vigna <jug@sad.it>
+
+ * src/insets/insettext.C (draw): set the status of the bv->text to
+ CHANGED_IN_DRAW if top_x changed and so a reinit is necessary.
+
+ * src/screen.C (DrawOneRow):
+ (DrawFromTo): redraw the actual row if something has changed in it
+ while drawing.
+
+ * src/text.C (draw): call an update of the toplevel-inset if something
+ has changed inside while drawing.
+
+ * src/lyxtext.h: added CHANGED_IN_DRAW status.
+
2000-07-06 Angus Leeming <a.leeming@ic.ac.uk>
* src/insets/insetbib.[Ch] (callback) new method, moving callback
// y1 is now the real beginning of row on the screen
while (row != 0 && y < y2) {
- text->GetVisibleRow(owner.owner(), y+y_offset, x_offset, row, y + text->first);
+ LyXText::text_status st = text->status;
+ do {
+ text->status = st;
+ text->GetVisibleRow(owner.owner(), y+y_offset,
+ x_offset, row, y + text->first);
+ } while (text->status == LyXText::CHANGED_IN_DRAW);
+ text->status = st;
y += row->height();
row = row->next();
}
if (y + row->height() > 0
&& y - row->height() <= long(owner.height())) {
// ok there is something visible
- text->GetVisibleRow(owner.owner(), y, x_offset, row, y + text->first);
+ LyXText::text_status st = text->status;
+ do {
+ text->status = st;
+ text->GetVisibleRow(owner.owner(), y, x_offset, row,
+ y + text->first);
+ } while (text->status == LyXText::CHANGED_IN_DRAW);
+ text->status = st;
}
}
owner.workWidth(), text->refresh_row->height());
}
break;
+ case LyXText::CHANGED_IN_DRAW: // just to remove the warning
case LyXText::UNCHANGED:
// Nothing needs done
break;
// tmpinset->update(bview, font, false);
tmpinset->draw(bview, font, offset+row->baseline(), x,
cleared);
+ if (status == CHANGED_IN_DRAW)
+ UpdateInset(bview, tmpinset);
}
++vpos;