]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathGrid.cpp
Fix regression of 5261ae6a2
[lyx.git] / src / mathed / InsetMathGrid.cpp
index ac8cd491acb8d50dafc3e132722550a1810fb381..b4619de470a0f3d3baadf6565393e0774a521c7a 100644 (file)
@@ -674,7 +674,7 @@ docstring InsetMathGrid::eolString(row_type row, bool fragile,
        // make sure an upcoming '[' does not break anything
        if (row + 1 < nrows()) {
                MathData const & c = cell(index(row + 1, 0));
-               if (c.size() && c.front()->getChar() == '[')
+               if (!c.empty() && c.front()->getChar() == '[')
                        //eol += "[0pt]";
                        eol += "{}";
        }
@@ -905,7 +905,7 @@ bool InsetMathGrid::idxDelete(idx_type & idx)
 
        // try to delete entire sequence of ncols() empty cells if possible
        for (idx_type i = idx; i < idx + ncols(); ++i)
-               if (cell(i).size())
+               if (!cell(i).empty())
                        return false;
 
        // move cells if necessary
@@ -1343,7 +1343,7 @@ void InsetMathGrid::doDispatch(Cursor & cur, FuncRequest & cmd)
                }
                InsetMathGrid grid(buffer_, 1, 1);
                if (!topaste.empty())
-                       if ((topaste.size() == 1 && topaste.at(0) < 0x80)
+                       if ((topaste.size() == 1 && isAscii(topaste))
                            || !mathed_parse_normal(grid, topaste, parseflg)) {
                                resetGrid(grid);
                                mathed_parse_normal(grid, topaste, parseflg | Parse::VERBATIM);