From 96eac2ca3fdd7e6b428f74c33d6c587828813868 Mon Sep 17 00:00:00 2001 From: Vincent van Ravesteijn Date: Mon, 9 Feb 2009 09:02:50 +0000 Subject: [PATCH] Fix bug 5750: http://bugzilla.lyx.org/show_bug.cgi?id=5750. Wrong width display of multicolumn cells. When changing a custom width cell into a multicolumn, the isFixedWidth bool should be set to false. Now, the function setFixedWidth could only set isFixedWidth to true when needed. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28407 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/insets/InsetTabular.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp index e644b90fc8..fdd4d3685b 100644 --- a/src/insets/InsetTabular.cpp +++ b/src/insets/InsetTabular.cpp @@ -1022,12 +1022,10 @@ void Tabular::setColumnPWidth(Cursor & cur, idx_type cell, bool Tabular::setFixedWidth(row_type r, col_type c) { bool const multicol = cell_info[r][c].multicolumn != CELL_NORMAL; - if ((!column_info[c].p_width.zero() && !multicol) - || (multicol && !cell_info[r][c].p_width.zero())) { - cell_info[r][c].inset->toggleFixedWidth(true); - return true; - } - return false; + bool const fixed_width = (!column_info[c].p_width.zero() && !multicol) + || (multicol && !cell_info[r][c].p_width.zero()); + cell_info[r][c].inset->toggleFixedWidth(fixed_width); + return fixed_width; } -- 2.39.2