@@ -412,10 +412,6 @@ void TableGroupItem::layoutTable()
412
412
{
413
413
if (!isEnabled ())
414
414
return ; // Note 20240830: prevent spurious layouts during serialization (see hlg::TableGroup::serializeFromJson()).
415
- // Adapt to a new (width, height), keep previous rows/columns ratio
416
- // New position is:
417
- // x = previousX * (actualWidth / previousWidth)
418
- // y = previousY * (actualHeight / previousHeight)
419
415
const auto tableContainer = getContainer ();
420
416
if (tableContainer == nullptr )
421
417
return ;
@@ -432,12 +428,10 @@ void TableGroupItem::layoutTable()
432
428
qWarning () << " TableGroupItem::layoutTable(): " << getGroup ()->getLabel () <<
433
429
" tableWidth=" << tableWidth << " tableHeight=" << tableHeight;
434
430
431
+ // Project normalized sx/sy coordinates to table item container CS.
435
432
for (const auto verticalBorder: _verticalBorders) {
436
433
if (verticalBorder == nullptr )
437
434
continue ;
438
- // FIXME #1756
439
- // const auto previousX = verticalBorder->x();
440
- // verticalBorder->setX((previousX / _previousSize.width()) * tableWidth);
441
435
verticalBorder->setX (verticalBorder->getSx () * tableWidth);
442
436
verticalBorder->setY (0 .);
443
437
verticalBorder->setHeight (tableHeight);
@@ -447,28 +441,13 @@ void TableGroupItem::layoutTable()
447
441
if (horizontalBorder == nullptr )
448
442
continue ;
449
443
horizontalBorder->setX (0 .);
450
- // FIXME #1756
451
- // const auto previousY = horizontalBorder->y();
452
- // horizontalBorder->setY((previousY / _previousSize.height()) * tableHeight);
453
444
horizontalBorder->setY (horizontalBorder->getSy () * tableHeight);
454
445
horizontalBorder->setWidth (tableWidth);
455
446
}
456
447
457
448
layoutCells ();
458
449
}
459
450
460
- void TableGroupItem::polishTable ()
461
- {
462
- // FIXME #1756 no longer necessary ????
463
-
464
- if (!isEnabled ())
465
- return ; // Note 20240830: prevent spurious layouts during serialization (see hlg::TableGroup::serializeFromJson()).
466
- const auto tableContainer = getContainer ();
467
- if (tableContainer == nullptr )
468
- return ;
469
- layoutCells ();
470
- }
471
-
472
451
void TableGroupItem::layoutCells ()
473
452
{
474
453
// qWarning() << "qan::TableGroupItem::layoutCells()";
0 commit comments