49b08f96e8
Many (most?) strings written aren't in fact UTF-8, and we can check at compile-time which are and which aren't, so don't hard-code fromUtf8() but use the much more efficient QStringLiteral() where applicable. This is low-hanging fruit. This patch only optimises US-ASCII string literals, not those that are latin-1 or even UTF-8, because that would require more extensive changes to the original fixString() function. Likewise, there are also other calls to QString::fromUtf8() being generated (e.g. in the pixmap code) that could benefit from being turned into QStringLiterals, but their code paths are more involved than those this patch fixes. This patch at least suffices in turning all the setObjectName() arguments into QStringLiterals, which was the main goal. The autotest baseline has been updated with the new expected results. Change-Id: Ic1ef67f500f9ff92d36164d515f4e004ef2a10bc Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
82 lines
2.3 KiB
C++
82 lines
2.3 KiB
C++
/********************************************************************************
|
|
** Form generated from reading UI file 'Widget.ui'
|
|
**
|
|
** Created: Fri Sep 4 10:17:15 2009
|
|
** by: Qt User Interface Compiler version 4.6.0
|
|
**
|
|
** WARNING! All changes made in this file will be lost when recompiling UI file!
|
|
********************************************************************************/
|
|
|
|
#ifndef WIDGET_H
|
|
#define WIDGET_H
|
|
|
|
#include <QtCore/QVariant>
|
|
#include <QtWidgets/QAction>
|
|
#include <QtWidgets/QApplication>
|
|
#include <QtWidgets/QButtonGroup>
|
|
#include <QtWidgets/QGroupBox>
|
|
#include <QtWidgets/QHeaderView>
|
|
#include <QtWidgets/QLabel>
|
|
#include <QtWidgets/QPushButton>
|
|
#include <QtWidgets/QVBoxLayout>
|
|
#include <QtWidgets/QWidget>
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
|
|
class Ui_Form
|
|
{
|
|
public:
|
|
QVBoxLayout *vboxLayout;
|
|
QLabel *Alabel;
|
|
QGroupBox *groupBox;
|
|
QPushButton *pushButton;
|
|
|
|
void setupUi(QWidget *Form)
|
|
{
|
|
if (Form->objectName().isEmpty())
|
|
Form->setObjectName(QStringLiteral("Form"));
|
|
Form->resize(400, 300);
|
|
vboxLayout = new QVBoxLayout(Form);
|
|
vboxLayout->setObjectName(QStringLiteral("vboxLayout"));
|
|
Alabel = new QLabel(Form);
|
|
Alabel->setObjectName(QStringLiteral("Alabel"));
|
|
|
|
vboxLayout->addWidget(Alabel);
|
|
|
|
groupBox = new QGroupBox(Form);
|
|
groupBox->setObjectName(QStringLiteral("groupBox"));
|
|
|
|
vboxLayout->addWidget(groupBox);
|
|
|
|
pushButton = new QPushButton(Form);
|
|
pushButton->setObjectName(QStringLiteral("pushButton"));
|
|
|
|
vboxLayout->addWidget(pushButton);
|
|
|
|
|
|
retranslateUi(Form);
|
|
|
|
QMetaObject::connectSlotsByName(Form);
|
|
} // setupUi
|
|
|
|
void retranslateUi(QWidget *Form)
|
|
{
|
|
Form->setWindowTitle(QApplication::translate("Form", "Form", 0, QApplication::UnicodeUTF8));
|
|
Alabel->setText(QApplication::translate("Form", "A label.\n"
|
|
"One new line.\n"
|
|
"Another new line.\n"
|
|
"Last line.", 0, QApplication::UnicodeUTF8));
|
|
groupBox->setTitle(QApplication::translate("Form", "A Group Box", 0, QApplication::UnicodeUTF8));
|
|
pushButton->setText(QApplication::translate("Form", "PushButton", 0, QApplication::UnicodeUTF8));
|
|
} // retranslateUi
|
|
|
|
};
|
|
|
|
namespace Ui {
|
|
class Form: public Ui_Form {};
|
|
} // namespace Ui
|
|
|
|
QT_END_NAMESPACE
|
|
|
|
#endif // WIDGET_H
|