use contentsrect to calculate window size if baseUnit isn't 1,1
BUG: 283518
This commit is contained in:
parent
252c21e903
commit
011643d983
1 changed files with 6 additions and 2 deletions
|
@ -158,8 +158,12 @@ void WindowGeometry::slotWindowStepUserMovedResized(EffectWindow *w, const QRect
|
|||
dy = r.height() - r2.height();
|
||||
|
||||
const QSize baseInc = w->basicUnit();
|
||||
if (baseInc != QSize(1,1)) {
|
||||
Q_ASSERT(baseInc.width() && baseInc.height());
|
||||
myMeasure[1]->setText( i18nc(myResizeString, r.width()/baseInc.width(), r.height()/baseInc.height(), number(dx/baseInc.width()), number(dy/baseInc.height()) ) );
|
||||
const QSize csz = w->contentsRect().size();
|
||||
myMeasure[1]->setText( i18nc(myResizeString, csz.width()/baseInc.width(), csz.height()/baseInc.height(), number(dx/baseInc.width()), number(dy/baseInc.height()) ) );
|
||||
} else
|
||||
myMeasure[1]->setText( i18nc(myResizeString, r.width(), r.height(), number(dx), number(dy) ) );
|
||||
|
||||
// calc width for bottomright element, superfluous otherwise
|
||||
dx = r.right() - r2.right();
|
||||
|
|
Loading…
Reference in a new issue