localize untranslated strings

This commit is contained in:
Alfonso Ruzafa 2022-05-16 21:36:52 +02:00
parent d2f22773e3
commit ebc89c2774
6 changed files with 17 additions and 16 deletions

View file

@ -830,7 +830,7 @@ lcCommandLineOptions lcApplication::ParseCommandLineOptions()
Options.StdOut += tr(" --no-highlight: Do not highlight parts in the steps they appear.\n"); Options.StdOut += tr(" --no-highlight: Do not highlight parts in the steps they appear.\n");
Options.StdOut += tr(" --highlight-color: Renderinng color for highlighted parts (#AARRGGBB).\n"); Options.StdOut += tr(" --highlight-color: Renderinng color for highlighted parts (#AARRGGBB).\n");
Options.StdOut += tr(" --shading <wireframe|flat|default|full>: Select shading mode for rendering.\n"); Options.StdOut += tr(" --shading <wireframe|flat|default|full>: Select shading mode for rendering.\n");
Options.StdOut += tr(" --line-width <width>: Set the with of the edge lines.\n"); Options.StdOut += tr(" --line-width <width>: Set the width of the edge lines.\n");
Options.StdOut += tr(" --aa-samples <count>: AntiAliasing sample size (1, 2, 4, or 8).\n"); Options.StdOut += tr(" --aa-samples <count>: AntiAliasing sample size (1, 2, 4, or 8).\n");
Options.StdOut += tr(" -scc, --stud-cylinder-color <#AARRGGBB>: High contrast stud cylinder color.\n"); Options.StdOut += tr(" -scc, --stud-cylinder-color <#AARRGGBB>: High contrast stud cylinder color.\n");
Options.StdOut += tr(" -ec, --edge-color <#AARRGGBB>: High contrast edge color.\n"); Options.StdOut += tr(" -ec, --edge-color <#AARRGGBB>: High contrast edge color.\n");

View file

@ -45,14 +45,14 @@ lcAutomateEdgeColorDialog::lcAutomateEdgeColorDialog(QWidget* Parent, bool ShowH
EdgeSettingsLayout->addWidget(ResetPartEdgeContrastButton,0,3); EdgeSettingsLayout->addWidget(ResetPartEdgeContrastButton,0,3);
} }
QLabel* PartColorValueLDIndexLabel = new QLabel(tr(ShowHighContrastDialog ? "Light/Dark Value:" : "Saturation:"), this); QLabel* PartColorValueLDIndexLabel = new QLabel(ShowHighContrastDialog ? tr("Light/Dark Value:") : tr("Saturation:"), this);
PartColorValueLDIndex = new QLabel(this); PartColorValueLDIndex = new QLabel(this);
PartColorValueLDIndexSlider = new QSlider(Qt::Horizontal, this); PartColorValueLDIndexSlider = new QSlider(Qt::Horizontal, this);
PartColorValueLDIndexSlider->setRange(0, 100); PartColorValueLDIndexSlider->setRange(0, 100);
PartColorValueLDIndexSlider->setValue(mPartColorValueLDIndex * 100); PartColorValueLDIndexSlider->setValue(mPartColorValueLDIndex * 100);
PartColorValueLDIndexSlider->setToolTip(tr(ShowHighContrastDialog ? PartColorValueLDIndexSlider->setToolTip(ShowHighContrastDialog ?
"Set to classify where color values are light or dark - e.g. Dark Bluish Gray (72) is light at 0.39." : tr("Set to classify where color values are light or dark - e.g. Dark Bluish Gray (72) is light at 0.39.") :
"Set to specify amount of edge color tint or shade from the saturation adjusted part color")); tr("Set to specify amount of edge color tint or shade from the saturation adjusted part color"));
connect(PartColorValueLDIndexSlider, SIGNAL(valueChanged(int)), this, SLOT(SliderValueChanged(int))); connect(PartColorValueLDIndexSlider, SIGNAL(valueChanged(int)), this, SLOT(SliderValueChanged(int)));
emit PartColorValueLDIndexSlider->valueChanged(PartColorValueLDIndexSlider->value()); emit PartColorValueLDIndexSlider->valueChanged(PartColorValueLDIndexSlider->value());
@ -176,7 +176,7 @@ void lcAutomateEdgeColorDialog::ColorButtonClicked()
if (lcGetPreferences().mAutomateEdgeColor) if (lcGetPreferences().mAutomateEdgeColor)
{ {
QMessageBox msgBox; QMessageBox msgBox;
msgBox.setText("Automate edge color appears to be enabled.<br>Black parts edge color will not be accessible.<br>Do you want to continue ?"); msgBox.setText(tr("Automate edge color appears to be enabled.<br>Black parts edge color will not be accessible.<br>Do you want to continue?"));
if (msgBox.exec() != QMessageBox::Accepted) if (msgBox.exec() != QMessageBox::Accepted)
return; return;
} }
@ -188,7 +188,7 @@ void lcAutomateEdgeColorDialog::ColorButtonClicked()
if (lcGetPreferences().mAutomateEdgeColor) if (lcGetPreferences().mAutomateEdgeColor)
{ {
QMessageBox msgBox; QMessageBox msgBox;
msgBox.setText("Automate edge color appears to be enabled.<br>Dark parts edge color will not be accessible.<br>Do you want to continue ?"); msgBox.setText(tr("Automate edge color appears to be enabled.<br>Dark parts edge color will not be accessible.<br>Do you want to continue?"));
if (msgBox.exec() != QMessageBox::Accepted) if (msgBox.exec() != QMessageBox::Accepted)
return; return;
} }

View file

@ -186,7 +186,7 @@ lcInstructionsPageListWidget::lcInstructionsPageListWidget(QWidget* Parent, lcIn
Layout->addLayout(ButtonsLayout); Layout->addLayout(ButtonsLayout);
QToolButton* PageSetupButton = new QToolButton(); QToolButton* PageSetupButton = new QToolButton();
PageSetupButton->setText("Page Setup"); PageSetupButton->setText(tr("Page Setup"));
ButtonsLayout->addWidget(PageSetupButton); ButtonsLayout->addWidget(PageSetupButton);
connect(PageSetupButton, SIGNAL(clicked()), this, SLOT(ShowPageSetupDialog())); connect(PageSetupButton, SIGNAL(clicked()), this, SLOT(ShowPageSetupDialog()));
@ -551,10 +551,10 @@ lcInstructionsDialog::lcInstructionsDialog(QWidget* Parent, Project* Project)
mPrintAction = mPageSettingsToolBar->addAction(tr("Print")); mPrintAction = mPageSettingsToolBar->addAction(tr("Print"));
mVerticalPageAction = mPageSettingsToolBar->addAction("Vertical"); mVerticalPageAction = mPageSettingsToolBar->addAction(tr("Vertical"));
mVerticalPageAction->setCheckable(true); mVerticalPageAction->setCheckable(true);
mHorizontalPageAction = mPageSettingsToolBar->addAction("Horizontal"); mHorizontalPageAction = mPageSettingsToolBar->addAction(tr("Horizontal"));
mHorizontalPageAction->setCheckable(true); mHorizontalPageAction->setCheckable(true);
mRowsSpinBox = new QSpinBox(mPageSettingsToolBar); mRowsSpinBox = new QSpinBox(mPageSettingsToolBar);
@ -568,7 +568,7 @@ lcInstructionsDialog::lcInstructionsDialog(QWidget* Parent, Project* Project)
PageDirectionGroup->addAction(mHorizontalPageAction); PageDirectionGroup->addAction(mHorizontalPageAction);
for (size_t PageNumber = 0; PageNumber < mInstructions->mPages.size(); PageNumber++) for (size_t PageNumber = 0; PageNumber < mInstructions->mPages.size(); PageNumber++)
mPageListWidget->mThumbnailsWidget->addItem(QString("Page %1").arg(PageNumber + 1)); mPageListWidget->mThumbnailsWidget->addItem(QString(tr("Page %1")).arg(PageNumber + 1));
connect(mPageListWidget->mThumbnailsWidget, SIGNAL(currentRowChanged(int)), this, SLOT(CurrentThumbnailChanged(int))); connect(mPageListWidget->mThumbnailsWidget, SIGNAL(currentRowChanged(int)), this, SLOT(CurrentThumbnailChanged(int)));
mPageListWidget->mThumbnailsWidget->setCurrentRow(0); mPageListWidget->mThumbnailsWidget->setCurrentRow(0);

View file

@ -899,7 +899,7 @@ void lcPartSelectionWidget::OptionsMenuAboutToShow()
QMenu* Menu = (QMenu*)sender(); QMenu* Menu = (QMenu*)sender();
Menu->clear(); Menu->clear();
Menu->addAction("Edit Palettes...", this, SLOT(EditPartPalettes())); Menu->addAction(tr("Edit Palettes..."), this, SLOT(EditPartPalettes()));
Menu->addSeparator(); Menu->addSeparator();
lcPartSelectionListModel* ListModel = mPartsWidget->GetListModel(); lcPartSelectionListModel* ListModel = mPartsWidget->GetListModel();

View file

@ -74,10 +74,11 @@ void lcPreviewDockWidget::SetPreviewLock()
} }
QIcon LockIcon(Locked ? ":/resources/action_preview_locked.png" : ":/resources/action_preview_unlocked.png"); QIcon LockIcon(Locked ? ":/resources/action_preview_locked.png" : ":/resources/action_preview_unlocked.png");
QString State(Locked ? tr("Unlock") : tr("Lock")); QString StatusTip(Locked
QString StatusTip(tr("%1 the preview display to %2 updates").arg(State).arg(Locked ? "enable" : "disable")); ? tr("Unlock the preview display to enable updates")
: tr("Lock the preview display to disable updates"));
mLockAction->setToolTip(tr("%1 Preview").arg(State)); mLockAction->setToolTip(Locked ? tr("Unlock Preview") : tr("Lock Preview"));
mLockAction->setIcon(LockIcon); mLockAction->setIcon(LockIcon);
mLockAction->setStatusTip(StatusTip); mLockAction->setStatusTip(StatusTip);
} }

View file

@ -130,7 +130,7 @@ Select shading mode for rendering.
.TP .TP
.BI "\-\-line-width " width .BI "\-\-line-width " width
Set the with of the edge lines. Set the width of the edge lines.
.TP .TP
.BI "\-\-aa\-samples " count .BI "\-\-aa\-samples " count