diff --git a/src/slic3r/GUI/AMSSetting.cpp b/src/slic3r/GUI/AMSSetting.cpp index 3215628c5..e5fbd5fa9 100644 --- a/src/slic3r/GUI/AMSSetting.cpp +++ b/src/slic3r/GUI/AMSSetting.cpp @@ -27,19 +27,19 @@ void AMSSetting::create() m_panel_body->SetBackgroundColour(*wxWHITE); wxBoxSizer *m_sizerl_body = new wxBoxSizer(wxVERTICAL); - m_panel_Insert_material = new wxPanel(this, wxID_ANY, wxDefaultPosition, wxSize(-1, -1), wxTAB_TRAVERSAL); + m_panel_Insert_material = new wxPanel(m_panel_body, wxID_ANY, wxDefaultPosition, wxSize(-1, -1), wxTAB_TRAVERSAL); m_panel_Insert_material->SetBackgroundColour(*wxWHITE); wxBoxSizer* m_sizer_main_Insert_material = new wxBoxSizer(wxVERTICAL); // checkbox area 1 wxBoxSizer *m_sizer_Insert_material = new wxBoxSizer(wxHORIZONTAL); - m_checkbox_Insert_material_auto_read = new ::CheckBox(m_panel_body); + m_checkbox_Insert_material_auto_read = new ::CheckBox(m_panel_Insert_material); m_checkbox_Insert_material_auto_read->Bind(wxEVT_TOGGLEBUTTON, &AMSSetting::on_insert_material_read, this); m_sizer_Insert_material->Add(m_checkbox_Insert_material_auto_read, 0, wxTOP, 1); m_sizer_Insert_material->Add(0, 0, 0, wxLEFT, 12); - m_title_Insert_material_auto_read = new wxStaticText(m_panel_body, wxID_ANY, _L("Insertion update"), + m_title_Insert_material_auto_read = new wxStaticText(m_panel_Insert_material, wxID_ANY, _L("Insertion update"), wxDefaultPosition, wxDefaultSize, 0); m_title_Insert_material_auto_read->SetFont(::Label::Head_13); @@ -55,7 +55,7 @@ void AMSSetting::create() m_sizer_Insert_material_tip->Add(0, 0, 0, wxLEFT, 10); // tip line1 - m_tip_Insert_material_line1 = new Label(m_panel_body, + m_tip_Insert_material_line1 = new Label(m_panel_Insert_material, _L("The AMS will automatically read the filament information when inserting a new Bambu Lab filament. This takes about 20 seconds.") ); m_tip_Insert_material_line1->SetFont(::Label::Body_13); @@ -66,7 +66,7 @@ void AMSSetting::create() m_sizer_Insert_material_tip_inline->Add(m_tip_Insert_material_line1, 0, wxEXPAND, 0); // tip line2 - m_tip_Insert_material_line2 = new Label(m_panel_body, + m_tip_Insert_material_line2 = new Label(m_panel_Insert_material, _L("Note: if a new filament is inserted during printing, the AMS will not automatically read any information until printing is completed.") ); m_tip_Insert_material_line2->SetFont(::Label::Body_13); @@ -77,7 +77,7 @@ void AMSSetting::create() m_sizer_Insert_material_tip_inline->Add(m_tip_Insert_material_line2, 0, wxEXPAND | wxTOP, 8); // tip line3 - m_tip_Insert_material_line3 = new Label(m_panel_body, + m_tip_Insert_material_line3 = new Label(m_panel_Insert_material, _L("When inserting a new filament, the AMS will not automatically read its information, leaving it blank for you to enter manually.") ); m_tip_Insert_material_line3->SetFont(::Label::Body_13); @@ -89,8 +89,8 @@ void AMSSetting::create() m_sizer_Insert_material_tip->Add(m_sizer_Insert_material_tip_inline, 1, wxALIGN_CENTER, 0); - m_sizer_main_Insert_material->Add(m_sizer_Insert_material, 0, wxEXPAND | wxTOP, FromDIP(8)); - m_sizer_main_Insert_material->Add(m_sizer_Insert_material_tip, 0, wxEXPAND | wxLEFT | wxTOP, 10); + m_sizer_main_Insert_material->Add(m_sizer_Insert_material, 0, wxEXPAND | wxTOP, FromDIP(4)); + m_sizer_main_Insert_material->Add(m_sizer_Insert_material_tip, 0, wxEXPAND | wxLEFT | wxTOP, 18); m_panel_Insert_material->SetSizer(m_sizer_main_Insert_material); // checkbox area 2 @@ -228,7 +228,8 @@ void AMSSetting::create() m_sizerl_body->Fit(m_panel_body); m_sizer_main->Add(0, 0, 0, wxTOP, FromDIP(10)); m_sizer_main->Add(m_static_ams_settings, 0, wxEXPAND | wxLEFT | wxRIGHT, FromDIP(24)); - m_sizer_main->Add(m_panel_body, 1, wxALL | wxEXPAND, FromDIP(24)); + m_sizer_main->Add(0, 0, 0, wxTOP, FromDIP(10)); + m_sizer_main->Add(m_panel_body, 1, wxBottom | wxLEFT | wxRIGHT | wxEXPAND, FromDIP(24)); this->SetSizer(m_sizer_main); this->Layout(); @@ -251,7 +252,7 @@ void AMSSetting::create() void AMSSetting::update_insert_material_read_mode(bool selected, std::string version) { - if (!version.empty() && version > AMS_F1_SUPPORT_INSERTION_UPDATE_DEFAULT) { + if (!version.empty() && version >= AMS_F1_SUPPORT_INSERTION_UPDATE_DEFAULT) { m_checkbox_Insert_material_auto_read->SetValue(true); m_checkbox_Insert_material_auto_read->Hide(); m_title_Insert_material_auto_read->Hide();