]> git.lyx.org Git - features.git/commitdiff
Change handling of LFUN_MATH_LIMITS.
authorDekel Tsur <dekelts@tau.ac.il>
Mon, 28 Oct 2002 10:47:24 +0000 (10:47 +0000)
committerDekel Tsur <dekelts@tau.ac.il>
Mon, 28 Oct 2002 10:47:24 +0000 (10:47 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5529 a592a061-630c-0410-9148-cb99ea01b6c8

src/mathed/ChangeLog
src/mathed/math_scriptinset.C

index 641f92fa677703fa6682892c8dd878440a098d83..b2adf9411f59b2f363d72111c95cdba58ed436c4 100644 (file)
@@ -1,5 +1,7 @@
 2002-10-28  Dekel Tsur  <dekelts@tau.ac.il>
 
+       * math_scriptinset.C (dispatch): Change handling of LFUN_MATH_LIMITS.
+
        * math_symbolinset.C (metrics): Compute em with the default font.
 
        * math_charinset.C (draw): Use math symbol fonts for <,> & =
index e84ddc22a647c4592556308fd9fd4e7e57685624..ebd2dab51e92ffc47e6681d4c0162f3d8ffd4100 100644 (file)
@@ -491,7 +491,17 @@ MathInset::result_type MathScriptInset::dispatch
        (FuncRequest const & cmd, idx_type & idx, pos_type & pos)
 {
        if (cmd.action == LFUN_MATH_LIMITS) {
-               limits_ = limits_ < 0 ? 1 : -1;
+               if (!cmd.argument.empty()) {
+                       if (cmd.argument == "limits")
+                               limits_ = 1;
+                       else if (cmd.argument == "nolimits")
+                               limits_ = -1;
+                       else
+                               limits_ = 0;
+               } else if (limits_ == 0)
+                       limits_ =  (hasLimits()) ? -1 : 1;
+               else
+                       limits_ = 0;
                return DISPATCHED;
        }