mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
do not use cells without decimals when calculating column widths and cell text offsets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34645 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
e6ab2b0442
commit
b031ac1e66
@ -962,7 +962,8 @@ bool Tabular::updateColumnWidths()
|
||||
for(row_type r = 0; r < nrows(); ++r) {
|
||||
idx_type const i = cellIndex(r, c);
|
||||
if (columnSpan(i) == 1) {
|
||||
if (getAlignment(i) == LYX_ALIGN_DECIMAL)
|
||||
if (getAlignment(i) == LYX_ALIGN_DECIMAL
|
||||
&& cell_info[r][c].decimal_width!=0)
|
||||
new_width = max(new_width, cellInfo(i).width
|
||||
+ max_dwidth[c] - cellInfo(i).decimal_width);
|
||||
else
|
||||
@ -1271,7 +1272,8 @@ int Tabular::textHOffset(idx_type cell) const
|
||||
int max_dhoffset = 0;
|
||||
for(row_type r = 0; r < row_info.size() ; ++r) {
|
||||
idx_type const i = cellIndex(r, c);
|
||||
if (getAlignment(i) == LYX_ALIGN_DECIMAL)
|
||||
if (getAlignment(i) == LYX_ALIGN_DECIMAL
|
||||
&& cellInfo(i).decimal_width != 0)
|
||||
max_dhoffset = max(max_dhoffset, cellInfo(i).decimal_hoffset);
|
||||
}
|
||||
x += max_dhoffset - cellInfo(cell).decimal_hoffset;
|
||||
|
Loading…
Reference in New Issue
Block a user