From: Abdelrazak Younes Date: Sat, 1 Sep 2007 23:01:21 +0000 (+0000) Subject: * InsetCollapsable::metrics(): Put back the test previous to revision 14472 for openi... X-Git-Tag: 1.6.10~8560 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=452348f4ced63697e795bab93d9e1d83b58511f0;p=lyx.git * InsetCollapsable::metrics(): Put back the test previous to revision 14472 for openinlined_ git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19985 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/insets/InsetCollapsable.cpp b/src/insets/InsetCollapsable.cpp index d92e5d47f6..c3f6e434ac 100644 --- a/src/insets/InsetCollapsable.cpp +++ b/src/insets/InsetCollapsable.cpp @@ -209,9 +209,7 @@ bool InsetCollapsable::metrics(MetricsInfo & mi, Dimension & dim) const if (geometry() == TopButton || geometry() == LeftButton) { InsetText::metrics(mi, textdim_); - // This expression should not contain mi.base.texwidth - openinlined_ = !hasFixedWidth() - && textdim_.wid < 0.5 * mi.base.bv->workWidth(); + openinlined_ = (textdim_.wid + 2 * dim.wid) <= mi.base.textwidth; if (openinlined_) { // Correct for button width. dim.wid += textdim_.wid;