X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fmathed%2FCommandInset.cpp;h=0c9e585e1a7a976893db08d832889aba627b0c8b;hb=2de30c62f8d671a8c8d4d52a6a7310e2c5ca84de;hp=e09604e241c9f2973f1cde97d07172c05a9d343d;hpb=7d68833dc9dd3d8cecd8594b15b03f6d2ec9a036;p=lyx.git diff --git a/src/mathed/CommandInset.cpp b/src/mathed/CommandInset.cpp index e09604e241..0c9e585e1a 100644 --- a/src/mathed/CommandInset.cpp +++ b/src/mathed/CommandInset.cpp @@ -43,8 +43,6 @@ void CommandInset::metrics(MetricsInfo & mi, Dimension & dim) const button_.update(screenLabel(), true); } button_.metrics(mi, dim); - // Cache the inset dimension. - setDimCache(mi, dim); } @@ -58,7 +56,6 @@ Inset * CommandInset::editXY(Cursor & cur, int /*x*/, int /*y*/) void CommandInset::draw(PainterInfo & pi, int x, int y) const { button_.draw(pi, x, y); - setPosCache(pi, x, y); } @@ -67,7 +64,7 @@ void CommandInset::write(WriteStream & os) const ModeSpecifier specifier(os, currentMode(), lockedMode(), asciiOnly()); MathEnsurer ensurer(os, needs_math_mode_); os << '\\' << name_; - if (cell(1).size()) + if (!cell(1).empty()) os << '[' << cell(1) << ']'; os << '{' << cell(0) << '}'; }