}
if (r + 1 < tabular.nrows())
- y += tabular.rowDescent(r) + tabular.rowAscent(r + 1)
- + tabular.interRowSpace(r + 1);
+ y += tabular.rowDescent(r) + tabular.rowAscent(r + 1)
+ + tabular.interRowSpace(r + 1);
}
}
tabular.cellRow(cur.idx()), tabular.cellColumn(cur.idx()));
if (cur.selIsMultiCell() || full_cell_selected) {
- y -= tabular.rowAscent(0);
for (row_type r = 0; r < tabular.nrows(); ++r) {
int xx = x;
for (col_type c = 0; c < tabular.ncols(); ++c) {
}
int const w = tabular.columnWidth(cell);
int const h = tabular.rowHeight(cell);
+ int const yy = y - tabular.rowAscent(r);
if (isCellSelected(cur, r, c))
- pi.pain.fillRectangle(xx, y, w, h, Color_selection);
+ pi.pain.fillRectangle(xx, yy, w, h, Color_selection);
xx += w;
}
if (r + 1 < tabular.nrows())
- y += tabular.rowDescent(r) + tabular.rowAscent(r)
+ y += tabular.rowDescent(r) + tabular.rowAscent(r + 1)
+ tabular.interRowSpace(r + 1);
}
int const col = tabular.cellColumn(sl.idx());
// y offset correction
- for (int r = 0; r < row; ++r) {
- y += tabular.rowAscent(r + 1) + tabular.rowDescent(r)
+ for (int r = 0; r < row; ++r)
+ y += tabular.rowDescent(r) + tabular.rowAscent(r + 1)
+ tabular.interRowSpace(r + 1);
- }
+
y += tabular.textVOffset(sl.idx());
// x offset correction