]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetTabular.cpp
* src/insets/InsetTabular.h:
[lyx.git] / src / insets / InsetTabular.cpp
index e14c5562d877387a40f3115d0821b3d48cee1404..4b2ac51268fecf70a99de622f6216b8089d18afd 100644 (file)
@@ -760,6 +760,7 @@ void Tabular::updateIndexes()
                                continue;
                        rowofcell[i] = row;
                        columnofcell[i] = column;
+                       setFixedWidth(row, column);
                        ++i;
                }
 }
@@ -994,6 +995,18 @@ void Tabular::setColumnPWidth(Cursor & cur, idx_type cell,
 }
 
 
+bool Tabular::setFixedWidth(row_type r, col_type c)
+{
+       if (!column_info[c].p_width.zero() ||
+                               (cell_info[r][c].multicolumn != CELL_NORMAL && 
+                               !cell_info[r][c].p_width.zero())) {
+               cell_info[r][c].inset->toggleFixedWidth(true);
+               return true;
+       }
+       return false;
+}
+
+
 bool Tabular::setMColumnPWidth(Cursor & cur, idx_type cell,
                Length const & width)
 {
@@ -1404,6 +1417,7 @@ void Tabular::read(Lexer & lex)
                        getTokenValue(line, "rotate", cell_info[i][j].rotate);
                        getTokenValue(line, "usebox", cell_info[i][j].usebox);
                        getTokenValue(line, "width", cell_info[i][j].p_width);
+                       setFixedWidth(i,j);
                        getTokenValue(line, "special", cell_info[i][j].align_special);
                        l_getline(is, line);
                        if (prefixIs(line, "\\begin_inset")) {