Fix filament type parameter box uses wrong width (#9582)

* Update Tab.cpp

* Update Tab.cpp
This commit is contained in:
yw4z 2025-05-09 17:54:35 +03:00 committed by GitHub
parent 9b18c82bfb
commit 2fbfb70994
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -3308,10 +3308,7 @@ void TabFilament::build()
auto page = add_options_page(L("Filament"), "custom-gcode_filament"); // ORCA: icon only visible on placeholders auto page = add_options_page(L("Filament"), "custom-gcode_filament"); // ORCA: icon only visible on placeholders
//BBS //BBS
auto optgroup = page->new_optgroup(L("Basic information"), L"param_information"); auto optgroup = page->new_optgroup(L("Basic information"), L"param_information");
// Set size as all another fields for a better alignment optgroup->append_single_option_line("filament_type"); // ORCA use same width with other elements
Option option = optgroup->get_option("filament_type");
option.opt.width = Field::def_width();
optgroup->append_single_option_line(option);
optgroup->append_single_option_line("filament_vendor"); optgroup->append_single_option_line("filament_vendor");
optgroup->append_single_option_line("filament_soluble"); optgroup->append_single_option_line("filament_soluble");
// BBS // BBS
@ -3356,7 +3353,7 @@ void TabFilament::build()
optgroup->append_single_option_line("adaptive_pressure_advance_overhangs"); optgroup->append_single_option_line("adaptive_pressure_advance_overhangs");
optgroup->append_single_option_line("adaptive_pressure_advance_bridges"); optgroup->append_single_option_line("adaptive_pressure_advance_bridges");
option = optgroup->get_option("adaptive_pressure_advance_model"); Option option = optgroup->get_option("adaptive_pressure_advance_model");
option.opt.full_width = true; option.opt.full_width = true;
option.opt.is_code = true; option.opt.is_code = true;
option.opt.height = 15; option.opt.height = 15;