diff --git a/src/slic3r/GUI/Tab.cpp b/src/slic3r/GUI/Tab.cpp index e8f0a5efb..2fc54465a 100644 --- a/src/slic3r/GUI/Tab.cpp +++ b/src/slic3r/GUI/Tab.cpp @@ -2351,10 +2351,13 @@ void TabPrinter::build_fff() } } if (opt_key == "gcode_flavor") { - bool supports_travel_acceleration = (boost::any_cast(value) == int(gcfMarlinFirmware)) || (boost::any_cast(value) == int(gcfRepRapFirmware)); - if (supports_travel_acceleration != m_supports_travel_acceleration) { + const int flavor = boost::any_cast(value); + bool supports_travel_acceleration = (flavor == int(gcfMarlinFirmware) || flavor == int(gcfRepRapFirmware)); + bool supports_min_feedrates = (flavor == int(gcfMarlinFirmware) || flavor == int(gcfMarlinLegacy)); + if (supports_travel_acceleration != m_supports_travel_acceleration || supports_min_feedrates != m_supports_min_feedrates) { m_rebuild_kinematics_page = true; m_supports_travel_acceleration = supports_travel_acceleration; + m_supports_min_feedrates = supports_min_feedrates; } } build_unregular_pages(); @@ -2639,9 +2642,11 @@ PageShp TabPrinter::build_kinematics_page() append_option_line(optgroup, "machine_max_jerk_" + axis); } - optgroup = page->new_optgroup(L("Minimum feedrates")); - append_option_line(optgroup, "machine_min_extruding_rate"); - append_option_line(optgroup, "machine_min_travel_rate"); + if (m_supports_min_feedrates) { + optgroup = page->new_optgroup(L("Minimum feedrates")); + append_option_line(optgroup, "machine_min_extruding_rate"); + append_option_line(optgroup, "machine_min_travel_rate"); + } return page; } @@ -3031,10 +3036,13 @@ void TabPrinter::update_fff() m_use_silent_mode = m_config->opt_bool("silent_mode"); } - bool supports_travel_acceleration = (m_config->option>("gcode_flavor")->value == gcfMarlinFirmware || m_config->option>("gcode_flavor")->value == gcfRepRapFirmware); - if (m_supports_travel_acceleration != supports_travel_acceleration) { + const auto flavor = m_config->option>("gcode_flavor")->value; + bool supports_travel_acceleration = (flavor == gcfMarlinFirmware || flavor == gcfRepRapFirmware); + bool supports_min_feedrates = (flavor == gcfMarlinFirmware || flavor == gcfMarlinLegacy); + if (m_supports_travel_acceleration != supports_travel_acceleration || m_supports_min_feedrates != supports_min_feedrates) { m_rebuild_kinematics_page = true; m_supports_travel_acceleration = supports_travel_acceleration; + m_supports_min_feedrates = supports_min_feedrates; } toggle_options(); diff --git a/src/slic3r/GUI/Tab.hpp b/src/slic3r/GUI/Tab.hpp index 38e142591..e8d939cf7 100644 --- a/src/slic3r/GUI/Tab.hpp +++ b/src/slic3r/GUI/Tab.hpp @@ -421,6 +421,7 @@ private: bool m_has_single_extruder_MM_page = false; bool m_use_silent_mode = false; bool m_supports_travel_acceleration = false; + bool m_supports_min_feedrates = false; void append_option_line(ConfigOptionsGroupShp optgroup, const std::string opt_key); bool m_rebuild_kinematics_page = false; ogStaticText* m_machine_limits_description_line {nullptr};