commit f5fe3c17be0a66b32085585962877dfc2dae9140
Author: Jean-Marc Lasgouttes <[email protected]>
Date:   Thu Nov 17 16:17:49 2016 +0100

    Reduce horizontal spacing for simple inline equations
---
 src/mathed/InsetMathHull.cpp |   18 ++++++++++++++++++
 src/mathed/InsetMathHull.h   |    6 ++++++
 2 files changed, 24 insertions(+), 0 deletions(-)

diff --git a/src/mathed/InsetMathHull.cpp b/src/mathed/InsetMathHull.cpp
index 851c1e6..38cdd26 100644
--- a/src/mathed/InsetMathHull.cpp
+++ b/src/mathed/InsetMathHull.cpp
@@ -2120,6 +2120,24 @@ bool InsetMathHull::getStatus(Cursor & cur, FuncRequest 
const & cmd,
 }
 
 
+int InsetMathHull::leftMargin() const
+{
+       return (getType() == hullSimple) ? 0 : InsetMathGrid::leftMargin();
+}
+
+
+int InsetMathHull::rightMargin() const
+{
+       return (getType() == hullSimple) ? 0 : InsetMathGrid::rightMargin();
+}
+
+
+int InsetMathHull::border() const
+{
+       return (getType() == hullSimple) ? 0 : InsetMathGrid::border();
+}
+
+
 /////////////////////////////////////////////////////////////////////
 
 
diff --git a/src/mathed/InsetMathHull.h b/src/mathed/InsetMathHull.h
index bc574b9..bae2653 100644
--- a/src/mathed/InsetMathHull.h
+++ b/src/mathed/InsetMathHull.h
@@ -200,6 +200,12 @@ protected:
        /// do we want to handle this event?
        bool getStatus(Cursor & cur, FuncRequest const & cmd,
                FuncStatus & status) const;
+       /// override to set to 0 for inline equation
+       int leftMargin() const;
+       /// override to set to 0 for inline equation
+       int rightMargin() const;
+       /// override to set to 0 for inline equation
+       int border() const;
        ///
        docstring eolString(row_type row, bool fragile, bool latex,
                        bool last_eoln) const;

Reply via email to