Attached. Fix along the lines of my bugzilla remark. I am not quite sure about the definition of leftEdgeFixed... please someone better informed refine this.
- Martin
Index: rowpainter.C
===================================================================
--- rowpainter.C (revision 16200)
+++ rowpainter.C (working copy)
@@ -893,6 +893,12 @@
bool cursor_on_row = CursorOnRow(pi, pit, rit, text);
bool in_inset_alone_on_row = innerCursorOnRow(pi, pit, rit,
text);
+ bool leftEdgeFixed =
+ (par.getAlign() == LYX_ALIGN_LEFT ||
+ par.getAlign() == LYX_ALIGN_BLOCK ||
+ (par.getAlign() == LYX_ALIGN_LAYOUT &&
+ (par.layout()->align == LYX_ALIGN_LEFT ||
+ par.layout()->align == LYX_ALIGN_BLOCK)));
// If this is the only object on the row, we can make it wide
//
@@ -905,7 +911,7 @@
if (in) {
InsetText * t = const_cast<InsetText *>(in->asTextInset());
if (t)
- t->setWide(in_inset_alone_on_row);
+ t->setWide(in_inset_alone_on_row && leftEdgeFixed);
}
}
@@ -924,7 +930,8 @@
// Clear background of this row
// (if paragraph background was not cleared)
if (!repaintAll &&
- (!in_inset_alone_on_row || row_has_changed)) {
+ (!(in_inset_alone_on_row && leftEdgeFixed)
+ || row_has_changed)) {
pi.pain.fillRectangle(x, y - rit->ascent(),
text.maxwidth_, rit->height(),
text.backgroundColor());
signature.asc
Description: This is a digitally signed message part
