- int cols = 1;
- if (!extractNumber(count, cols)) {
- success_ = false;
- error("can't extract number of multicolumn cells");
- }
- // resize the table if necessary
- size_t first = grid.index(cellrow, cellcol);
- for (int i = 1; i < cols; ++i) {
- if (addCol(grid, cellcol)) {
- size_t const idx = grid.index(cellrow, cellcol);
- grid.cellinfo(idx).multi_ =
- InsetMathGrid::CELL_PART_OF_MULTICOLUMN;
+ int cols;
+ if (extractNumber(count, cols)) {
+ // resize the table if necessary
+ size_t first = grid.index(cellrow, cellcol);
+ for (int i = 1; i < cols; ++i) {
+ if (addCol(grid, cellcol)) {
+ size_t const idx = grid.index(cellrow, cellcol);
+ grid.cellinfo(idx).multi_ =
+ InsetMathGrid::CELL_PART_OF_MULTICOLUMN;
+ }