Am Samstag, 10. September 2005 09:06 schrieb Juergen Spitzmueller: > Jean-Marc Lasgouttes wrote: > > Please commit, but with a stronger comment (with a FIXME or a > > #warning) in InsetText::neverIndent explaining that this is a hack and > > that cells should have their own InsetCell type. > > Done.
Unfortunately I get a segmentation fault now. The problem is that Paragraph::inInset() may return 0. The attached patch fixes that. It is going in right now because it is obviously the right fix. Georg
Index: src/ChangeLog =================================================================== RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/ChangeLog,v retrieving revision 1.2276 diff -u -p -r1.2276 ChangeLog --- src/ChangeLog 10 Sep 2005 06:51:56 -0000 1.2276 +++ src/ChangeLog 10 Sep 2005 13:26:05 -0000 @@ -1,3 +1,7 @@ +2005-09-10 Georg Baum <[EMAIL PROTECTED]> + + * text.C (leftMargin): check for inInset == 0 + 2005-08-10 Jürgen Spitzmüller <[EMAIL PROTECTED]> * text.C (leftMargin): test for insetbase's new neverIndent() Index: src/text.C =================================================================== RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/text.C,v retrieving revision 1.626 diff -u -p -r1.626 text.C --- src/text.C 10 Sep 2005 06:51:58 -0000 1.626 +++ src/text.C 10 Sep 2005 13:26:14 -0000 @@ -592,7 +592,7 @@ int LyXText::leftMargin(pit_type const p && align == LYX_ALIGN_BLOCK && !par.params().noindent() // in some insets, paragraphs are never indented - && !par.inInset()->neverIndent() + && !(par.inInset() && par.inInset()->neverIndent()) // display style insets are always centered, omit indentation && !(!par.empty() && par.isInset(pos)