]> git.lyx.org Git - features.git/commitdiff
Use only the first label when mutating eqnarray to display formula.
authorDekel Tsur <dekelts@tau.ac.il>
Mon, 9 Jul 2001 16:42:22 +0000 (16:42 +0000)
committerDekel Tsur <dekelts@tau.ac.il>
Mon, 9 Jul 2001 16:42:22 +0000 (16:42 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2211 a592a061-630c-0410-9148-cb99ea01b6c8

src/mathed/ChangeLog
src/mathed/math_matrixinset.C

index 2d5597af55d881307afe9610546a166c052f5c74..8ce2221ac32c8cc3b34be47b61c335408cf835a6 100644 (file)
@@ -1,3 +1,8 @@
+2001-07-09  Dekel Tsur  <dekelts@tau.ac.il>
+
+       * math_matrixinset.C (mutate): Use only the first label when
+       mutating eqnarray to display formula.
+
 2001-07-09  Juergen Vigna  <jug@sad.it>
 
        * formulabase.C (mathDispatchCreation): don't do anything with the
index c185e874e3eea30d32b58a10381256e630695e7c..10c7e0234ed27591225a2e52a80d9ee75b64a637 100644 (file)
@@ -476,13 +476,20 @@ void MathMatrixInset::mutate(short newtype)
                        switch (newtype) {
                                case LM_OT_SIMPLE:
                                case LM_OT_EQUATION: {
-                                       string label;
                                        bool allnonum = true;
                                        for (int r = 0; r < nrows(); ++r) {
-                                               label += label_[r];
                                                if (!nonum_[r])
                                                        allnonum = false;
                                        }
+
+                                       string label;
+                                       for (int r = 0; r < nrows(); ++r) {
+                                               if (!label_[r].empty()) {
+                                                       label = label_[r];
+                                                       break;
+                                               }
+                                       }
+
                                        glueall();
                                        mutate(newtype);
                                        label_[0] = label;