Commit 2ae4ce1b authored by Pino Toscano's avatar Pino Toscano
Browse files

i18n fixes

- fix few string puzzles
- avoid contractions ("don't" -> "do not", etc)
- remove extra whitespaces
- use i18np where needed
- remove extra exclamation marks
parent 3d2cd8b6
Pipeline #1460 passed with stage
in 15 minutes and 53 seconds
......@@ -51,7 +51,7 @@ KeyframeImport::KeyframeImport(int in, int out, const QString &animData, std::sh
{
auto *lay = new QVBoxLayout(this);
auto *l1 = new QHBoxLayout;
QLabel *lab = new QLabel(i18n("Data to import: "), this);
QLabel *lab = new QLabel(i18n("Data to import:"), this);
l1->addWidget(lab);
m_dataCombo = new QComboBox(this);
......
......@@ -1018,7 +1018,7 @@ void Bin::slotReloadClip()
f.close();
KMessageBox::information(
this,
i18n("Your project file was modified by Kdenlive.\nTo make sure you don't lose data, a backup copy called %1 was created.",
i18n("Your project file was modified by Kdenlive.\nTo make sure you do not lose data, a backup copy called %1 was created.",
backupFile));
}
}
......@@ -1051,7 +1051,7 @@ void Bin::slotLocateClip()
qCDebug(KDENLIVE_LOG) << " / / " + url.toString();
} else {
if (!exists) {
emitMessage(i18n("Couldn't locate ") + QString(" (" + url.toString() + QLatin1Char(')')), 100, ErrorMessage);
emitMessage(i18n("Could not locate %1", url.toString()), 100, ErrorMessage);
}
return;
}
......@@ -1158,7 +1158,7 @@ void Bin::createClip(const QDomElement &xml)
out << doc.toString();
f.close();
KMessageBox::information(
this, i18n("Your project file was modified by Kdenlive.\nTo make sure you don't lose data, a backup copy called %1 was created.",
this, i18n("Your project file was modified by Kdenlive.\nTo make sure you do not lose data, a backup copy called %1 was created.",
backupFile));
}
}
......
......@@ -37,7 +37,7 @@ ManageCapturesDialog::ManageCapturesDialog(const QList<QUrl> &files, QWidget *pa
setFont(QFontDatabase::systemFont(QFontDatabase::SmallestReadableFont));
m_view.setupUi(this);
m_importButton = m_view.buttonBox->button(QDialogButtonBox::Ok);
m_importButton->setText(i18n("import"));
m_importButton->setText(i18n("Import"));
m_view.treeWidget->setIconSize(QSize(70, 50));
for (const QUrl &url : files) {
QStringList text;
......
......@@ -672,7 +672,7 @@ bool RenderWidget::saveProfile(QDomElement newprofile)
bool ok;
while (existingProfileNames.contains(newProfileName)) {
QString updatedProfileName = QInputDialog::getText(this, i18n("Profile already exists"),
i18n("This profile name already exists. Change the name if you don't want to overwrite it."),
i18n("This profile name already exists. Change the name if you do not want to overwrite it."),
QLineEdit::Normal, newProfileName, &ok);
if (!ok) {
return false;
......@@ -880,7 +880,7 @@ void RenderWidget::slotEditProfile()
// a profile with that same name already exists
bool ok;
newProfileName = QInputDialog::getText(this, i18n("Profile already exists"),
i18n("This profile name already exists. Change the name if you don't want to overwrite it."),
i18n("This profile name already exists. Change the name if you do not want to overwrite it."),
QLineEdit::Normal, newProfileName, &ok);
if (!ok) {
return;
......@@ -3363,7 +3363,7 @@ void RenderWidget::adjustSpeed(int speedIndex)
if (m_view.formats->currentItem()) {
QStringList speeds = m_view.formats->currentItem()->data(0, SpeedsRole).toStringList();
if (speedIndex < speeds.count()) {
m_view.speed->setToolTip(i18n("Codec speed parameters:\n") + speeds.at(speedIndex));
m_view.speed->setToolTip(i18n("Codec speed parameters:\n%1", speeds.at(speedIndex)));
}
}
}
......
......@@ -370,7 +370,7 @@ bool DocumentValidator::upgrade(double version, const double currentVersion)
// qCDebug(KDENLIVE_LOG) << "Unable to open document with version " << version;
KMessageBox::sorry(
QApplication::activeWindow(),
i18n("This project type is unsupported (version %1) and can't be loaded.\nPlease consider upgrading your Kdenlive version.", version),
i18n("This project type is unsupported (version %1) and cannot be loaded.\nPlease consider upgrading your Kdenlive version.", version),
i18n("Unable to open project"));
return false;
}
......@@ -379,7 +379,7 @@ bool DocumentValidator::upgrade(double version, const double currentVersion)
if (qFuzzyCompare(version, 0.5) || qFuzzyCompare(version, 0.7)) {
// 0.7 is unsupported
// qCDebug(KDENLIVE_LOG) << "Unable to open document with version " << version;
KMessageBox::sorry(QApplication::activeWindow(), i18n("This project type is unsupported (version %1) and can't be loaded.", version),
KMessageBox::sorry(QApplication::activeWindow(), i18n("This project type is unsupported (version %1) and cannot be loaded.", version),
i18n("Unable to open project"));
return false;
}
......@@ -2094,7 +2094,7 @@ bool DocumentValidator::checkMovit()
}
if (KMessageBox::questionYesNo(QApplication::activeWindow(),
i18n("The project file uses some GPU effects. GPU acceleration is not currently enabled.\nDo you want to convert the "
"project to a non-GPU version ?\nThis might result in data loss.")) != KMessageBox::Yes) {
"project to a non-GPU version?\nThis might result in data loss.")) != KMessageBox::Yes) {
return false;
}
// Try to convert Movit filters to their non GPU equivalent
......
......@@ -566,11 +566,11 @@ bool KdenliveDoc::saveSceneList(const QString &path, const QString &scene)
}
QString message;
if (m_documentOpenStatus == UpgradedProject) {
message = i18n("Your project file was upgraded to the latest Kdenlive document version.\nTo make sure you don't lose data, a backup copy called %1 "
message = i18n("Your project file was upgraded to the latest Kdenlive document version.\nTo make sure you do not lose data, a backup copy called %1 "
"was created.",
backupFile);
} else {
message = i18n("Your project file was modified by Kdenlive.\nTo make sure you don't lose data, a backup copy called %1 was created.", backupFile);
message = i18n("Your project file was modified by Kdenlive.\nTo make sure you do not lose data, a backup copy called %1 was created.", backupFile);
}
KIO::FileCopyJob *copyjob = KIO::file_copy(QUrl::fromLocalFile(path), QUrl::fromLocalFile(backupFile));
......@@ -1384,7 +1384,7 @@ void KdenliveDoc::switchProfile(std::unique_ptr<ProfileParam> &profile, const QS
QString currentProfileDesc = pCore->getCurrentProfile()->description();
KMessageBox::ButtonCode answer = KMessageBox::questionYesNoCancel(
QApplication::activeWindow(),
i18n("Your default project profile is %1, but your clip's profile is %2.\nDo you want to change default profile for future projects ?",
i18n("Your default project profile is %1, but your clip's profile is %2.\nDo you want to change default profile for future projects?",
currentProfileDesc, profile->description()),
i18n("Change default project profile"), KGuiItem(i18n("Change default to %1", profile->description())),
KGuiItem(i18n("Keep current default %1", currentProfileDesc)), KGuiItem(i18n("Ask me later")));
......
......@@ -231,7 +231,7 @@ void DvdWizardVob::slotTranscodeFinished(int exitCode, QProcess::ExitStatus exit
// Something failed
// TODO show log
m_warnMessage->setMessageType(KMessageWidget::Warning);
m_warnMessage->setText(i18n("Transcoding failed!"));
m_warnMessage->setText(i18n("Transcoding failed"));
m_warnMessage->animatedShow();
m_transcodeQueue.clear();
}
......
......@@ -198,7 +198,7 @@ bool EffectStackModel::copyEffect(const std::shared_ptr<AbstractEffectItem> &sou
if (result && logUndo) {
std::shared_ptr<EffectItemModel> sourceEffect = std::static_pointer_cast<EffectItemModel>(sourceItem);
QString effectName = EffectsRepository::get()->getName(sourceEffect->getAssetId());
PUSH_UNDO(undo, redo, i18n("copy effect %1", effectName));
PUSH_UNDO(undo, redo, i18n("Copy effect %1", effectName));
}
return result;
}
......
......@@ -328,7 +328,7 @@ void LibraryWidget::slotDeleteFromLibrary()
if (current->data(0, Qt::UserRole + 2).toInt() == LibraryItem::PlayList) {
message = i18n("This will delete the MLT playlist:\n%1", path);
} else {
message = i18n("This will delete the file :\n%1", path);
message = i18n("This will delete the file:\n%1", path);
}
if (KMessageBox::warningContinueCancel(this, message) != KMessageBox::Continue) {
return;
......
......@@ -872,7 +872,7 @@ void MainWindow::setupActions()
connect(sceneMode, static_cast<void (KSelectAction::*)(QAction *)>(&KSelectAction::triggered), this, &MainWindow::slotChangeEdit);
addAction(QStringLiteral("timeline_mode"), sceneMode);
m_useTimelineZone = new KDualAction(i18n("Don't Use Timeline Zone for Insert"), i18n("Use Timeline Zone for Insert"), this);
m_useTimelineZone = new KDualAction(i18n("Do not Use Timeline Zone for Insert"), i18n("Use Timeline Zone for Insert"), this);
m_useTimelineZone->setActiveIcon(QIcon::fromTheme(QStringLiteral("timeline-use-zone-on")));
m_useTimelineZone->setInactiveIcon(QIcon::fromTheme(QStringLiteral("timeline-use-zone-off")));
m_useTimelineZone->setAutoToggle(true);
......@@ -3044,7 +3044,7 @@ void MainWindow::buildDynamicActions()
for (const QString &stab : {QStringLiteral("vidstab"), QStringLiteral("videostab2"), QStringLiteral("videostab")}) {
filter = std::make_unique<Mlt::Filter>(profile, stab.toUtf8().constData());
if ((filter != nullptr) && filter->is_valid()) {
QAction *action = new QAction(i18n("Stabilize") + QStringLiteral(" (") + stab + QLatin1Char(')'), m_extraFactory->actionCollection());
QAction *action = new QAction(i18n("Stabilize (%1)", stab), m_extraFactory->actionCollection());
ts->addAction(action->text(), action);
connect(action, &QAction::triggered, [stab]() {
pCore->jobManager()->startJob<StabilizeJob>(pCore->bin()->selectedClipsIds(), {},
......@@ -3691,7 +3691,7 @@ void MainWindow::forceIconSet(bool force)
bool useDarkIcons = background.value() < 100;
KdenliveSettings::setUse_dark_breeze(useDarkIcons);
}
if (KMessageBox::warningContinueCancel(this, i18n("Kdenlive needs to be restarted to apply icon theme change. Restart now ?")) == KMessageBox::Continue) {
if (KMessageBox::warningContinueCancel(this, i18n("Kdenlive needs to be restarted to apply the icon theme change. Restart now?")) == KMessageBox::Continue) {
slotRestart();
}
}
......
......@@ -278,7 +278,7 @@ void ClipTranscode::slotTranscodeFinished(int exitCode, QProcess::ExitStatus exi
}
} else {
m_infoMessage->setMessageType(KMessageWidget::Warning);
m_infoMessage->setText(i18n("Transcoding failed!"));
m_infoMessage->setText(i18n("Transcoding failed"));
m_infoMessage->animatedShow();
log_text->setVisible(true);
}
......
......@@ -211,7 +211,7 @@ void ProfileWidget::fillDescriptionPanel(const QString &profile_path)
if (profile->progressive()) {
interlaced = i18n("no");
}
description += i18n("Interlaced : %1</p>", interlaced);
description += i18n("Interlaced: %1</p>", interlaced);
}
m_descriptionPanel->setHtml(description);
}
......
......@@ -433,7 +433,7 @@ void ProjectSettings::accept()
if (KMessageBox::warningContinueCancel(
this,
i18n("Changing the profile of your project cannot be undone.\nIt is recommended to save your project before attempting this operation "
"that might cause some corruption in transitions.\n Are you sure you want to proceed?"),
"that might cause some corruption in transitions.\nAre you sure you want to proceed?"),
i18n("Confirm profile change")) == KMessageBox::Cancel) {
return;
}
......
......@@ -441,7 +441,7 @@ bool ProjectManager::checkForBackupFile(const QUrl &url, bool newFile)
if (orphanedFile) {
if (KMessageBox::questionYesNo(nullptr, i18n("Auto-saved files exist. Do you want to recover them now?"), i18n("File Recovery"),
KGuiItem(i18n("Recover")), KGuiItem(i18n("Don't recover"))) == KMessageBox::Yes) {
KGuiItem(i18n("Recover")), KGuiItem(i18n("Do not recover"))) == KMessageBox::Yes) {
doOpenFile(url, orphanedFile);
return true;
}
......
......@@ -521,7 +521,7 @@ bool TimelineFunctions::requestSplitAudio(const std::shared_ptr<TimelineItemMode
for (int cid : clips) {
if (!timeline->getClipPtr(cid)->canBeAudio() || timeline->getClipPtr(cid)->clipState() == PlaylistState::AudioOnly) {
// clip without audio or audio only, skip
pCore->displayMessage(i18n("One or more clips don't have audio, or are already audio"), ErrorMessage);
pCore->displayMessage(i18n("One or more clips do not have audio, or are already audio"), ErrorMessage);
return false;
}
int position = timeline->getClipPosition(cid);
......
......@@ -2007,7 +2007,7 @@ void TitleWidget::setXml(const QDomDocument &doc, const QString &id)
m_missingMessage->setCloseButtonVisible(true);
m_missingMessage->setWordWrap(true);
m_missingMessage->setMessageType(KMessageWidget::Warning);
m_missingMessage->setText(i18n("This title has %1 missing elements", m_titledocument.invalidCount()));
m_missingMessage->setText(i18np("This title has 1 missing element", "This title has %1 missing elements", m_titledocument.invalidCount()));
QAction *action = new QAction(i18n("Details"));
m_missingMessage->addAction(action);
connect(action, &QAction::triggered, this, &TitleWidget::showMissingItems);
......@@ -2125,7 +2125,7 @@ void TitleWidget::showMissingItems()
}
}
missingUrls.removeDuplicates();
KMessageBox::informationList(QApplication::activeWindow(), i18n("The following files are missing: "), missingUrls);
KMessageBox::informationList(QApplication::activeWindow(), i18n("The following files are missing:"), missingUrls);
}
void TitleWidget::writeChoices()
......
......@@ -36,7 +36,7 @@ Rectangle {
Label {
Layout.fillWidth:true
text: i18n("Properties of transition ") + transitionName
text: i18n("Properties of transition %1", transitionName)
}
AssetView {
Layout.fillWidth:true
......
......@@ -55,7 +55,7 @@ void TransitionStackView::setModel(const std::shared_ptr<AssetParameterModel> &m
if (!pCore->compositionAutoTrack(model->getOwnerId().second)) {
m_trackBox->setCurrentIndex(m_trackBox->findData(aTrack.first));
}
QLabel *title = new QLabel(i18n("Composition track: "), this);
QLabel *title = new QLabel(i18n("Composition track:"), this);
lay->addWidget(title);
lay->addWidget(m_trackBox);
m_lay->insertLayout(0, lay);
......
......@@ -455,7 +455,7 @@ void ResourceWidget::slotFreesoundUseHQPreview()
int ret =
QMessageBox::warning(this, i18n("File Exists"),
i18n("HQ preview files are all mp3 files. We have added .mp3 as a file extension to the destination file name you chose. "
"However, there is an existing file of this name present. \n Do you want to overwrite the existing file?. ") +
"However, there is an existing file of this name present.\n Do you want to overwrite the existing file?") +
QStringLiteral("\n") + m_saveLocation,
QMessageBox::Yes | QMessageBox::No, QMessageBox::No);
if (ret == QMessageBox::No) {
......@@ -497,7 +497,7 @@ void ResourceWidget::slotGotFile(KJob *job)
auto *copyJob = static_cast<KIO::FileCopyJob *>(job);
const QUrl filePath = copyJob->destUrl();
KMessageBox::information(this, i18n("Resource saved to ") + filePath.toLocalFile(), i18n("Data Imported"));
KMessageBox::information(this, i18n("Resource saved to %1", filePath.toLocalFile()), i18n("Data Imported"));
emit addClip(filePath, QStringList());
}
......@@ -834,7 +834,7 @@ void ResourceWidget::DownloadRequestFinished(QNetworkReply *reply)
file.write(aSoundData);
file.close();
KMessageBox::information(this, i18n("Resource saved to ") + m_saveLocation, i18n("Data Imported"));
KMessageBox::information(this, i18n("Resource saved to %1", m_saveLocation), i18n("Data Imported"));
emit addClip(QUrl(m_saveLocation), QStringList()); // MainWindow::slotDownloadResources() links this signal to MainWindow::slotAddProjectClip
m_desc.append(QStringLiteral("<br>") + i18n("Saved file to") + QStringLiteral("<br>"));
......@@ -857,7 +857,7 @@ void ResourceWidget::DownloadRequestFinished(QNetworkReply *reply)
#ifdef QT5_USE_WEBKIT
m_pOAuth2->ForgetAccessToken();
#endif
m_desc.append(QStringLiteral("<br>") + i18n("Error Downloading File. Error code: ") + reply->error() + QStringLiteral("<br>"));
m_desc.append(QStringLiteral("<br>") + i18n("Error Downloading File. Error code: %1", reply->error()) + QStringLiteral("<br>"));
m_desc.append(QStringLiteral("<br><b>") + i18n("Try importing again to obtain a new freesound connection") + QStringLiteral("</b>"));
updateLayout();
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment