forked from qt-creator/qt-creator
Python: Tr fixes
Add missing colons, quotes and full stops, and don't use book style capitalization for labels. Change-Id: If338922c7221eac498612ad5a152f24cd921e884 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
This commit is contained in:
@@ -845,7 +845,7 @@ void InterpreterAspect::addToLayout(LayoutItem &builder)
|
|||||||
Core::ICore::showOptionsDialog(m_settingsDialogId);
|
Core::ICore::showOptionsDialog(m_settingsDialogId);
|
||||||
});
|
});
|
||||||
|
|
||||||
builder.addItems({Tr::tr("Interpreter"), m_comboBox.data(), manageButton});
|
builder.addItems({Tr::tr("Interpreter:"), m_comboBox.data(), manageButton});
|
||||||
}
|
}
|
||||||
|
|
||||||
void InterpreterAspect::updateCurrentInterpreter()
|
void InterpreterAspect::updateCurrentInterpreter()
|
||||||
|
@@ -92,8 +92,9 @@ void PipInstallTask::handleDone()
|
|||||||
m_future.reportFinished();
|
m_future.reportFinished();
|
||||||
const bool success = m_process.result() == ProcessResult::FinishedWithSuccess;
|
const bool success = m_process.result() == ProcessResult::FinishedWithSuccess;
|
||||||
if (!success) {
|
if (!success) {
|
||||||
Core::MessageManager::writeFlashing(Tr::tr("Installing %1 failed with exit code %2")
|
Core::MessageManager::writeFlashing(Tr::tr("Installing \"%1\" failed with exit code %2.")
|
||||||
.arg(packagesDisplayName()).arg(m_process.exitCode()));
|
.arg(packagesDisplayName())
|
||||||
|
.arg(m_process.exitCode()));
|
||||||
}
|
}
|
||||||
emit finished(success);
|
emit finished(success);
|
||||||
}
|
}
|
||||||
|
@@ -811,12 +811,12 @@ void PythonSettings::createVirtualEnvironmentInteractive(
|
|||||||
if (!preselectedId.isEmpty() && interpreter.id == preselectedId)
|
if (!preselectedId.isEmpty() && interpreter.id == preselectedId)
|
||||||
interpreters->setCurrentIndex(interpreters->count() - 1);
|
interpreters->setCurrentIndex(interpreters->count() - 1);
|
||||||
}
|
}
|
||||||
layout->addRow(Tr::tr("Python Interpreter"), interpreters);
|
layout->addRow(Tr::tr("Python interpreter:"), interpreters);
|
||||||
auto pathChooser = new PathChooser();
|
auto pathChooser = new PathChooser();
|
||||||
pathChooser->setInitialBrowsePathBackup(startDirectory);
|
pathChooser->setInitialBrowsePathBackup(startDirectory);
|
||||||
pathChooser->setExpectedKind(PathChooser::Directory);
|
pathChooser->setExpectedKind(PathChooser::Directory);
|
||||||
pathChooser->setPromptDialogTitle(Tr::tr("New Python Virtual Environment Directory"));
|
pathChooser->setPromptDialogTitle(Tr::tr("New Python Virtual Environment Directory"));
|
||||||
layout->addRow(Tr::tr("Virtual Environment Directory"), pathChooser);
|
layout->addRow(Tr::tr("Virtual environment directory:"), pathChooser);
|
||||||
auto buttons = new QDialogButtonBox(QDialogButtonBox::Cancel);
|
auto buttons = new QDialogButtonBox(QDialogButtonBox::Cancel);
|
||||||
auto createButton = buttons->addButton(Tr::tr("Create"), QDialogButtonBox::AcceptRole);
|
auto createButton = buttons->addButton(Tr::tr("Create"), QDialogButtonBox::AcceptRole);
|
||||||
createButton->setEnabled(false);
|
createButton->setEnabled(false);
|
||||||
|
@@ -65,7 +65,7 @@ bool PythonWizardPageFactory::validateData(Id typeId, const QVariant &data, QStr
|
|||||||
if (items.isEmpty()) {
|
if (items.isEmpty()) {
|
||||||
if (errorMessage) {
|
if (errorMessage) {
|
||||||
*errorMessage = Tr::tr("'data' of a Python wizard page expects a map with 'items' "
|
*errorMessage = Tr::tr("'data' of a Python wizard page expects a map with 'items' "
|
||||||
"containing a list of objects");
|
"containing a list of objects.");
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -92,16 +92,16 @@ PythonWizardPage::PythonWizardPage(const QList<QPair<QString, QVariant>> &pySide
|
|||||||
this,
|
this,
|
||||||
&PythonWizardPage::updateInterpreters);
|
&PythonWizardPage::updateInterpreters);
|
||||||
|
|
||||||
m_pySideVersion.setLabelText(Tr::tr("PySide version"));
|
m_pySideVersion.setLabelText(Tr::tr("PySide version:"));
|
||||||
m_pySideVersion.setDisplayStyle(SelectionAspect::DisplayStyle::ComboBox);
|
m_pySideVersion.setDisplayStyle(SelectionAspect::DisplayStyle::ComboBox);
|
||||||
for (auto [name, data] : pySideAndData)
|
for (auto [name, data] : pySideAndData)
|
||||||
m_pySideVersion.addOption(SelectionAspect::Option(name, {}, data));
|
m_pySideVersion.addOption(SelectionAspect::Option(name, {}, data));
|
||||||
if (defaultPyside >= 0)
|
if (defaultPyside >= 0)
|
||||||
m_pySideVersion.setDefaultValue(defaultPyside);
|
m_pySideVersion.setDefaultValue(defaultPyside);
|
||||||
|
|
||||||
m_createVenv.setLabelText(Tr::tr("Create new Virtual Environment"));
|
m_createVenv.setLabelText(Tr::tr("Create new virtual environment"));
|
||||||
|
|
||||||
m_venvPath.setLabelText(Tr::tr("Path to virtual environment"));
|
m_venvPath.setLabelText(Tr::tr("Path to virtual environment:"));
|
||||||
m_venvPath.setEnabler(&m_createVenv);
|
m_venvPath.setEnabler(&m_createVenv);
|
||||||
m_venvPath.setExpectedKind(PathChooser::Directory);
|
m_venvPath.setExpectedKind(PathChooser::Directory);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user