Fixes in phrases

This commit is contained in:
Lukas Matena 2023-10-20 13:33:56 +02:00
parent 6274f24e93
commit f0458daceb
4 changed files with 19 additions and 19 deletions

View File

@ -1136,8 +1136,10 @@ std::vector<std::string> create_shape_warnings(const EmbossShape &shape, float s
}
std::string fill_warning = create_fill_warning(*shape);
if (!fill_warning.empty())
if (!fill_warning.empty()) {
// TRN: The first placeholder is shape identifier, the second one is text describing the problem.
add_warning(shape_index * 2, GUI::format(_L("Fill of shape (%1%) contains unsupported: %2% "), shape->id, fill_warning));
}
float minimal_width_in_mm = 1e-3f;
if (shape->strokeWidth <= minimal_width_in_mm * scale) {

View File

@ -1928,7 +1928,7 @@ void MainFrame::load_config_file()
DynamicPrintConfig config = wxGetApp().preset_bundle->full_config();
const auto* post_process = config.opt<ConfigOptionStrings>("post_process");
if (post_process != nullptr && !post_process->values.empty()) {
const wxString msg = _L("The selected config file contains a post-processing script") + "\n" + _L("Please review the script carefully before running it.");
const wxString msg = _L("The selected config file contains a post-processing script.\nPlease review the script carefully before exporting G-code.");
wxString text;
for (const auto& s : post_process->values) {
text += s;

View File

@ -2616,13 +2616,12 @@ std::vector<size_t> Plater::priv::load_files(const std::vector<fs::path>& input_
if (!config.empty()) {
const auto* post_process = config.opt<ConfigOptionStrings>("post_process");
if (post_process != nullptr && !post_process->values.empty()) {
wxString msg = type_3mf ? _L("The selected 3MF file contains a post-processing script") :
_L("The selected AMF file contains a post-processing script");
msg += "\n" + _L("Please review the script carefully before running it.");
// TRN The placeholder is either "3MF" or "AMF"
wxString msg = GUI::format_wxstr(_L("The selected %1% file contains a post-processing script.\n"
"Please review the script carefully before exporting G-code."), type_3mf ? "3MF" : "AMF" );
wxString text;
for (const auto& s : post_process->values) {
for (const auto& s : post_process->values)
text += s;
}
InfoDialog msg_dlg(nullptr, msg, text, true, wxOK | wxICON_WARNING);
msg_dlg.set_caption(wxString(SLIC3R_APP_NAME " - ") + _L("Attention!"));
@ -5589,10 +5588,8 @@ void Plater::convert_gcode_to_ascii()
}
else {
output_file = rename_file(output_file, ".gcode");
wxString msg = _L("You are trying to convert to ASCII a binary file whose extension is '.gcode'.");
msg += "\n" + _L("The exported file will be renamed as:");
msg += "\n\n" + output_file;
msg += "\n\n" + _L("Continue with export?");
wxString msg = GUI::format_wxstr("The converted binary G-code file has '.gcode' extension.\n"
"The exported file will be renamed to:\n\n%1%\n\nDo you want to continue?", output_file);
MessageDialog msg_dlg(this, msg, _L("Warning"), wxYES_NO);
if (msg_dlg.ShowModal() != wxID_YES)
return;
@ -5669,10 +5666,8 @@ void Plater::convert_gcode_to_binary()
}
else {
output_file = rename_file(output_file, ".bgcode");
wxString msg = _L("You are trying to convert to binary an ASCII file whose extension is '.bgcode'.");
msg += "\n" + _L("The exported file will be renamed as:");
msg += "\n\n" + output_file;
msg += "\n\n" + _L("Continue with export?");
wxString msg = GUI::format_wxstr("The converted ASCII G-code file has '.bgcode' extension.\n"
"The exported file will be renamed to:\n\n%1%\n\nDo you want to continue?", output_file);
MessageDialog msg_dlg(this, msg, _L("Warning"), wxYES_NO);
if (msg_dlg.ShowModal() != wxID_YES)
return;

View File

@ -18,7 +18,10 @@
namespace Slic3r {
namespace GUI {
const char* WIFI_CONFIGFILE_NAME = "prusa_printer_settings.ini";
WifiConfigDialog::WifiConfigDialog(wxWindow* parent, std::string& file_path, RemovableDriveManager* removable_manager)
// TRN: This is the dialog title.
: DPIDialog(parent, wxID_ANY, _L("Wi-Fi Configuration File Generator"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER)
, m_wifi_scanner(new WifiScanner())
, out_file_path(file_path)
@ -33,14 +36,14 @@ WifiConfigDialog::WifiConfigDialog(wxWindow* parent, std::string& file_path, Rem
// TRN Wifi config dialog explanation line 1.
wxStaticText* explain_label1 = new wxStaticText(panel, wxID_ANY, _L("Generate a file to be loaded by a Prusa printer to configure its Wi-Fi connection."));
// TRN Wifi config dialog explanation line 2.
wxStaticText* explain_label2 = new wxStaticText(panel, wxID_ANY, _L("Write this file on a USB flash drive. Its name will be prusa_printer_settings.ini."));
wxStaticText* explain_label2 = new wxStaticText(panel, wxID_ANY, GUI::format_wxstr(_L("Write this file on the USB flash drive. Its name will be %1%."), WIFI_CONFIGFILE_NAME));
// TRN Wifi config dialog explanation line 3.
wxStaticText* explain_label3 = new wxStaticText(panel, wxID_ANY, _L("Your Prusa Printer should load this file automatically."));
// TRN Wifi config dialog explanation line 4.
wxStaticText* explain_label4 = new wxStaticText(panel, wxID_ANY, _L("Note: This file will contains SSID and password in plain text."));
wxStaticText* explain_label4 = new wxStaticText(panel, wxID_ANY, _L("Note: This file will contain the SSID and password in plain text."));
auto* ssid_sizer = new wxBoxSizer(wxHORIZONTAL);
// TRN SSID of WiFi network.
// TRN SSID of WiFi network. It is a standard abbreviation which should probably not change in most languages.
wxStaticText* ssid_label = new wxStaticText(panel, wxID_ANY, GUI::format_wxstr("%1%:", _L("SSID")));
m_ssid_combo = new ::ComboBox(panel, wxID_ANY);
#if __APPLE__
@ -212,7 +215,7 @@ void WifiConfigDialog::on_ok(wxCommandEvent& e)
return;
}
boost::filesystem::path file_path = boost::filesystem::path(selected_path) / "prusa_printer_settings.ini";
boost::filesystem::path file_path = boost::filesystem::path(selected_path) / WIFI_CONFIGFILE_NAME;
bool path_on_removable_media = m_removable_manager->set_and_verify_last_save_path(file_path.string());
if (!path_on_removable_media) {