diff --git a/lib/appbase/widgets/BaseWindow.cpp b/lib/appbase/widgets/BaseWindow.cpp index 8f77d6585..dc9f9cafb 100644 --- a/lib/appbase/widgets/BaseWindow.cpp +++ b/lib/appbase/widgets/BaseWindow.cpp @@ -521,7 +521,7 @@ void BaseWindow::resizeEvent(QResizeEvent *) getApp()->windows->queueSave(); #endif - this->moveIntoDesktopRect(this); + //this->moveIntoDesktopRect(this); this->calcButtonsSizes(); } diff --git a/src/widgets/dialogs/UserInfoPopup.cpp b/src/widgets/dialogs/UserInfoPopup.cpp index 5d0758faa..86f0eefa1 100644 --- a/src/widgets/dialogs/UserInfoPopup.cpp +++ b/src/widgets/dialogs/UserInfoPopup.cpp @@ -55,8 +55,8 @@ UserInfoPopup::UserInfoPopup() auto app = getApp(); - auto layout = - LayoutCreator(this).setLayoutType(); + auto layout = LayoutCreator(this->getLayoutContainer()) + .setLayoutType(); // first line auto head = layout.emplace().withoutMargin(); @@ -223,26 +223,32 @@ UserInfoPopup::UserInfoPopup() }); } - // this->setStyleSheet("font-size: 11pt;"); - this->installEvents(); + + this->setSizePolicy(QSizePolicy::Ignored, QSizePolicy::Policy::Ignored); } void UserInfoPopup::themeChangedEvent() { BaseWindow::themeChangedEvent(); - this->setStyleSheet( - "background: #333; font-size: " + - QString::number(getFonts() - ->getFont(FontStyle::UiMediumBold, this->scale()) - .pixelSize()) + - "px;"); + for (auto &&child : this->findChildren()) + { + child->setFont(getFonts()->getFont(FontStyle::UiMedium, this->scale())); + } } void UserInfoPopup::scaleChangedEvent(float /*scale*/) { themeChangedEvent(); + + QTimer::singleShot(20, this, [this] { + auto geo = this->geometry(); + geo.setWidth(10); + geo.setHeight(10); + + this->setGeometry(geo); + }); } void UserInfoPopup::installEvents()