From 4e8cc18554ca1cc0f7ffa4564f5535c7eee3a63c Mon Sep 17 00:00:00 2001 From: Enrico Forestieri Date: Wed, 22 Dec 2010 00:16:51 +0000 Subject: [PATCH] Fix bug #7193 (Math macro template painting problem) git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36987 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/rowpainter.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/rowpainter.cpp b/src/rowpainter.cpp index fccb894c3f..bb529748bb 100644 --- a/src/rowpainter.cpp +++ b/src/rowpainter.cpp @@ -38,6 +38,8 @@ #include "insets/InsetText.h" +#include "mathed/InsetMath.h" + #include "support/debug.h" #include "support/gettext.h" #include "support/textutils.h" @@ -752,9 +754,11 @@ void RowPainter::paintOnlyInsets() for (pos_type pos = row_.pos(); pos != end; ++pos) { // If outer row has changed, nested insets are repaint completely. Inset const * inset = par_.getInset(pos); - bool const nested_inset = inset && (inset->inMathed() || - inset->asInsetText() || - inset->asInsetTabular()); + bool const nested_inset = inset && + ((inset->asInsetMath() && + !inset->asInsetMath()->asMacroTemplate()) + || inset->asInsetText() + || inset->asInsetTabular()); if (!nested_inset) continue; if (x_ > pi_.base.bv->workWidth() -- 2.39.5