LayoutSaver: Fix rounding errors when doing a relative restore

After a restore with relative sizes the items might not be on a pixel
perfect position regarding to their anchors. Make sure they are after
the restore is complete.
This commit is contained in:
Sergio Martins
2020-02-25 23:24:39 +00:00
parent 170f4efbb2
commit ee786f57c5
4 changed files with 26 additions and 5 deletions

View File

@@ -1080,6 +1080,7 @@ void MultiSplitterLayout::positionStaticAnchors()
void MultiSplitterLayout::redistributeSpace()
{
positionStaticAnchors();
redistributeSpace_recursive(m_leftAnchor, 0);
redistributeSpace_recursive(m_topAnchor, 0);
}