]> git.lyx.org Git - features.git/commitdiff
InsetTabular.cpp: fix the logic when \linebreaks are allowed in table cells, fixes...
authorUwe Stöhr <uwestoehr@web.de>
Sun, 25 May 2008 21:14:36 +0000 (21:14 +0000)
committerUwe Stöhr <uwestoehr@web.de>
Sun, 25 May 2008 21:14:36 +0000 (21:14 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24938 a592a061-630c-0410-9148-cb99ea01b6c8

src/insets/InsetTabular.cpp

index aa7b83c063d0af212c879d7bb501712b12ab9f21..e49c2a7a6d420999ddfcb0a69b42b1f97a4c51dd 100644 (file)
@@ -1568,10 +1568,12 @@ void Tabular::setUsebox(idx_type cell, BoxType type)
 }
 
 
+// FIXME: Remove this routine because we cannot insert \parboxes when the user
+// adds line breaks, see bug 4886.
 Tabular::BoxType Tabular::getUsebox(idx_type cell) const
 {
-       if (column_info[cellColumn(cell)].p_width.zero() &&
-               !(isMultiColumn(cell) && !cellInfo(cell).p_width.zero()))
+       if ((!column_info[cellColumn(cell)].p_width.zero() && !isMultiColumn(cell)) ||
+               (isMultiColumn(cell) && !cellInfo(cell).p_width.zero()))
                return BOX_NONE;
        if (cellInfo(cell).usebox > 1)
                return cellInfo(cell).usebox;