]> git.lyx.org Git - features.git/commitdiff
* InsetTabular.cpp: fix logic of multirow top/bottom line output (bug #7578)
authorJürgen Spitzmüller <spitz@lyx.org>
Fri, 23 Sep 2011 13:07:00 +0000 (13:07 +0000)
committerJürgen Spitzmüller <spitz@lyx.org>
Fri, 23 Sep 2011 13:07:00 +0000 (13:07 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_2_0_X@39734 a592a061-630c-0410-9148-cb99ea01b6c8

src/insets/InsetTabular.cpp
status.20x

index 132a3ee656e6f04c6eb5b0406fa8aeff9deecce2..dc6effe946a1b79fabaf1447c607fc11dd371ef7 100644 (file)
@@ -2057,8 +2057,8 @@ void Tabular::TeXTopHLine(otexstream & os, row_type row, string const lang) cons
                // multirow, no line must be drawn.
                if (row != 0)
                        if (isMultiRow(cellIndex(row, c))
-                               && isMultiRow(cellIndex(row - 1, c)))
-                                       topline[c] = false;
+                           && cell_info[row][c].multirow != CELL_BEGIN_OF_MULTIROW)
+                               topline[c] = false;
                if (topline[c])
                        ++nset;
        }
@@ -2117,13 +2117,14 @@ void Tabular::TeXBottomHLine(otexstream & os, row_type row, string const lang) c
        for (col_type c = 0; c < ncols(); ++c) {
                bottomline.push_back(bottomLine(cellIndex(row, c)));
                topline.push_back(!lastrow && topLine(cellIndex(row + 1, c)));
-               // If cell is part of a multirow and not the last or first cell of the
+               // If cell is part of a multirow and not the last cell of the
                // multirow, no line must be drawn.
                if (!lastrow)
                        if (isMultiRow(cellIndex(row, c))
-                               && isMultiRow(cellIndex(row + 1, c))) {
-                                       bottomline[c] = false;
-                                       topline[c] = false;
+                           && isMultiRow(cellIndex(row + 1, c))
+                           && cell_info[row + 1][c].multirow != CELL_BEGIN_OF_MULTIROW) {
+                               bottomline[c] = false;
+                               topline[c] = false;
                                }
                nextrowset &= topline[c];
        }
index 309440c78ac5713be66f4da8dde3b4a72b278b51..9c4521ef68cbc651174ee6507ba010175182ccbe 100644 (file)
@@ -69,6 +69,8 @@ What's new
 
 * DOCUMENT INPUT/OUTPUT
 
+- Fix output of multirow table cell borders (bug 7578).
+
 - Fix ASCII export for branch inset (bug 7720).
 
 - Fix regression where parent macros were not displayed in a viewed child