From 7794f870f2b1a269969ff4b2af886220d2e7645c Mon Sep 17 00:00:00 2001 From: Stefan Schimanski Date: Thu, 21 Feb 2008 19:45:05 +0000 Subject: [PATCH] * add some space between math inset and popup. This should really come from the font maximal descent in fact. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23108 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/mathed/InsetMathNest.cpp | 6 ++++++ src/mathed/MathMacro.cpp | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/src/mathed/InsetMathNest.cpp b/src/mathed/InsetMathNest.cpp index f8228c4485..30e82c5b67 100644 --- a/src/mathed/InsetMathNest.cpp +++ b/src/mathed/InsetMathNest.cpp @@ -1665,6 +1665,12 @@ void InsetMathNest::completionPosAndDim(Cursor const & cur, int & x, int & y, // get inset dimensions dim = cur.bv().coordCache().insets().dim(inset); + // FIXME: these 3 are no accurate, but should depend on the font. + // Now the popup jumps down if you enter a char with descent > 0. + dim.des += 3; + dim.asc += 3; + + // and position Point xy = cur.bv().coordCache().insets().xy(inset); x = xy.x_; diff --git a/src/mathed/MathMacro.cpp b/src/mathed/MathMacro.cpp index 97c25f7a20..dd8d2814b8 100644 --- a/src/mathed/MathMacro.cpp +++ b/src/mathed/MathMacro.cpp @@ -800,6 +800,12 @@ void MathMacro::completionPosAndDim(Cursor const & cur, int & x, int & y, { // get inset dimensions dim = cur.bv().coordCache().insets().dim(this); + // FIXME: these 3 are no accurate, but should depend on the font. + // Now the popup jumps down if you enter a char with descent > 0. + dim.des += 3; + dim.asc += 3; + + // and position Point xy = cur.bv().coordCache().insets().xy(this); x = xy.x_; -- 2.39.2