mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
* InsetTabular.cpp:
- (getLastCellInRow): fix crash when in first multirow row - (TeXRow): do not output row separator in in last row (bug #7294). git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37709 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d76afa404d
commit
2d7cf03935
@ -1342,8 +1342,9 @@ Tabular::idx_type Tabular::getFirstCellInRow(row_type row) const
|
||||
Tabular::idx_type Tabular::getLastCellInRow(row_type row) const
|
||||
{
|
||||
col_type c = ncols() - 1;
|
||||
while (cell_info[row][c].multirow == CELL_PART_OF_MULTIROW
|
||||
|| cell_info[row][c].multicolumn == CELL_PART_OF_MULTICOLUMN)
|
||||
while (c > 0
|
||||
&& (cell_info[row][c].multirow == CELL_PART_OF_MULTIROW
|
||||
|| cell_info[row][c].multicolumn == CELL_PART_OF_MULTICOLUMN))
|
||||
--c;
|
||||
return cell_info[row][c].cellno;
|
||||
}
|
||||
@ -2442,13 +2443,15 @@ void Tabular::TeXRow(otexstream & os, row_type row,
|
||||
if (isPartOfMultiColumn(row, c))
|
||||
continue;
|
||||
|
||||
if (isPartOfMultiRow(row, c) &&
|
||||
column_info[c].alignment != LYX_ALIGN_DECIMAL) {
|
||||
cell = cellIndex(row, c);
|
||||
|
||||
if (isPartOfMultiRow(row, c)
|
||||
&& column_info[c].alignment != LYX_ALIGN_DECIMAL) {
|
||||
if (cell != getLastCellInRow(row))
|
||||
os << " & ";
|
||||
continue;
|
||||
}
|
||||
|
||||
cell = cellIndex(row, c);
|
||||
TeXCellPreamble(os, cell, ismulticol, ismultirow);
|
||||
shared_ptr<InsetTableCell> inset = cellInset(cell);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user