UI fixes / improvements (#11617)

* fix margins on titlebar fold

* update

* Update Plater.cpp

* update

* Update toolbar_double_directional_arrow.svg

* Update toolbar_double_directional_arrow.svg

* object list variable height icon

* Update tab_multi_active.svg

* update ams icons

* match popup border color

* Update param_advanced.svg

* Update custom-gcode_advanced.svg

* match label & parameter box width on object table

* revert changes for orange colors

* match sizes of radio buttons on widgets

* Update GLGizmoSVG.cpp
This commit is contained in:
yw4z
2025-12-18 15:17:29 +03:00
committed by GitHub
parent 00ff06a5d3
commit 22d2fe9b37
46 changed files with 195 additions and 200 deletions

View File

@@ -936,7 +936,7 @@ public:
Bind(wxEVT_PAINT, [this](wxPaintEvent& evt) {
wxPaintDC dc(this);
dc.SetPen(wxColour("#EEEEEE"));
dc.SetPen(StateColor::darkModeColorFor(wxColour("#DBDBDB"))); // ORCA match popup border color
dc.SetBrush(*wxTRANSPARENT_BRUSH);
dc.DrawRoundedRectangle(0, 0, GetSize().x, GetSize().y, 0);
});
@@ -1636,8 +1636,8 @@ Sidebar::Sidebar(Plater *parent)
h_sizer_title->AddSpacer(FromDIP(SidebarProps::ElementSpacing()));
h_sizer_title->Add(p->m_text_printer_settings, 0, wxALIGN_CENTER);
h_sizer_title->AddStretchSpacer();
h_sizer_title->Add(p->m_printer_connect , 0, wxALIGN_CENTER | wxRIGHT, FromDIP(20)); // used larger margin to prevent accidental clicks
h_sizer_title->Add(p->m_printer_bbl_sync, 0, wxALIGN_CENTER | wxRIGHT, FromDIP(20)); // used larger margin to prevent accidental clicks
h_sizer_title->Add(p->m_printer_connect , 0, wxALIGN_CENTER | wxRIGHT, FromDIP(SidebarProps::WideSpacing())); // used larger margin to prevent accidental clicks
h_sizer_title->Add(p->m_printer_bbl_sync, 0, wxALIGN_CENTER | wxRIGHT, FromDIP(SidebarProps::WideSpacing())); // used larger margin to prevent accidental clicks
h_sizer_title->Add(p->m_printer_setting, 0, wxALIGN_CENTER);
h_sizer_title->AddSpacer(FromDIP(SidebarProps::TitlebarMargin()));
h_sizer_title->SetMinSize(-1, 3 * em);
@@ -1654,10 +1654,7 @@ Sidebar::Sidebar(Plater *parent)
// add printer title
scrolled_sizer->Add(p->m_panel_printer_title, 0, wxEXPAND | wxALL, 0);
p->m_panel_printer_title->Bind(wxEVT_LEFT_UP, [this] (auto & e) {
if (p->m_panel_printer_content->GetMaxHeight() == 0)
p->m_panel_printer_content->SetMaxSize({-1, -1});
else
p->m_panel_printer_content->SetMaxSize({-1, 0});
p->m_panel_printer_content->Show(!p->m_panel_printer_content->IsShown());
m_scrolled_sizer->Layout();
});
@@ -1987,16 +1984,7 @@ Sidebar::Sidebar(Plater *parent)
if (e.GetPosition().x > (p->m_flushing_volume_btn->IsShown()
? p->m_flushing_volume_btn->GetPosition().x : (p->m_bpButton_add_filament->GetPosition().x - FromDIP(30)))) // ORCA exclude area of del button from titlebar collapse/expand feature to fix undesired collapse when user spams del filament button
return;
if (p->m_panel_filament_content->GetMaxHeight() == 0) {
p->m_panel_filament_content->SetMaxSize({-1, FromDIP(174)});
auto min_size = p->m_panel_filament_content->GetSizer()->GetMinSize();
if (min_size.y > p->m_panel_filament_content->GetMaxHeight())
min_size.y = p->m_panel_filament_content->GetMaxHeight();
p->m_panel_filament_content->SetMinSize({-1, min_size.y});
} else {
p->m_panel_filament_content->SetMinSize({-1, 0});
p->m_panel_filament_content->SetMaxSize({-1, 0});
}
p->m_panel_filament_content->Show(!p->m_panel_filament_content->IsShown());
m_scrolled_sizer->Layout();
});
@@ -2038,7 +2026,7 @@ Sidebar::Sidebar(Plater *parent)
}));
bSizer39->Add(p->m_flushing_volume_btn, 0, wxALIGN_CENTER_VERTICAL | wxLEFT, FromDIP(4));
bSizer39->Hide(p->m_flushing_volume_btn);
bSizer39->Hide(p->m_flushing_volume_btn); // ORCA Ensure button is hidden on launch while 1 filament exist
ScalableButton* add_btn = new ScalableButton(p->m_panel_filament_title, wxID_ANY, "add_filament");
add_btn->SetToolTip(_L("Add one filament"));
@@ -2058,12 +2046,8 @@ Sidebar::Sidebar(Plater *parent)
bSizer39->Add(del_btn, 0, wxALIGN_CENTER | wxLEFT, FromDIP(SidebarProps::IconSpacing()));
bSizer39->Add(add_btn, 0, wxALIGN_CENTER | wxLEFT, FromDIP(SidebarProps::IconSpacing())); // ORCA Moved add button after delete button to prevent add button position change when remove icon automatically hidden
bSizer39->AddSpacer(FromDIP(20));
if (p->combos_filament.size() <= 1) { // ORCA Fix Flushing button and Delete filament button not hidden on launch while only 1 filament exist
bSizer39->Hide(p->m_flushing_volume_btn);
//bSizer39->Hide(p->m_bpButton_del_filament); // ORCA: Hide delete filament button if there is only one filament
}
bSizer39->Hide(p->m_bpButton_del_filament); // ORCA Ensure button is hidden on launch while 1 filament exist
ams_btn = new ScalableButton(p->m_panel_filament_title, wxID_ANY, "ams_fila_sync", wxEmptyString, wxDefaultSize, wxDefaultPosition,
wxBU_EXACTFIT | wxNO_BORDER, false, 16); // ORCA match icon size with other icons as 16x16
@@ -2075,7 +2059,7 @@ Sidebar::Sidebar(Plater *parent)
ams_btn->Bind(wxEVT_UPDATE_UI, &Sidebar::update_sync_ams_btn_enable, this);
p->m_bpButton_ams_filament = ams_btn;
bSizer39->Add(ams_btn, 0, wxALIGN_CENTER | wxLEFT, FromDIP(SidebarProps::IconSpacing()));
bSizer39->Add(ams_btn, 0, wxALIGN_CENTER | wxLEFT, FromDIP(SidebarProps::WideSpacing()));
//bSizer39->Add(FromDIP(10), 0, 0, 0, 0 );
ScalableButton* set_btn = new ScalableButton(p->m_panel_filament_title, wxID_ANY, "settings");
@@ -2088,7 +2072,7 @@ Sidebar::Sidebar(Plater *parent)
});
p->m_bpButton_set_filament = set_btn;
bSizer39->Add(set_btn, 0, wxALIGN_CENTER | wxLEFT, FromDIP(SidebarProps::IconSpacing()));
bSizer39->Add(set_btn, 0, wxALIGN_CENTER | wxLEFT, FromDIP(SidebarProps::WideSpacing()));
bSizer39->AddSpacer(FromDIP(SidebarProps::TitlebarMargin()));
// add filament content