Skip to content

Commit c36263a

Browse files
authored
[Translation] no splits (#3901)
* [translation] - Avoid to split sentence for - `"Abbreviations were exported to '%s'"` - `"Rename '%s'"` - `"Virtual Folder provided was: '%s'"` - `"Could not find target project: '%s'\n"` - `"Error while reading file content: '%s'.\n"` - `"Copy '%s' to the clipboard"` - `"'%s' copied!"` - `"Delete '%s'?"` - `"Save changes to '%s'?"` - `"Remove workspace configuration '%s'?"` - `"Remove configuration '%s'?"` - Avoid to split sentence for `"Delete formatter '%s'?"` - `"A project with the same name: '%s'\nalready exists"` (second part were/is missing in some languages) - `"Search the docs for '%s'"` - `"Edit build order for project '%s'"` Uniformize `"Are you sure you want to delete '%s'?"`
1 parent fea2ce9 commit c36263a

21 files changed

+411
-480
lines changed

CodeFormatter/codeformatterdlg.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ void CodeFormatterDlg::OnDelete(wxCommandEvent& event)
117117
}
118118

119119
wxString formatter_name = m_dvListCtrl->GetItemText(item);
120-
if (::wxMessageBox(_("Delete formatter '") + formatter_name + "'",
120+
if (::wxMessageBox(wxString::Format(_("Delete formatter '%s'?"), formatter_name),
121121
_("Delete formatter"),
122122
wxYES_NO | wxCANCEL | wxCANCEL_DEFAULT | wxICON_QUESTION) != wxYES) {
123123
return;

DebugAdapterClient/DapDebuggerSettingsDlg.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,10 @@ void DapDebuggerSettingsDlg::OnDelete(wxCommandEvent& event)
6262
}
6363

6464
wxString name = m_notebook->GetPageText(sel);
65-
if (::wxMessageBox(
66-
_("Delete '") + name + "'", "CodeLite", wxYES_NO | wxCANCEL | wxCANCEL_DEFAULT | wxICON_WARNING, this) !=
67-
wxYES) {
65+
if (::wxMessageBox(wxString::Format(_("Delete '%s'"), name),
66+
"CodeLite",
67+
wxYES_NO | wxCANCEL | wxCANCEL_DEFAULT | wxICON_WARNING,
68+
this) != wxYES) {
6869
return;
6970
}
7071

EOSWiki/eoswiki.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ void EOSWiki::CreateProject(const EOSProjectData& data)
8282
if (clCxxWorkspaceST::Get()->IsOpen()) {
8383
ProjectPtr proj = clCxxWorkspaceST::Get()->GetProject(data.GetName());
8484
if (proj) {
85-
::wxMessageBox(wxString() << _("A project with the same name: '") << data.GetName() << "'\nalready exists",
85+
::wxMessageBox(wxString::Format(_("A project with the same name: '%s'\nalready exists"), data.GetName()),
8686
"CodeLite",
8787
wxICON_ERROR | wxOK | wxOK_DEFAULT);
8888
return;

HelpPlugin/helpplugin.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,7 @@ void HelpPlugin::OnEditorContextMenu(clContextMenuEvent& event)
8282
wxMenu* menu = event.GetMenu();
8383
wxBitmap helpBitmap = wxXmlResource::Get()->LoadBitmap("svn_info");
8484
menu->AppendSeparator();
85-
wxString label;
86-
label << _("Search the docs for '") << modSelection << "'";
85+
wxString label = wxString::Format(_("Search the docs for '%s'"), modSelection);
8786
menu->Append(XRCID("ID_ZEAL_HELP"), label)->SetBitmap(helpBitmap);
8887
menu->AppendSeparator();
8988
}

LiteEditor/BuildOrderDialog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ BuildOrderDialog::BuildOrderDialog(wxWindow* parent, const wxString& projectName
99
: BuildOrderDialogBase(parent)
1010
, m_projectName(projectName)
1111
{
12-
SetLabel(_("Edit build order for project '") + projectName + "'");
12+
SetLabel(wxString::Format(_("Edit build order for project '%s'"), projectName));
1313

1414
m_dvListCtrlProjects->SetSortFunction(
1515
[](clRowEntry* a, clRowEntry* b) { return a->GetLabel(0).CmpNoCase(b->GetLabel(0)) < 0; });

LiteEditor/CompilerMainPage.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ void CompilerMainPage::OnDeleteFileType(wxCommandEvent& event)
227227
wxDataViewItem item = m_dvListCtrlFileTemplates->RowToItem(sel);
228228
wxString filetype = m_dvListCtrlFileTemplates->GetItemText(item);
229229

230-
if (wxMessageBox(wxString() << _("Are you sure you want to delete '") << filetype << "'?",
230+
if (wxMessageBox(wxString::Format(_("Are you sure you want to delete '%s'?"), filetype),
231231
wxT("CodeLite"),
232232
wxYES_NO | wxCANCEL) == wxYES) {
233233
m_dvListCtrlFileTemplates->DeleteItem(sel);

LiteEditor/edit_configuration.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,8 +180,7 @@ void EditConfigurationDialog::OnButtonDelete(wxCommandEvent& event)
180180
if(selection.IsEmpty()) {
181181
return;
182182
}
183-
wxString msg(_("Remove configuration '"));
184-
msg << selection << _("' ?");
183+
wxString msg = wxString::Format(_("Remove configuration '%s'?"), selection);
185184
if(wxMessageBox(msg, _("Confirm"), wxYES_NO | wxCANCEL | wxICON_WARNING) == wxYES) {
186185
ProjectSettingsPtr settings = ManagerST::Get()->GetProjectSettings(m_projectName);
187186
if(settings) {

LiteEditor/edit_workspace_conf_dlg.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,7 @@ void EditWorkspaceConfDlg::OnDelete(wxCommandEvent& event)
115115

116116
// remove the requested workspace build configuration
117117
BuildMatrixPtr matrix = ManagerST::Get()->GetWorkspaceBuildMatrix();
118-
wxString msg;
119-
msg << _("Remove workspace configuration '") << delMe << wxT("' ?");
118+
wxString msg = wxString::Format(_("Remove workspace configuration '%s'?"), delMe);
120119
if (wxMessageBox(msg, wxT("CodeLite"), wxICON_QUESTION | wxYES_NO | wxCANCEL) == wxYES) {
121120
matrix->RemoveConfiguration(delMe);
122121
// apply changes

LiteEditor/mainbook.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -380,8 +380,7 @@ bool MainBook::AskUserToSave(clEditor* editor)
380380
return true;
381381

382382
// unsaved changes
383-
wxString msg;
384-
msg << _("Save changes to '") << editor->GetFileName().GetFullName() << wxT("' ?");
383+
wxString msg = wxString::Format(_("Save changes to '%s'?"), editor->GetFileName().GetFullName());
385384
long style = wxYES_NO | wxICON_WARNING;
386385
if (!ManagerST::Get()->IsShutdownInProgress()) {
387386
style |= wxCANCEL;

Plugin/LSP/LanguageServerSettingsDlg.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,10 @@ void LanguageServerSettingsDlg::OnDeleteLSP(wxCommandEvent& event)
5555
}
5656
wxString serverName = m_notebook->GetPageText(sel);
5757

58-
if (::wxMessageBox(wxString() << _("Are you sure you want to delete '") << serverName << "' ?", "CodeLite",
59-
wxICON_QUESTION | wxCENTRE | wxYES_NO | wxCANCEL | wxCANCEL_DEFAULT, this) != wxYES) {
58+
if (::wxMessageBox(wxString::Format(_("Are you sure you want to delete '%s'?"), serverName),
59+
"CodeLite",
60+
wxICON_QUESTION | wxCENTRE | wxYES_NO | wxCANCEL | wxCANCEL_DEFAULT,
61+
this) != wxYES) {
6062
return;
6163
}
6264
LanguageServerConfig::Get().RemoveServer(serverName);

0 commit comments

Comments
 (0)