Skip to content

Commit

Permalink
qt: Tweak few strings (#3706)
Browse files Browse the repository at this point in the history
* Tweak few strings to make it easier to translate

Use args when it makes sense. Wrap 2 more strings with `tr()`.

* Fix typo
  • Loading branch information
UdjinM6 authored and charlesrocket committed Oct 1, 2020
1 parent 8c1efb2 commit eda153a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/qt/bitcoinamountfield.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ void BitcoinAmountField::unitChanged(int idx)
// Determine new unit ID
int newUnit = units->data(idx, BitcoinUnits::UnitRole).toInt();

amount->setPlaceholderText(tr("Amount in ") + units->data(idx,Qt::DisplayRole).toString());
amount->setPlaceholderText(tr("Amount in %1").arg(units->data(idx,Qt::DisplayRole).toString()));

amount->setDisplayUnit(newUnit);
}
Expand Down
2 changes: 1 addition & 1 deletion src/qt/guiutil.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ void setupAppearance(QWidget* parent, OptionsModel* model)
dlg.setWindowTitle(QObject::tr("Appearance Setup"));
dlg.setWindowIcon(QIcon(":icons/bitcoin"));
// And the widgets we add to it
QLabel lblHeading(QObject::tr("Please choose your prefered settings for the appearance of %1").arg(QObject::tr(PACKAGE_NAME)), &dlg);
QLabel lblHeading(QObject::tr("Please choose your preferred settings for the appearance of %1").arg(QObject::tr(PACKAGE_NAME)), &dlg);
lblHeading.setObjectName("lblHeading");
lblHeading.setWordWrap(true);
QLabel lblSubHeading(QObject::tr("This can also be adjusted later in the \"Appearance\" tab of the preferences."), &dlg);
Expand Down
4 changes: 2 additions & 2 deletions src/qt/masternodelist.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ void MasternodeList::updateDIP3ListScheduled()
// after filter was last changed unless we want to force the update.
if (fFilterUpdatedDIP3) {
int64_t nSecondsToWait = nTimeFilterUpdatedDIP3 - GetTime() + MASTERNODELIST_FILTER_COOLDOWN_SECONDS;
ui->countLabelDIP3->setText(tr("Please wait... %1").arg(nSecondsToWait));
ui->countLabelDIP3->setText(tr("Please wait...") + " " + QString::number(nSecondsToWait));

if (nSecondsToWait <= 0) {
updateDIP3List();
Expand Down Expand Up @@ -304,7 +304,7 @@ void MasternodeList::on_filterLineEditDIP3_textChanged(const QString& strFilterI
strCurrentFilterDIP3 = strFilterIn;
nTimeFilterUpdatedDIP3 = GetTime();
fFilterUpdatedDIP3 = true;
ui->countLabelDIP3->setText(tr("Please wait... %1").arg(MASTERNODELIST_FILTER_COOLDOWN_SECONDS));
ui->countLabelDIP3->setText(tr("Please wait...") + " " + QString::number(MASTERNODELIST_FILTER_COOLDOWN_SECONDS));
}

void MasternodeList::on_checkBoxMyMasternodesOnly_stateChanged(int state)
Expand Down
4 changes: 2 additions & 2 deletions src/qt/sendcoinsdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,10 @@ SendCoinsDialog::SendCoinsDialog(bool _fPrivateSend, QWidget* parent) :

if (fPrivateSend) {
ui->sendButton->setText("PrivateS&end");
ui->sendButton->setToolTip("Confirm the PrivateSend action");
ui->sendButton->setToolTip(tr("Confirm the PrivateSend action"));
} else {
ui->sendButton->setText(tr("S&end"));
ui->sendButton->setToolTip("Confirm the send action");
ui->sendButton->setToolTip(tr("Confirm the send action"));
}
}

Expand Down

0 comments on commit eda153a

Please sign in to comment.