Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NOISSUE Fix strings #4477

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion launcher/InstanceImportTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ void InstanceImportTask::processFlame()
}
catch (const JSONValidationError &e)
{
emitFailed(tr("Could not understand pack manifest:\n") + e.cause());
emitFailed(tr("Could not parse the pack manifest:\n") + e.cause());
return;
}
if(!pack.overrides.isEmpty())
Expand Down
4 changes: 2 additions & 2 deletions launcher/JavaCommon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ bool JavaCommon::checkJVMArgs(QString jvmargs, QWidget *parent)
|| jvmargs.contains("-XX-MaxHeapSize") || jvmargs.contains("-XX:InitialHeapSize"))
{
auto warnStr = QObject::tr(
"You tried to manually set a JVM memory option (using \"-XX:PermSize\", \"-XX-MaxHeapSize\", \"-XX:InitialHeapSize\", \"-Xmx\" or \"-Xms\").\n"
"An attempt was made to manually set a JVM memory option (using \"-XX:PermSize\", \"-XX-MaxHeapSize\", \"-XX:InitialHeapSize\", \"-Xmx\" or \"-Xms\").\n"
"There are dedicated boxes for these in the settings (Java tab, in the Memory group at the top).\n"
"This message will be displayed until you remove them from the JVM arguments.");
"This message will be displayed until these arguments are removed from the JVM arguments.");
CustomMessageBox::selectable(
parent, QObject::tr("JVM arguments warning"),
warnStr,
Expand Down
21 changes: 10 additions & 11 deletions launcher/LaunchController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,8 @@ void LaunchController::decideAccount()
auto reply = CustomMessageBox::selectable(
m_parentWidget,
tr("No Accounts"),
tr("In order to play Minecraft, you must have at least one Mojang or Minecraft "
"account logged in."
"Would you like to open the account manager to add an account now?"),
tr("In order to play Minecraft, logging in to at least one Mojang or Microsoft account is required. "
"Open the account manager to add an account?"),
QMessageBox::Information,
QMessageBox::Yes | QMessageBox::No
)->exec();
Expand All @@ -74,7 +73,7 @@ void LaunchController::decideAccount()
{
// If no default account is set, ask the user which one to use.
ProfileSelectDialog selectDialog(
tr("Which account would you like to use?"),
tr("Select the account that should be used"),
ProfileSelectDialog::GlobalDefaultCheckbox,
m_parentWidget
);
Expand Down Expand Up @@ -107,7 +106,7 @@ void LaunchController::login() {
// we loop until the user succeeds in logging in or gives up
bool tryagain = true;
// the failure. the default failure.
const QString needLoginAgain = tr("Your account is currently not logged in. Please enter your password to log in again. <br /> <br /> This could be caused by a password change.");
const QString needLoginAgain = tr("Not currently logged in. Please enter the password to log in again.<br /><br />This could be caused by a password change.");
QString failReason = needLoginAgain;

while (tryagain)
Expand All @@ -129,7 +128,7 @@ void LaunchController::login() {
QString name = QInputDialog::getText(
m_parentWidget,
tr("Player name"),
tr("Choose your offline mode player name."),
tr("Choose an offline mode player name."),
QLineEdit::Normal,
m_session->player_name,
&ok
Expand Down Expand Up @@ -169,7 +168,7 @@ void LaunchController::login() {
// play demo ?
QMessageBox box(m_parentWidget);
box.setWindowTitle(tr("Play demo?"));
box.setText(tr("This account does not own Minecraft.\nYou need to purchase the game first to play it.\n\nDo you want to play the demo?"));
box.setText(tr("This account does not own Minecraft.\nPurchasing the game is required to play the full version.\n\nDo you want to play the demo?"));
box.setIcon(QMessageBox::Warning);
auto demoButton = box.addButton(tr("Play Demo"), QMessageBox::ButtonRole::YesRole);
auto cancelButton = box.addButton(tr("Cancel"), QMessageBox::ButtonRole::NoRole);
Expand Down Expand Up @@ -327,8 +326,8 @@ void LaunchController::readyForLaunch()
connect(profilerInstance, &BaseProfiler::readyToLaunch, [this](const QString & message)
{
QMessageBox msg;
msg.setText(tr("The game launch is delayed until you press the "
"button. This is the right time to setup the profiler, as the "
msg.setText(tr("The game launch is delayed until the button is pressed. "
"This is the right time to setup the profiler, as the "
"profiler server is running now.\n\n%1").arg(message));
msg.setWindowTitle(tr("Waiting."));
msg.setIcon(QMessageBox::Information);
Expand Down Expand Up @@ -386,8 +385,8 @@ bool LaunchController::abort()
}
auto response = CustomMessageBox::selectable(
m_parentWidget, tr("Kill Minecraft?"),
tr("This can cause the instance to get corrupted and should only be used if Minecraft "
"is frozen for some reason"),
tr("This can cause the instance to get corrupted and should only be done if Minecraft "
"is not responding"),
QMessageBox::Question, QMessageBox::Yes | QMessageBox::No, QMessageBox::Yes)->exec();
if (response == QMessageBox::Yes)
{
Expand Down
2 changes: 1 addition & 1 deletion launcher/UpdateController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,7 @@ void UpdateController::fail()
if(!rollbackOK)
{
msg = QObject::tr("The rollback failed too.\n"
"You will have to repair %1 manually.\n"
"%1 will have to be repaired manually.\n"
"Please let us know why and how this happened.").arg(BuildConfig.LAUNCHER_NAME);
QMessageBox::critical(m_parent, rollFailTitle, msg);
qApp->quit();
Expand Down
2 changes: 1 addition & 1 deletion launcher/minecraft/auth/AccountList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ QVariant AccountList::data(const QModelIndex &index, int role) const
return tr("Working", "Account status");
}
case AccountState::Errored: {
return tr("Errored", "Account status");
return tr("Error", "Account status");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the past tense here is intentional as the account has errored

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Errored" is not a word that exists in formal language. You have to remember, these words have to be translated into other languages, if words are made up, the translators have to make up their own words as well, which often make even less sense than in the original. The correct form would be "Encountered an error", but there is very little space in the UI to fit such a long string.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

errored is very much a real adjective https://en.wiktionary.org/wiki/errored
now you can argue all you want about formal language, but I think that ship has sailed a long time ago in terms of real world usage and at least in German, errored translates perfectly to the adjective fehlerhaft

The correct form would be "Encountered an error"

I too read this https://english.stackexchange.com/questions/3059/is-errored-correct-usage

}
case AccountState::Expired: {
return tr("Expired", "Account status");
Expand Down
10 changes: 5 additions & 5 deletions launcher/minecraft/auth/steps/XboxAuthorizationStep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -124,31 +124,31 @@ bool XboxAuthorizationStep::processSTSError(
case 2148916233:{
emit finished(
AccountTaskState::STATE_FAILED_SOFT,
tr("This Microsoft account does not have an XBox Live profile. Buy the game on %1 first.")
.arg("<a href=\"https://www.minecraft.net/en-us/store/minecraft-java-edition\">minecraft.net</a>")
tr("This Microsoft account does not have an Xbox Live profile. Purchasing the game on %1 is required.")
.arg(tr("<a href=\"https://www.minecraft.net/en-us/store/minecraft-java-edition\">minecraft.net</a>"))
);
return true;
}
case 2148916235: {
// NOTE: this is the Grulovia error
emit finished(
AccountTaskState::STATE_FAILED_SOFT,
tr("XBox Live is not available in your country. You've been blocked.")
tr("Xbox Live is not available in this country. The provided account has been blocked by Microsoft.")
);
return true;
}
case 2148916238: {
emit finished(
AccountTaskState::STATE_FAILED_SOFT,
tr("This Microsoft account is underaged and is not linked to a family.\n\nPlease set up your account according to %1.")
tr("This is not an adult Microsoft account and it is not linked to a family.\n\nPlease set up the account according to %1.")
.arg("<a href=\"https://help.minecraft.net/hc/en-us/articles/4403181904525\">help.minecraft.net</a>")
);
return true;
}
default: {
emit finished(
AccountTaskState::STATE_FAILED_SOFT,
tr("XSTS authentication ended with unrecognized error(s):\n\n%1").arg(errorCode)
tr("XSTS authentication ended with an unrecognized error code:\n\n%1").arg(errorCode)
);
return true;
}
Expand Down
4 changes: 2 additions & 2 deletions launcher/minecraft/auth/steps/XboxUserStep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@ void XboxUserStep::onRequestDone(

if (error != QNetworkReply::NoError) {
qWarning() << "Reply error:" << error;
emit finished(AccountTaskState::STATE_FAILED_SOFT, tr("XBox user authentication failed."));
emit finished(AccountTaskState::STATE_FAILED_SOFT, tr("Xbox user authentication failed."));
return;
}

Katabasis::Token temp;
if(!Parsers::parseXTokenResponse(data, temp, "UToken")) {
qWarning() << "Could not parse user authentication response...";
emit finished(AccountTaskState::STATE_FAILED_SOFT, tr("XBox user authentication response could not be understood."));
emit finished(AccountTaskState::STATE_FAILED_SOFT, tr("Unexpected Xbox user authentication response."));
return;
}
m_data->userToken = temp;
Expand Down
2 changes: 1 addition & 1 deletion launcher/minecraft/launch/DirectJavaLaunch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ void DirectJavaLaunch::on_state(LoggedProcess::State state)
case LoggedProcess::FailedToStart:
{
//: Error message displayed if instance can't start
const char *reason = QT_TR_NOOP("Could not launch minecraft!");
const char *reason = QT_TR_NOOP("Could not launch Minecraft!");
emit logLine(reason, MessageLevel::Fatal);
emitFailed(tr(reason));
return;
Expand Down
8 changes: 4 additions & 4 deletions launcher/minecraft/launch/VerifyJavaInstall.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,18 @@ void VerifyJavaInstall::executeTask() {
// Java 16 requirement
else if (minecraftComponent->getReleaseDateTime() >= g_VersionFilterData.java16BeginsDate) {
if (javaVersion.major() < 16) {
emit logLine("Minecraft 21w19a and above require the use of Java 16",
emit logLine("Minecraft 21w19a (1.17) and above require the use of Java 16",
MessageLevel::Fatal);
emitFailed(tr("Minecraft 21w19a and above require the use of Java 16"));
emitFailed(tr("Minecraft 21w19a (1.17) and above require the use of Java 16"));
return;
}
}
// Java 8 requirement
else if (minecraftComponent->getReleaseDateTime() >= g_VersionFilterData.java8BeginsDate) {
if (javaVersion.major() < 8) {
emit logLine("Minecraft 17w13a and above require the use of Java 8",
emit logLine("Minecraft 17w13a (1.12) and above require the use of Java 8",
MessageLevel::Fatal);
emitFailed(tr("Minecraft 17w13a and above require the use of Java 8"));
emitFailed(tr("Minecraft 17w13a (1.12) and above require the use of Java 8"));
return;
}
}
Expand Down
2 changes: 1 addition & 1 deletion launcher/minecraft/update/FMLLibrariesTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ void FMLLibrariesTask::fmllibsFailed(QString reason)
{
QStringList failed = downloadJob->getFailedFiles();
QString failed_all = failed.join("\n");
emitFailed(tr("Failed to download the following files:\n%1\n\nReason:%2\nPlease try again.").arg(failed_all, reason));
emitFailed(tr("Failed to download the following files:\n%1\n\nReason: %2\nPlease try again.").arg(failed_all, reason));
}

bool FMLLibrariesTask::abort()
Expand Down
4 changes: 2 additions & 2 deletions launcher/modplatform/atlauncher/ATLPackInstallTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ void PackInstallTask::onDownloadSucceeded()
}
catch (const JSONValidationError &e)
{
emitFailed(tr("Could not understand pack manifest:\n") + e.cause());
emitFailed(tr("Could not parse the pack manifest:\n") + e.cause());
return;
}
m_version = version;
Expand Down Expand Up @@ -471,7 +471,7 @@ void PackInstallTask::extractConfigs()
QuaZip packZip(archivePath);
if(!packZip.open(QuaZip::mdUnzip))
{
emitFailed(tr("Failed to open pack configs %1!").arg(archivePath));
emitFailed(tr("Failed to open the pack configs archive in %1").arg(archivePath));
return;
}

Expand Down
2 changes: 1 addition & 1 deletion launcher/modplatform/modpacksch/FTBPackInstallTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ void PackInstallTask::onDownloadSucceeded()
}
catch (const JSONValidationError &e)
{
emitFailed(tr("Could not understand pack manifest:\n") + e.cause());
emitFailed(tr("Could not parse the pack manifest:\n") + e.cause());
return;
}
m_version = version;
Expand Down
9 changes: 5 additions & 4 deletions launcher/modplatform/technic/TechnicPackProcessor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ void Technic::TechnicPackProcessor::run(SettingsObjectPtr globalSettings, const
else
{
if (minecraftVersion.isEmpty())
emit failed(tr("Could not find \"version.json\" inside \"bin/modpack.jar\", but minecraft version is unknown"));
emit failed(tr("Could not find \"version.json\" inside \"bin/modpack.jar\", "
"the Minecraft version cannot be automatically determined"));
components->setComponentVersion("net.minecraft", minecraftVersion, true);
components->installJarMods({modpackJar});

Expand Down Expand Up @@ -145,7 +146,7 @@ void Technic::TechnicPackProcessor::run(SettingsObjectPtr globalSettings, const
else
{
// This is the "Vanilla" modpack, excluded by the search code
emit failed(tr("Unable to find a \"version.json\"!"));
emit failed(tr("Unable to find the file \"version.json\"!"));
return;
}

Expand All @@ -158,7 +159,7 @@ void Technic::TechnicPackProcessor::run(SettingsObjectPtr globalSettings, const
{
if (fmlMinecraftVersion.isEmpty())
{
emit failed(tr("Could not understand \"version.json\":\ninheritsFrom is missing"));
emit failed(tr("Could not parse the file \"version.json\":\ninheritsFrom is missing"));
return;
}
minecraftVersion = fmlMinecraftVersion;
Expand Down Expand Up @@ -199,7 +200,7 @@ void Technic::TechnicPackProcessor::run(SettingsObjectPtr globalSettings, const
}
catch (const JSONValidationError &e)
{
emit failed(tr("Could not understand \"version.json\":\n") + e.cause());
emit failed(tr("Could not parse the file \"version.json\":\n") + e.cause());
return;
}

Expand Down
2 changes: 1 addition & 1 deletion launcher/ui/InstanceWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ InstanceWindow::InstanceWindow(InstancePtr instance, QWidget *parent)
setAttribute(Qt::WA_DeleteOnClose);

auto icon = APPLICATION->icons()->getIcon(m_instance->iconKey());
QString windowTitle = tr("Console window for ") + m_instance->name();
QString windowTitle = tr("Console window for %1").arg(m_instance->name());

// Set window properties
{
Expand Down
2 changes: 1 addition & 1 deletion launcher/ui/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ class MainWindow::Ui
actionDISCORD->setObjectName(QStringLiteral("actionDISCORD"));
actionDISCORD->setIcon(APPLICATION->getThemedIcon("discord"));
actionDISCORD.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Discord"));
actionDISCORD.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open %1 discord voice chat."));
actionDISCORD.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open %1 Discord chat."));
all_actions.append(&actionDISCORD);
helpMenu->addAction(actionDISCORD);
}
Expand Down
4 changes: 2 additions & 2 deletions launcher/ui/dialogs/ProfileSelectDialog.ui
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@
<item>
<widget class="QCheckBox" name="globalDefaultCheck">
<property name="text">
<string>Use as default?</string>
<string>Use as default</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="instDefaultCheck">
<property name="text">
<string>Use as default for this instance only?</string>
<string>Use as default for this instance only</string>
</property>
</widget>
</item>
Expand Down
4 changes: 2 additions & 2 deletions launcher/ui/dialogs/UpdateDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,12 +133,12 @@ QString reprocessCommits(QByteArray json)
result += QObject::tr("<p>The update removes %1 commits and adds the following %2:</p>").arg(commit_behind).arg(commit_ahead);
print_commits();
}
result += QObject::tr("<p>You can <a href=\"%1\">look at the changes on github</a>.</p>").arg(diff_url);
result += QObject::tr("<p>You can <a href=\"%1\">look at the changes on GitHub</a>.</p>").arg(diff_url);
return result;
}
catch (const JSONValidationError &e)
{
qWarning() << "Got an unparseable commit log from github:" << e.what();
qWarning() << "Got an unparseable commit log from GitHub:" << e.what();
qDebug() << json;
}
return QString();
Expand Down
2 changes: 1 addition & 1 deletion launcher/ui/pages/global/AccountListPage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ AccountListPage::AccountListPage(QWidget *parent)
ui->setupUi(this);
ui->listView->setEmptyString(tr(
"Welcome!\n"
"If you're new here, you can click the \"Add\" button to add your Mojang or Minecraft account."
"Click the \"Add\" button to add a Mojang or Minecraft account."
));
ui->listView->setEmptyMode(VersionListView::String);
ui->listView->setContextMenuPolicy(Qt::CustomContextMenu);
Expand Down
11 changes: 4 additions & 7 deletions launcher/ui/pages/global/LauncherPage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,10 @@ void LauncherPage::on_instDirBrowseBtn_clicked()
if (FS::checkProblemticPathJava(QDir(cooked_dir)))
{
QMessageBox warning;
warning.setText(tr("You're trying to specify an instance folder which\'s path "
"contains at least one \'!\'. "
"Java is known to cause problems if that is the case, your "
"instances (probably) won't start!"));
warning.setInformativeText(
tr("Do you really want to use this path? "
"Selecting \"No\" will close this and not alter your instance path."));
warning.setText(tr("The specified instance path contains the disallowed symbol: '!'. "
"Java has problems with paths containing '!', it is unlikely that "
"the instance will be able to start."));
warning.setInformativeText(tr("Continue using the specified path?"));
warning.setStandardButtons(QMessageBox::Yes | QMessageBox::No);
int result = warning.exec();
if (result == QMessageBox::Yes)
Expand Down
8 changes: 4 additions & 4 deletions launcher/ui/pages/global/LauncherPage.ui
Original file line number Diff line number Diff line change
Expand Up @@ -364,21 +364,21 @@
<item>
<widget class="QCheckBox" name="showConsoleCheck">
<property name="text">
<string>Show console while the game is running?</string>
<string>Show console while the game is running</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="autoCloseConsoleCheck">
<property name="text">
<string>Automatically close console when the game quits?</string>
<string>Automatically close console when the game quits</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="showConsoleErrorCheck">
<property name="text">
<string>Show console when the game crashes?</string>
<string>Show console when the game crashes</string>
</property>
</widget>
</item>
Expand Down Expand Up @@ -499,7 +499,7 @@
<item>
<widget class="QCheckBox" name="analyticsCheck">
<property name="text">
<string>Send anonymous usage statistics?</string>
<string>Send anonymous usage statistics</string>
</property>
</widget>
</item>
Expand Down
2 changes: 1 addition & 1 deletion launcher/ui/pages/global/MinecraftPage.ui
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<item>
<widget class="QCheckBox" name="maximizedCheckBox">
<property name="text">
<string>Start Minecraft maximized?</string>
<string>Start Minecraft maximized</string>
</property>
</widget>
</item>
Expand Down
Loading