UI Fixes / Improvements (#12069)

* clone dialog - spin input stuck on selected

* fix advanced toggle label

* fix scrollbar appearing on project page welcome screen

* create slicing section on preferences

* reduce margins on tabs

* bbl part skip dialog

* Update filament_not_mactch.svg

* Update icon_qusetion.svg

* match hyperlink color on notifications

* fix position of notifications on slicing errors

* match background color of BBL > Calibration tab > Sidebar

* match look of BBL sidebars

* match bbl monitor icons

* match multi-device page margins

* bbl > monitor > print control buttons

* fix flush dialog showing text selection on buttons

* Printer network dialog > match combo box width
This commit is contained in:
yw4z
2026-02-04 14:40:02 +03:00
committed by GitHub
parent ea3685aacb
commit d608d7dffe
31 changed files with 63 additions and 133 deletions

View File

@@ -475,7 +475,7 @@ void CalibrationPanel::init_tabpanel() {
m_tabpanel = new Tabbook(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, sizer_side_tools, wxNB_LEFT | wxTAB_TRAVERSAL | wxNB_NOPAGETHEME);
m_side_tools->set_table_panel(m_tabpanel);
m_tabpanel->SetBackgroundColour(*wxWHITE);
m_tabpanel->SetBackgroundColour(wxColour("#FEFFFF")); // ORCA match sidebar background color
m_cali_panels[0] = new PressureAdvanceWizard(m_tabpanel);
m_cali_panels[1] = new FlowRateWizard(m_tabpanel);
@@ -491,11 +491,12 @@ void CalibrationPanel::init_tabpanel() {
selected);
}
for (int i = 0; i < (int)CALI_MODE_COUNT; i++)
m_tabpanel->SetPageImage(i, "");
// ORCA use standard paddings and keep arrow icon for consistent look between sidebars
//for (int i = 0; i < (int)CALI_MODE_COUNT; i++)
// m_tabpanel->SetPageImage(i, "");
auto padding_size = m_tabpanel->GetBtnsListCtrl()->GetPaddingSize(0);
m_tabpanel->GetBtnsListCtrl()->SetPaddingSize({ FromDIP(15), padding_size.y });
//auto padding_size = m_tabpanel->GetBtnsListCtrl()->GetPaddingSize(0);
//m_tabpanel->GetBtnsListCtrl()->SetPaddingSize({ FromDIP(15), padding_size.y });
m_initialized = true;
}

View File

@@ -21,6 +21,11 @@ CloneDialog::CloneDialog(wxWindow *parent)
auto count_label = new wxStaticText(this, wxID_ANY, _L("Number of copies:"), wxDefaultPosition, wxDefaultSize, 0);
m_count_spin = new SpinInput(this, wxEmptyString, "", wxDefaultPosition, wxSize(FromDIP(120), -1), wxSP_ARROW_KEYS, 1, 1000, 1);
m_count_spin->GetTextCtrl()->SetFocus();
m_count_spin->Bind(wxEVT_KILL_FOCUS, [this](wxFocusEvent &e) {
e.SetId(GetId());
ProcessEventLocally(e);
e.Skip();
});
f_sizer->Add(count_label , 0, wxEXPAND | wxALIGN_CENTER_VERTICAL);
f_sizer->Add(m_count_spin, 0, wxALIGN_CENTER_VERTICAL);

View File

@@ -213,7 +213,7 @@ void DailyTipsDataRenderer::render_text(const ImVec2& start_pos, const ImVec2& s
ImVec2 link_start_pos = ImGui::GetCursorScreenPos();
imgui.text(first_part_text);
ImColor HyperColor = ImColor(31, 142, 234, (int)(255 * m_fade_opacity)).Value;
ImColor HyperColor = ImColor(0, 150, 136, (int)(255 * m_fade_opacity)).Value; // ORCA match color of hyperlinks
ImVec2 wiki_part_rect_min = ImVec2(link_start_pos.x + first_part_size.x, link_start_pos.y);
ImVec2 wiki_part_rect_max = wiki_part_rect_min + wiki_part_size;
ImGui::PushStyleColor(ImGuiCol_Text, HyperColor.Value);

View File

@@ -2166,7 +2166,7 @@ void GLCanvas3D::render(bool only_init)
if (m_canvas_type != ECanvasType::CanvasAssembleView) {
float right_margin = SLIDER_DEFAULT_RIGHT_MARGIN;
float bottom_margin = SLIDER_DEFAULT_BOTTOM_MARGIN;
if (m_canvas_type == ECanvasType::CanvasPreview) {
if (m_canvas_type == ECanvasType::CanvasPreview && m_gcode_viewer.has_data()) { // ORCA only shift position of notifiations when sliders / gcode_viewer exist
float scale_factor = get_scale();
#ifdef WIN32
int dpi = get_dpi_for_window(wxGetApp().GetTopWindow());

View File

@@ -494,7 +494,7 @@ MultiMachineManagerPage::MultiMachineManagerPage(wxWindow* parent)
m_main_panel->SetSizer(m_main_sizer);
m_main_panel->Layout();
page_sizer = new wxBoxSizer(wxVERTICAL);
page_sizer->Add(m_main_panel, 1, wxALL | wxEXPAND, FromDIP(25));
page_sizer->Add(m_main_panel, 1, wxALL | wxEXPAND, FromDIP(10)); // ORCA match margin with other tabs
SetSizer(page_sizer);
Layout();

View File

@@ -718,7 +718,7 @@ LocalTaskManagerPage::LocalTaskManagerPage(wxWindow* parent)
m_main_panel->Layout();
page_sizer = new wxBoxSizer(wxVERTICAL);
page_sizer->Add(m_main_panel, 1, wxALL | wxEXPAND, FromDIP(25));
page_sizer->Add(m_main_panel, 1, wxALL | wxEXPAND, FromDIP(10)); // ORCA match margin with other tabs
wxGetApp().UpdateDarkUIWin(this);
@@ -1184,7 +1184,7 @@ CloudTaskManagerPage::CloudTaskManagerPage(wxWindow* parent)
m_main_panel->Layout();
page_sizer = new wxBoxSizer(wxVERTICAL);
page_sizer->Add(m_main_panel, 1, wxALL | wxEXPAND, FromDIP(25));
page_sizer->Add(m_main_panel, 1, wxALL | wxEXPAND, FromDIP(10)); // ORCA match margin with other tabs
Bind(wxEVT_TIMER, &CloudTaskManagerPage::on_timer, this);
wxGetApp().UpdateDarkUIWin(this);

View File

@@ -261,6 +261,7 @@ ParamsPanel::ParamsPanel( wxWindow* parent, wxWindowID id, const wxPoint& pos, c
m_mode_icon = new ScalableButton(m_top_panel, wxID_ANY, "advanced"); // ORCA
m_mode_icon->Bind(wxEVT_BUTTON, [this](wxCommandEvent e) {
if(wxGetApp().get_mode() == comDevelop) return; // prevent change on dev mode
m_mode_view->SetValue(!m_mode_view->GetValue());
wxCommandEvent evt(wxEVT_TOGGLEBUTTON, m_mode_view->GetId()); // ParamsPanel::OnToggled(evt)
evt.SetEventObject(m_mode_view);

View File

@@ -50,18 +50,6 @@ static StateColor zoom_bg(std::pair<wxColour, int>(wxColour(255, 255, 255), Stat
static StateColor zoom_bd(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled), std::pair<wxColour, int>(wxColour(38, 46, 48), StateColor::Enabled));
static StateColor zoom_text(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled), std::pair<wxColour, int>(wxColour(38, 46, 48), StateColor::Enabled));
static StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed),
std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
static StateColor btn_bg_gray(std::pair<wxColour, int>(wxColour(194, 194, 194), StateColor::Pressed),
std::pair<wxColour, int>(wxColour(194, 194, 194), StateColor::Hovered),
std::pair<wxColour, int>(wxColour(194, 194, 194), StateColor::Normal));
static StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(0, 137, 123), StateColor::Pressed),
std::pair<wxColour, int>(wxColour(38, 166, 154), StateColor::Hovered),
std::pair<wxColour, int>(wxColour(0, 150, 136), StateColor::Normal));
PartSkipDialog::PartSkipDialog(wxWindow *parent) : DPIDialog(parent, wxID_ANY, _L("Skip Objects"), wxDefaultPosition, wxDefaultSize, wxCAPTION | wxCLOSE_BOX)
{
std::time_t t = std::time(0);
@@ -69,8 +57,6 @@ PartSkipDialog::PartSkipDialog(wxWindow *parent) : DPIDialog(parent, wxID_ANY, _
buf << put_time(std::localtime(&t), "%a_%b_%d_%H_%M_%S/");
m_timestamp = buf.str();
std::string icon_path = (boost::format("%1%/images/OrcaSlicerTitle.ico") % Slic3r::resources_dir()).str();
SetIcon(wxIcon(Slic3r::encode_path(icon_path.c_str()), wxBITMAP_TYPE_ICO));
SetBackgroundColour(*wxWHITE);
m_sizer = new wxBoxSizer(wxVERTICAL);
@@ -187,13 +173,7 @@ PartSkipDialog::PartSkipDialog(wxWindow *parent) : DPIDialog(parent, wxID_ANY, _
m_tot_label->SetMinSize(wxSize(FromDIP(200), FromDIP(20)));
m_apply_btn = new Button(m_book_third_panel, _L("Skip"));
m_apply_btn->SetBackgroundColor(btn_bg_gray);
m_apply_btn->SetTextColor(wxColour("#FFFFFE"));
// m_apply_btn->SetBorderColor(wxColour(38, 46, 48));
m_apply_btn->SetFont(Label::Body_14);
m_apply_btn->SetSize(wxSize(FromDIP(80), FromDIP(32)));
m_apply_btn->SetMinSize(wxSize(FromDIP(80), FromDIP(32)));
m_apply_btn->SetCornerRadius(FromDIP(16));
m_apply_btn->SetStyle(ButtonStyle::Regular, ButtonType::Choice);
m_apply_btn->SetToolTip(wxEmptyString);
m_canvas_sizer->Add(m_canvas, 0, wxLEFT | wxTOP | wxEXPAND, FromDIP(17));
@@ -251,13 +231,7 @@ PartSkipDialog::PartSkipDialog(wxWindow *parent) : DPIDialog(parent, wxID_ANY, _
m_book_second_sizer->Add(0, 0, 1, wxEXPAND, 0);
m_second_retry_btn = new Button(m_book_second_panel, _L("Retry"));
m_second_retry_btn->SetBackgroundColor(btn_bg_green);
// m_second_retry_btn->SetBorderColor(wxColour(38, 46, 48));
m_second_retry_btn->SetTextColor(*wxWHITE);
m_second_retry_btn->SetFont(Label::Body_14);
m_second_retry_btn->SetSize(wxSize(FromDIP(80), FromDIP(32)));
m_second_retry_btn->SetMinSize(wxSize(FromDIP(80), FromDIP(32)));
m_second_retry_btn->SetCornerRadius(FromDIP(16));
m_second_retry_btn->SetStyle(ButtonStyle::Confirm, ButtonType::Choice);
m_second_retry_btn->Bind(wxEVT_BUTTON, &PartSkipDialog::OnRetryButton, this);
m_book_second_btn_sizer->Add(m_second_retry_btn, 0, wxALL, FromDIP(24));
@@ -343,17 +317,12 @@ void PartSkipDialog::on_dpi_changed(const wxRect &suggested_rect)
m_line->SetMinSize(wxSize(FromDIP(267), 1));
m_line->SetMaxSize(wxSize(FromDIP(267), 1));
m_apply_btn->SetMinSize(wxSize(FromDIP(80), FromDIP(32)));
m_apply_btn->SetCornerRadius(FromDIP(16));
m_apply_btn->Rescale();
m_apply_btn->Rescale(); // ORCA no need to set size again with SetStyle
m_dlg_placeholder->SetMinSize(wxSize(-1, FromDIP(15)));
m_dlg_placeholder->SetMaxSize(wxSize(-1, FromDIP(15)));
// m_second_retry_btn->SetSize(wxSize(-1, FromDIP(32)));
m_second_retry_btn->SetMinSize(wxSize(FromDIP(80), FromDIP(32)));
m_second_retry_btn->SetCornerRadius(FromDIP(16));
m_second_retry_btn->Rescale();
m_second_retry_btn->Rescale(); // ORCA no need to set size again with SetStyle
m_all_checkbox->SetMinSize(wxSize(FromDIP(18), FromDIP(18)));
m_all_checkbox->Rescale();
@@ -883,19 +852,19 @@ void PartSkipDialog::OnAllCheckbox(wxCommandEvent &event)
void PartSkipDialog::UpdateApplyButtonStatus()
{
if (IsAllCancled()) {
m_apply_btn->SetBackgroundColor(btn_bg_gray);
m_apply_btn->SetStyle(ButtonStyle::Regular, ButtonType::Choice);
m_apply_btn->SetToolTip(_L("Nothing selected"));
m_enable_apply_btn = false;
} else if (m_parts_state.size() > 64) {
m_apply_btn->SetBackgroundColor(btn_bg_gray);
m_apply_btn->SetStyle(ButtonStyle::Regular, ButtonType::Choice);
m_apply_btn->SetToolTip(_L("Over 64 objects in single plate"));
m_enable_apply_btn = false;
} else if (!is_model_support_partskip) {
m_apply_btn->SetBackgroundColor(btn_bg_gray);
m_apply_btn->SetStyle(ButtonStyle::Regular, ButtonType::Choice);
m_apply_btn->SetToolTip(_L("The current print job cannot be skipped"));
m_enable_apply_btn = false;
} else {
m_apply_btn->SetBackgroundColor(btn_bg_green);
m_apply_btn->SetStyle(ButtonStyle::Confirm, ButtonType::Choice);
m_apply_btn->SetToolTip(wxEmptyString);
m_enable_apply_btn = true;
}
@@ -955,8 +924,6 @@ int PartSkipDialog::GetAllSkippedPartsNum()
PartSkipConfirmDialog::PartSkipConfirmDialog(wxWindow *parent) : DPIDialog(parent, wxID_ANY, _L("Skip Objects"), wxDefaultPosition, wxDefaultSize, wxCAPTION | wxCLOSE_BOX)
{
std::string icon_path = (boost::format("%1%/images/OrcaSlicerTitle.ico") % Slic3r::resources_dir()).str();
SetIcon(wxIcon(Slic3r::encode_path(icon_path.c_str()), wxBITMAP_TYPE_ICO));
SetBackgroundColour(*wxWHITE);
SetMinSize(wxSize(FromDIP(480), FromDIP(215)));
SetSizeHints(wxDefaultSize, wxDefaultSize);
@@ -989,20 +956,8 @@ PartSkipConfirmDialog::PartSkipConfirmDialog(wxWindow *parent) : DPIDialog(paren
m_button_sizer->SetMinSize(wxSize(FromDIP(480), FromDIP(54)));
m_button_sizer->Add(0, 0, 1, wxEXPAND, 0);
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
std::pair<wxColour, int>(wxColour(0, 177, 66), StateColor::Normal));
m_apply_button = new Button(this, _L("Continue"));
m_apply_button->SetBackgroundColor(btn_bg_green);
m_apply_button->SetTextColor(*wxWHITE);
// m_apply_button->SetBorderColor(wxColour(38, 46, 48));
m_apply_button->SetFont(Label::Body_14);
m_apply_button->SetSize(wxSize(FromDIP(80), FromDIP(32)));
m_apply_button->SetMinSize(wxSize(FromDIP(80), FromDIP(32)));
m_apply_button->SetCornerRadius(FromDIP(16));
m_apply_button->SetStyle(ButtonStyle::Confirm, ButtonType::Choice);
m_apply_button->Bind(wxEVT_BUTTON, [this](auto &e) {
EndModal(wxID_OK);
e.Skip();
@@ -1033,9 +988,7 @@ bool PartSkipConfirmDialog::Show(bool show)
void PartSkipConfirmDialog::on_dpi_changed(const wxRect &suggested_rect)
{
m_apply_button->SetMinSize(wxSize(FromDIP(80), FromDIP(32)));
m_apply_button->SetCornerRadius(FromDIP(16));
m_apply_button->Rescale();
m_apply_button->Rescale(); // ORCA no need to set size again with SetStyle
Layout();
Fit();
}

View File

@@ -160,7 +160,7 @@ void PhysicalPrinterDialog::build_printhost_settings(ConfigOptionsGroup* m_optgr
// (printer_agent is coString in config, but we need a dropdown)
ConfigOptionDef def;
def.type = coEnum;
def.width = Field::def_width();
def.width = Field::def_width_wider();
def.label = L("Printer Agent");
def.tooltip = L("Select the network agent implementation for printer communication. "
"Available agents are registered at startup.");
@@ -315,7 +315,7 @@ void PhysicalPrinterDialog::build_printhost_settings(ConfigOptionsGroup* m_optgr
// For bbl printers, we build a fake option to control whether the original device tab should be used
ConfigOptionDef def;
def.type = coBool;
def.width = Field::def_width();
def.width = Field::def_width_wider();
def.label = L("View print host webui in Device tab");
def.tooltip = L("Replace the BambuLab's device tab with print host webui");
def.set_default_value(new ConfigOptionBool(false));

View File

@@ -1328,11 +1328,17 @@ void PreferencesDialog::create_items()
auto item_auto_arrange = create_item_checkbox(_L("Auto arrange plate after cloning"), "", "auto_arrange");
g_sizer->Add(item_auto_arrange);
//// CONTROL > Slicing
g_sizer->Add(create_item_title(_L("Slicing")), 1, wxEXPAND);
auto item_auto_reslice = create_item_auto_reslice(
_L("Auto slice after changes"),
_L("If enabled, OrcaSlicer will re-slice automatically whenever slicing-related settings change."),
_L("Delay in seconds before auto slicing starts, allowing multiple edits to be grouped. Use 0 to slice immediately."));
g_sizer->Add(item_auto_reslice);
auto item_mix_print_high_low_temperature = create_item_checkbox(_L("Remove mixed temperature restriction"), _L("With this option enabled, you can print materials with a large temperature difference together."), "enable_high_low_temp_mixed_printing");
g_sizer->Add(item_mix_print_high_low_temperature);
//// CONTROL > Camera
g_sizer->Add(create_item_title(_L("Camera")), 1, wxEXPAND);
@@ -1587,9 +1593,6 @@ void PreferencesDialog::create_items()
auto item_ams_blacklist = create_item_checkbox(_L("Skip AMS blacklist check"), "", "skip_ams_blacklist_check");
g_sizer->Add(item_ams_blacklist);
auto item_mix_print_high_low_temperature = create_item_checkbox(_L("Remove mixed temperature restriction"), _L("With this option enabled, you can print materials with a large temperature difference together."), "enable_high_low_temp_mixed_printing");
g_sizer->Add(item_mix_print_high_low_temperature);
g_sizer->Add(create_item_title(_L("Storage")), 1, wxEXPAND);
auto item_allow_abnormal_storage = create_item_checkbox(_L("Allow Abnormal Storage"), _L("This allows the use of Storage that is marked as abnormal by the Printer.\nUse at your own risk, can cause issues!"), "allow_abnormal_storage");
g_sizer->Add(item_allow_abnormal_storage);

View File

@@ -604,7 +604,7 @@ void PrintingTaskPanel::create_panel(wxWindow* parent)
std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Hovered), std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Enabled),
std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Normal));
m_button_partskip = new Button(progress_lr_panel, wxEmptyString, "print_control_partskip_disable", 0, 20, wxID_ANY);
m_button_partskip = new Button(progress_lr_panel, wxEmptyString, "print_control_partskip_disable", 0, 16, wxID_ANY); // ORCA match icon size
m_button_partskip->Enable(false);
m_button_partskip->Hide();
m_button_partskip->SetBackgroundColor(white_bg);

View File

@@ -389,6 +389,7 @@ void Tab::create_preset_tab()
m_mode_icon = new ScalableButton(m_top_panel, wxID_ANY, "advanced"); // ORCA
m_mode_icon->SetToolTip(_L("Show/Hide advanced parameters"));
m_mode_icon->Bind(wxEVT_BUTTON, [this](wxCommandEvent e) {
if(wxGetApp().get_mode() == comDevelop) return; // prevent change on dev mode
m_mode_view->SetValue(!m_mode_view->GetValue());
wxCommandEvent evt(wxEVT_TOGGLEBUTTON, m_mode_view->GetId()); // ParamsPanel::OnToggled(evt)
evt.SetEventObject(m_mode_view);
@@ -7142,7 +7143,7 @@ void Page::activate(ConfigOptionMode mode, std::function<void()> throw_if_cancel
for (auto group : m_optgroups) {
if (!group->activate(throw_if_canceled))
continue;
m_vsizer->Add(group->sizer, 0, wxEXPAND | (group->is_legend_line() ? (wxLEFT|wxTOP) : wxALL), 10);
m_vsizer->Add(group->sizer, 0, wxEXPAND | (group->is_legend_line() ? (wxLEFT|wxTOP) : wxALL), m_parent->FromDIP(5)); // ORCA use less margin on parameters section
group->update_visibility(mode);
#if HIDE_FIRST_SPLIT_LINE
if (first) group->stb->Hide();

View File

@@ -20,7 +20,7 @@ const static wxColour TAB_BUTTON_BG = wxColour("#FEFFFF");
const static wxColour TAB_BUTTON_SEL = wxColour("#BFE1DE"); // ORCA
TabButton::TabButton()
: paddingSize(43, 16)
: paddingSize(18, 16) // ORCA reduce / match left margin buttons on sidebars
, text_color(*wxBLACK)
{
background_color = StateColor(
@@ -163,7 +163,7 @@ void TabButton::render(wxDC &dc)
auto text = GetLabel();
if (!text.IsEmpty()) {
pt.x = paddingSize.x;
pt.x = FromDIP(paddingSize.x); // ORCA match padding on scaling
pt.y = rcContent.y + (rcContent.height - textSize.y) / 2;
dc.SetFont(GetFont());
dc.SetTextForeground(text_color.colorForStates(states));

View File

@@ -204,7 +204,7 @@ void TabButtonsListCtrl::SetFooterText(const wxString& text)
m_footer_text->SetForegroundColour(wxColour(128, 128, 128));
m_footer_text->SetFont(Label::Body_10);
int em = em_unit(this);
m_sizer->Add(m_footer_text, 0, wxALIGN_CENTER_HORIZONTAL | wxBOTTOM, em / 2);
m_sizer->Add(m_footer_text, 0, wxALL, FromDIP(18)); // ORCA reduce / match left margin buttons on sidebars
} else {
m_footer_text->SetLabel(text);
}