X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fmathed%2FInsetMathPhantom.cpp;h=cd4ae451cfdcf7b594302ddd5c392b4171358441;hb=6de3c19fd63f810eed90ef3bc4469faf28e949c2;hp=bbc2234a1863b2fe59f442a40c59e6f4af5583cd;hpb=187790135b73e3e99a43e53f8c6494d119e94e98;p=lyx.git diff --git a/src/mathed/InsetMathPhantom.cpp b/src/mathed/InsetMathPhantom.cpp index bbc2234a18..cd4ae451cf 100644 --- a/src/mathed/InsetMathPhantom.cpp +++ b/src/mathed/InsetMathPhantom.cpp @@ -240,6 +240,8 @@ void InsetMathPhantom::draw(PainterInfo & pi, int x, int y) const void InsetMathPhantom::write(WriteStream & os) const { MathEnsurer ensurer(os); + if (os.fragile()) + os << "\\protect"; switch (kind_) { case phantom: os << "\\phantom{";