}
-Tabular::idx_type Tabular::setMultiColumn(idx_type cell, idx_type number)
+Tabular::idx_type Tabular::setMultiColumn(idx_type cell, idx_type number,
+ bool const right_border)
{
idx_type const col = cellColumn(cell);
idx_type const row = cellRow(cell);
if (column_info[col].alignment != LYX_ALIGN_DECIMAL)
cs.alignment = column_info[col].alignment;
if (col > 0)
- setRightLine(cell, rightLine(cellIndex(row, col - 1)));
+ setRightLine(cell, right_border);
for (idx_type i = 1; i < number; ++i) {
CellData & cs1 = cellInfo(cell + i);
{
idx_type i = getFirstCellInRow(row);
if (what) {
- setMultiColumn(i, numberOfCellsInRow(row));
+ setMultiColumn(i, numberOfCellsInRow(row), false);
setTopLine(i, false);
setBottomLine(i, false);
setLeftLine(i, false);
// just multicol for one single cell
// check whether we are completely in a multicol
if (!tabular.isMultiColumn(cur.idx()))
- tabular.setMultiColumn(cur.idx(), 1);
+ tabular.setMultiColumn(cur.idx(), 1,
+ tabular.rightLine(cur.idx()));
break;
}
// we have a selection so this means we just add all this
idx_type const s_start = cur.selBegin().idx();
row_type const col_start = tabular.cellColumn(s_start);
row_type const col_end = tabular.cellColumn(cur.selEnd().idx());
- cur.idx() = tabular.setMultiColumn(s_start, col_end - col_start + 1);
+ cur.idx() = tabular.setMultiColumn(s_start, col_end - col_start + 1,
+ tabular.rightLine(cur.selEnd().idx()));
cur.pit() = 0;
cur.pos() = 0;
cur.setSelection(false);
///
bool isMultiColumn(idx_type cell) const;
///
- idx_type setMultiColumn(idx_type cell, idx_type number);
+ idx_type setMultiColumn(idx_type cell, idx_type number,
+ bool const right_border);
///
void unsetMultiColumn(idx_type cell);
///