Fix missed strings for UI consistency

Fix ellipsis rendering
This commit is contained in:
Max Wilfinger
2025-08-08 09:39:11 +02:00
committed by Chris Hennes
parent 2eeff96e99
commit 1850c5dc0f
41 changed files with 117 additions and 118 deletions

View File

@@ -996,7 +996,7 @@ LabelButton::LabelButton (QWidget * parent)
label->setAutoFillBackground(true);
layout->addWidget(label);
button = new QPushButton(QLatin1String(""), this);
button = new QPushButton(QStringLiteral(""), this);
#if defined (Q_OS_MACOS)
button->setAttribute(Qt::WA_LayoutUsesWidgetRect); // layout size from QMacStyle was not correct
#endif
@@ -1384,7 +1384,7 @@ LabelEditor::LabelEditor (QWidget * parent)
connect(lineEdit, &QLineEdit::textChanged,
this, &LabelEditor::validateText);
button = new QPushButton(QLatin1String(""), this);
button = new QPushButton(QStringLiteral(""), this);
#if defined (Q_OS_MACOS)
button->setAttribute(Qt::WA_LayoutUsesWidgetRect); // layout size from QMacStyle was not correct
#endif
@@ -1460,7 +1460,7 @@ void LabelEditor::setButtonText(const QString& txt)
{
button->setText(txt);
int w1 = 2 * QtTools::horizontalAdvance(button->fontMetrics(), txt);
int w2 = 2 * QtTools::horizontalAdvance(button->fontMetrics(), QLatin1String(""));
int w2 = 2 * QtTools::horizontalAdvance(button->fontMetrics(), QStringLiteral(""));
button->setFixedWidth((w1 > w2 ? w1 : w2));
}