From c4bc5ef0b09d466bbec0ba3861eeb025c4999aeb Mon Sep 17 00:00:00 2001 From: David Kocik Date: Thu, 20 Jun 2024 17:51:08 +0200 Subject: [PATCH] Improved text --- src/slic3r/GUI/ConfigWizardWebViewPage.cpp | 19 +++++++++++++------ src/slic3r/GUI/ConfigWizardWebViewPage.hpp | 1 + 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/src/slic3r/GUI/ConfigWizardWebViewPage.cpp b/src/slic3r/GUI/ConfigWizardWebViewPage.cpp index 656bcc05db..a97b44f30e 100644 --- a/src/slic3r/GUI/ConfigWizardWebViewPage.cpp +++ b/src/slic3r/GUI/ConfigWizardWebViewPage.cpp @@ -5,6 +5,7 @@ #include "GUI_App.hpp" #include "Plater.hpp" #include "slic3r/GUI/I18N.hpp" +#include "format.hpp" #include @@ -31,12 +32,17 @@ ConfigWizardWebViewPage::ConfigWizardWebViewPage(ConfigWizard *parent) } if (logged) { // TRN Config wizard page with a log in web. - m_text = new wxStaticText(this, wxID_ANY, format_wxstr("You are logged as %1%.", p_user_account->get_username())); + m_text = new wxStaticText(this, wxID_ANY, format_wxstr("You are logged as %1%.", p_user_account->get_username())); } else { - // TRN Config wizard page with a log in web. - m_text = new wxStaticText(this, wxID_ANY, _L("Please log into your Prusa Account. This step is not mandatory.")); + // TRN Config wizard page with a log in web. first line of text. + m_text = new wxStaticText(this, wxID_ANY, _L("Please log into your Prusa Account.")); + // TRN Config wizard page with a log in web. second line of text. + m_bold_text = new wxStaticText(this, wxID_ANY, _L("This step is optional.")); + m_bold_text->SetFont(wxGetApp().bold_font()); + m_bold_text->Wrap(WRAP_WIDTH); } append(m_text); + append(m_bold_text); m_browser_sizer->Add(m_browser, 1, wxEXPAND); append(m_browser_sizer, 1, wxEXPAND); @@ -50,15 +56,16 @@ ConfigWizardWebViewPage::ConfigWizardWebViewPage(ConfigWizard *parent) void ConfigWizardWebViewPage::login_changed() { - assert(p_user_account && m_browser_sizer && m_text); + assert(p_user_account && m_browser_sizer && m_text && m_bold_text); bool logged = p_user_account->is_logged(); m_browser_sizer->Show(!logged); + m_bold_text->Show(!logged); if (logged) { // TRN Config wizard page with a log in web. m_text->SetLabel(format_wxstr("You are logged as %1%.", p_user_account->get_username())); } else { - // TRN Config wizard page with a log in web. - m_text->SetLabel(_L("Please log into your Prusa Account. This step is not mandatory.")); + // TRN Config wizard page with a log in web. first line of text. + m_text->SetLabel(_L("Please log into your Prusa Account.")); } } diff --git a/src/slic3r/GUI/ConfigWizardWebViewPage.hpp b/src/slic3r/GUI/ConfigWizardWebViewPage.hpp index 193e66db6d..89398a49b5 100644 --- a/src/slic3r/GUI/ConfigWizardWebViewPage.hpp +++ b/src/slic3r/GUI/ConfigWizardWebViewPage.hpp @@ -57,6 +57,7 @@ private: UserAccount *p_user_account{nullptr}; wxBoxSizer *m_browser_sizer{nullptr}; wxStaticText *m_text{nullptr}; + wxStaticText *m_bold_text{nullptr}; }; }} // namespace Slic3r::GUI