2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-01 15:05:56 +00:00

Use QFontMetrics::height in PreLaunchWindow

This commit is contained in:
Ilya Fedin
2021-12-07 17:20:04 +04:00
committed by John Preston
parent 7ff7473db6
commit fedd21b0a6

View File

@@ -43,9 +43,7 @@ PreLaunchWindow::PreLaunchWindow(QString title) {
p.setColor(QPalette::Window, QColor(255, 255, 255)); p.setColor(QPalette::Window, QColor(255, 255, 255));
setPalette(p); setPalette(p);
QLabel tmp(this); _size = QFontMetrics(QGuiApplication::font()).height();
tmp.setText(qsl("Tmp"));
_size = tmp.sizeHint().height();
int paddingVertical = (_size / 2); int paddingVertical = (_size / 2);
int paddingHorizontal = _size; int paddingHorizontal = _size;