From 58a8722a6993de3aff4851137b51102a70dfb7cf Mon Sep 17 00:00:00 2001 From: Noisyfox Date: Thu, 4 Jun 2026 09:02:09 +0800 Subject: [PATCH] Don't show unsupported presets in drop down list (#13959) * Don't show unsupported presets in drop down list, since it's not useful * Add option to show unsupported presets * Explicitly set the default value to `false` * update filament list without restart on preference change --------- Co-authored-by: yw4z --- src/libslic3r/AppConfig.cpp | 3 +++ src/slic3r/GUI/Preferences.cpp | 7 +++++++ src/slic3r/GUI/PresetComboBoxes.cpp | 4 +++- 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/libslic3r/AppConfig.cpp b/src/libslic3r/AppConfig.cpp index 13782fbad2..f8e6d87f6d 100644 --- a/src/libslic3r/AppConfig.cpp +++ b/src/libslic3r/AppConfig.cpp @@ -326,6 +326,9 @@ void AppConfig::set_defaults() if (get("developer_mode").empty()) set_bool("developer_mode", false); + if (get("show_unsupported_presets").empty()) + set_bool("show_unsupported_presets", false); + if (get("enable_ssl_for_mqtt").empty()) set_bool("enable_ssl_for_mqtt", true); diff --git a/src/slic3r/GUI/Preferences.cpp b/src/slic3r/GUI/Preferences.cpp index 8720da84a1..31b3ba95a7 100644 --- a/src/slic3r/GUI/Preferences.cpp +++ b/src/slic3r/GUI/Preferences.cpp @@ -1040,6 +1040,10 @@ wxBoxSizer *PreferencesDialog::create_item_checkbox(wxString title, wxString too } } + if (param == "show_unsupported_presets") { + wxGetApp().plater()->sidebar().update_presets(Preset::TYPE_FILAMENT); + } + if (param == "enable_high_low_temp_mixed_printing") { if (checkbox->GetValue()) { const wxString warning_title = _L("Bed Temperature Difference Warning"); @@ -1874,6 +1878,9 @@ void PreferencesDialog::create_items() auto item_keep_painting = create_item_checkbox(_L("(Experimental) Keep painted feature after mesh change"), _L("Attempt to keep painted features (color/seam/support/fuzzy etc.) after changing the object mesh (such as cut/reload from disk/simplify/fix etc.)\nHighly experimental! Slow and may create artifact."), "keep_painting"); g_sizer->Add(item_keep_painting); + auto item_show_unsupported = create_item_checkbox(_L("Show unsupported presets"), _L("Show incompatible/unsupported presets in the printer and filament dropdown lists. These presets cannot be selected."), "show_unsupported_presets"); + g_sizer->Add(item_show_unsupported); + 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); diff --git a/src/slic3r/GUI/PresetComboBoxes.cpp b/src/slic3r/GUI/PresetComboBoxes.cpp index 70cbd5688a..a2a4422010 100644 --- a/src/slic3r/GUI/PresetComboBoxes.cpp +++ b/src/slic3r/GUI/PresetComboBoxes.cpp @@ -1408,7 +1408,9 @@ void PlaterPresetComboBox::update() add_presets(bundle_presets, selected_bundle_preset, L("Bundle presets"), bundle_group_name); // BBS: move system to the end add_presets(system_presets, selected_system_preset, L("System presets"), _L("System")); - add_presets(uncompatible_presets, {}, L("Unsupported presets"), _L("Unsupported") + " "); + // Orca: optionally show unsupported presets (controlled by developer preference, default off) + if (wxGetApp().app_config->get_bool("show_unsupported_presets")) + add_presets(uncompatible_presets, {}, L("Unsupported presets"), _L("Unsupported") + " "); //BBS: remove unused pysical printer logic /*if (m_type == Preset::TYPE_PRINTER)