]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt4/GuiMathMatrix.cpp
Use QMessageBox for toggleWarning if possible
[lyx.git] / src / frontends / qt4 / GuiMathMatrix.cpp
index 8106629d994a045fbb99e9a24503548fb35bc46f..e4e3f8878b04da28fed0d9dd3c01794c08a0e8d9 100644 (file)
@@ -63,6 +63,11 @@ GuiMathMatrix::GuiMathMatrix(GuiView & lv)
 {
        setupUi(this);
 
+       for (int i = 0; *VertAligns[i]; ++i)
+               valignCO->addItem(qt_(VertAligns[i]));
+       for (int i = 0; *DecoChars[i]; ++i)
+               decorationCO->addItem(qt_(DecoChars[i]));
+
        table->setMinimumSize(100, 100);
        rowsSB->setValue(5);
        columnsSB->setValue(5);
@@ -91,11 +96,6 @@ GuiMathMatrix::GuiMathMatrix(GuiView & lv)
        connect(decorationCO, SIGNAL(activated(int)),
                this, SLOT(decorationChanged(int)));
 
-       for (int i = 0; *VertAligns[i]; ++i)
-               valignCO->addItem(qt_(VertAligns[i]));
-       for (int i = 0; *DecoChars[i]; ++i)
-               decorationCO->addItem(qt_(DecoChars[i]));
-
        bc().setPolicy(ButtonPolicy::IgnorantPolicy);
 }
 
@@ -131,7 +131,7 @@ void GuiMathMatrix::slotOK()
        // a matrix without a decoration is an array,
        // otherwise it is an AMS matrix
        // decorated matrices cannot have a vertical alignment
-       
+
        char const c = v_align_c[valignCO->currentIndex()];
        QString const sh = halignED->text();
        string const str = fromqstr(