Tweak FTDI spacing

This commit is contained in:
Scott Lahteine 2020-12-21 17:48:03 -06:00
parent 6429be6efc
commit 34b6bca006
20 changed files with 151 additions and 151 deletions

View File

@ -90,29 +90,29 @@ void AdvancedSettingsMenu::onRedraw(draw_mode_t what) {
cmd.colors(normal_btn)
.font(Theme::font_medium)
.enabled(ENABLED(HAS_BED_PROBE))
.tag(2) .button( ZPROBE_ZOFFSET_POS, GET_TEXT_F(MSG_ZPROBE_ZOFFSET))
.tag(2) .button(ZPROBE_ZOFFSET_POS, GET_TEXT_F(MSG_ZPROBE_ZOFFSET))
.enabled(ENABLED(CASE_LIGHT_ENABLE))
.tag(16).button( CASE_LIGHT_POS, GET_TEXT_F(MSG_CASE_LIGHT))
.tag(3) .button( STEPS_PER_MM_POS, GET_TEXT_F(MSG_STEPS_PER_MM))
.tag(16).button(CASE_LIGHT_POS, GET_TEXT_F(MSG_CASE_LIGHT))
.tag(3) .button(STEPS_PER_MM_POS, GET_TEXT_F(MSG_STEPS_PER_MM))
.enabled(ENABLED(HAS_TRINAMIC_CONFIG))
.tag(13).button( TMC_CURRENT_POS, GET_TEXT_F(MSG_TMC_CURRENT))
.tag(13).button(TMC_CURRENT_POS, GET_TEXT_F(MSG_TMC_CURRENT))
.enabled(ENABLED(SENSORLESS_HOMING))
.tag(14).button( TMC_HOMING_THRS_POS, GET_TEXT_F(MSG_TMC_HOMING_THRS))
.tag(14).button(TMC_HOMING_THRS_POS, GET_TEXT_F(MSG_TMC_HOMING_THRS))
.enabled(ENABLED(HAS_MULTI_HOTEND))
.tag(4) .button( OFFSETS_POS, GET_TEXT_F(MSG_OFFSETS_MENU))
.tag(4) .button(OFFSETS_POS, GET_TEXT_F(MSG_OFFSETS_MENU))
.enabled(EITHER(LIN_ADVANCE, FILAMENT_RUNOUT_SENSOR))
.tag(11).button( FILAMENT_POS, GET_TEXT_F(MSG_FILAMENT))
.tag(12).button( ENDSTOPS_POS, GET_TEXT_F(MSG_LCD_ENDSTOPS))
.tag(15).button( DISPLAY_POS, GET_TEXT_F(MSG_DISPLAY_MENU))
.tag(9) .button( INTERFACE_POS, GET_TEXT_F(MSG_INTERFACE))
.tag(10).button( RESTORE_DEFAULTS_POS, GET_TEXT_F(MSG_RESTORE_DEFAULTS))
.tag(5) .button( VELOCITY_POS, GET_TEXT_F(MSG_VELOCITY))
.tag(6) .button( ACCELERATION_POS, GET_TEXT_F(MSG_ACCELERATION))
.tag(7) .button( JERK_POS, GET_TEXT_F(TERN(HAS_JUNCTION_DEVIATION, MSG_JUNCTION_DEVIATION, MSG_JERK)))
.tag(11).button(FILAMENT_POS, GET_TEXT_F(MSG_FILAMENT))
.tag(12).button(ENDSTOPS_POS, GET_TEXT_F(MSG_LCD_ENDSTOPS))
.tag(15).button(DISPLAY_POS, GET_TEXT_F(MSG_DISPLAY_MENU))
.tag(9) .button(INTERFACE_POS, GET_TEXT_F(MSG_INTERFACE))
.tag(10).button(RESTORE_DEFAULTS_POS, GET_TEXT_F(MSG_RESTORE_DEFAULTS))
.tag(5) .button(VELOCITY_POS, GET_TEXT_F(MSG_VELOCITY))
.tag(6) .button(ACCELERATION_POS, GET_TEXT_F(MSG_ACCELERATION))
.tag(7) .button(JERK_POS, GET_TEXT_F(TERN(HAS_JUNCTION_DEVIATION, MSG_JUNCTION_DEVIATION, MSG_JERK)))
.enabled(ENABLED(BACKLASH_GCODE))
.tag(8).button( BACKLASH_POS, GET_TEXT_F(MSG_BACKLASH))
.tag(8).button(BACKLASH_POS, GET_TEXT_F(MSG_BACKLASH))
.colors(action_btn)
.tag(1).button( BACK_POS, GET_TEXT_F(MSG_BACK));
.tag(1).button(BACK_POS, GET_TEXT_F(MSG_BACK));
}
}

View File

@ -219,7 +219,7 @@ void BaseNumericAdjustmentScreen::widgets_t::adjuster_sram_val(uint8_t tag, prog
.font(font_small)
.text( BTN_POS(1,_line), BTN_SIZE(4,1), label);
_button_style(cmd, TEXT_AREA);
cmd.fgcolor(_color).button( BTN_POS(5,_line), BTN_SIZE(5,1), F(""), OPT_FLAT);
cmd.fgcolor(_color).button(BTN_POS(5,_line), BTN_SIZE(5,1), F(""), OPT_FLAT);
}
cmd.font(font_medium);
@ -282,7 +282,7 @@ void BaseNumericAdjustmentScreen::widgets_t::text_field(uint8_t tag, progmem_str
_button_style(cmd, TEXT_AREA);
cmd.fgcolor(_color)
.tag(tag)
.button( BTN_POS(5,_line), BTN_SIZE(9,1), F(""), OPT_FLAT);
.button(BTN_POS(5,_line), BTN_SIZE(9,1), F(""), OPT_FLAT);
}
if (_what & FOREGROUND) {

View File

@ -250,7 +250,7 @@ void BedMeshScreen::drawHighlightedPointValue() {
.text(Z_LABEL_POS, GET_TEXT_F(MSG_MESH_EDIT_Z))
.text(Z_VALUE_POS, str)
.colors(action_btn)
.tag(1).button( OKAY_POS, GET_TEXT_F(MSG_BUTTON_OKAY))
.tag(1).button(OKAY_POS, GET_TEXT_F(MSG_BUTTON_OKAY))
.tag(0);
switch (screen_data.BedMeshScreen.message) {

View File

@ -43,50 +43,50 @@ void AdvancedSettingsMenu::onRedraw(draw_mode_t what) {
#define GRID_ROWS 9
#define GRID_COLS 2
.tag(2) .button( BTN_POS(1,1), BTN_SIZE(1,1), GET_TEXT_F(MSG_DISPLAY_MENU))
.tag(2) .button(BTN_POS(1,1), BTN_SIZE(1,1), GET_TEXT_F(MSG_DISPLAY_MENU))
.enabled(
#if HAS_TRINAMIC_CONFIG
1
#endif
)
.tag(3) .button( BTN_POS(1,2), BTN_SIZE(1,1), GET_TEXT_F(MSG_TMC_CURRENT))
.tag(3) .button(BTN_POS(1,2), BTN_SIZE(1,1), GET_TEXT_F(MSG_TMC_CURRENT))
.enabled(
#if HAS_TRINAMIC_CONFIG
1
#endif
)
.tag(4) .button( BTN_POS(1,3), BTN_SIZE(1,1), GET_TEXT_F(MSG_TMC_HOMING_THRS))
.tag(5) .button( BTN_POS(1,4), BTN_SIZE(1,1), GET_TEXT_F(MSG_LCD_ENDSTOPS))
.tag(4) .button(BTN_POS(1,3), BTN_SIZE(1,1), GET_TEXT_F(MSG_TMC_HOMING_THRS))
.tag(5) .button(BTN_POS(1,4), BTN_SIZE(1,1), GET_TEXT_F(MSG_LCD_ENDSTOPS))
.enabled(
#if HAS_MULTI_HOTEND
1
#endif
)
.tag(6) .button( BTN_POS(1,5), BTN_SIZE(1,1), GET_TEXT_F(MSG_OFFSETS_MENU))
.tag(6) .button(BTN_POS(1,5), BTN_SIZE(1,1), GET_TEXT_F(MSG_OFFSETS_MENU))
.tag(7) .button( BTN_POS(2,1), BTN_SIZE(1,1), GET_TEXT_F(MSG_STEPS_PER_MM))
.tag(8) .button( BTN_POS(2,2), BTN_SIZE(1,1), GET_TEXT_F(MSG_VELOCITY))
.tag(9) .button( BTN_POS(2,3), BTN_SIZE(1,1), GET_TEXT_F(MSG_ACCELERATION))
.tag(7) .button(BTN_POS(2,1), BTN_SIZE(1,1), GET_TEXT_F(MSG_STEPS_PER_MM))
.tag(8) .button(BTN_POS(2,2), BTN_SIZE(1,1), GET_TEXT_F(MSG_VELOCITY))
.tag(9) .button(BTN_POS(2,3), BTN_SIZE(1,1), GET_TEXT_F(MSG_ACCELERATION))
#if HAS_JUNCTION_DEVIATION
.tag(10) .button( BTN_POS(2,4), BTN_SIZE(1,1), GET_TEXT_F(MSG_JUNCTION_DEVIATION))
.tag(10) .button(BTN_POS(2,4), BTN_SIZE(1,1), GET_TEXT_F(MSG_JUNCTION_DEVIATION))
#else
.tag(10) .button( BTN_POS(2,4), BTN_SIZE(1,1), GET_TEXT_F(MSG_JERK))
.tag(10) .button(BTN_POS(2,4), BTN_SIZE(1,1), GET_TEXT_F(MSG_JERK))
#endif
.enabled(
#if ENABLED(BACKLASH_GCODE)
1
#endif
)
.tag(11) .button( BTN_POS(2,5), BTN_SIZE(1,1), GET_TEXT_F(MSG_BACKLASH))
.tag(11) .button(BTN_POS(2,5), BTN_SIZE(1,1), GET_TEXT_F(MSG_BACKLASH))
.enabled(
#if ENABLED(LIN_ADVANCE)
1
#endif
)
.tag(12) .button( BTN_POS(1,6), BTN_SIZE(2,1), GET_TEXT_F(MSG_LINEAR_ADVANCE))
.tag(13) .button( BTN_POS(1,7), BTN_SIZE(2,1), GET_TEXT_F(MSG_INTERFACE))
.tag(14) .button( BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_RESTORE_DEFAULTS))
.tag(12) .button(BTN_POS(1,6), BTN_SIZE(2,1), GET_TEXT_F(MSG_LINEAR_ADVANCE))
.tag(13) .button(BTN_POS(1,7), BTN_SIZE(2,1), GET_TEXT_F(MSG_INTERFACE))
.tag(14) .button(BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_RESTORE_DEFAULTS))
.colors(action_btn)
.tag(1). button( BTN_POS(1,9), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
#undef GRID_COLS

View File

@ -46,16 +46,16 @@ void MainMenu::onRedraw(draw_mode_t what) {
.font(font_large).text( BTN_POS(1,1), BTN_SIZE(2,1), GET_TEXT_F(MSG_MAIN))
.colors(normal_btn)
.font(font_medium)
.tag(2).button( BTN_POS(1,2), BTN_SIZE(2,1), GET_TEXT_F(MSG_MOVE_TO_HOME))
.tag(3).button( BTN_POS(1,3), BTN_SIZE(2,1), GET_TEXT_F(MSG_RAISE_PLUNGER))
.tag(4).button( BTN_POS(1,4), BTN_SIZE(2,1), GET_TEXT_F(MSG_RELEASE_XY_AXIS))
.tag(5).button( BTN_POS(1,5), BTN_SIZE(2,1), GET_TEXT_F(MSG_AUTOLEVEL_X_AXIS))
.tag(6).button( BTN_POS(1,6), BTN_SIZE(2,1), GET_TEXT_F(MSG_BED_TEMPERATURE))
.tag(7).button( BTN_POS(1,7), BTN_SIZE(2,1), GET_TEXT_F(MSG_INTERFACE))
.tag(8).button( BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_ADVANCED_SETTINGS))
.tag(9).button( BTN_POS(1,9), BTN_SIZE(2,1), GET_TEXT_F(MSG_INFO_MENU))
.tag(2).button(BTN_POS(1,2), BTN_SIZE(2,1), GET_TEXT_F(MSG_MOVE_TO_HOME))
.tag(3).button(BTN_POS(1,3), BTN_SIZE(2,1), GET_TEXT_F(MSG_RAISE_PLUNGER))
.tag(4).button(BTN_POS(1,4), BTN_SIZE(2,1), GET_TEXT_F(MSG_RELEASE_XY_AXIS))
.tag(5).button(BTN_POS(1,5), BTN_SIZE(2,1), GET_TEXT_F(MSG_AUTOLEVEL_X_AXIS))
.tag(6).button(BTN_POS(1,6), BTN_SIZE(2,1), GET_TEXT_F(MSG_BED_TEMPERATURE))
.tag(7).button(BTN_POS(1,7), BTN_SIZE(2,1), GET_TEXT_F(MSG_INTERFACE))
.tag(8).button(BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_ADVANCED_SETTINGS))
.tag(9).button(BTN_POS(1,9), BTN_SIZE(2,1), GET_TEXT_F(MSG_INFO_MENU))
.colors(action_btn)
.tag(1).button( BTN_POS(1,10), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
.tag(1).button(BTN_POS(1,10), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
}
#undef GRID_COLS

View File

@ -81,7 +81,7 @@ void BioPrintingDialogBox::draw_interaction_buttons(draw_mode_t what) {
.enabled(isPrinting() ? TERN0(SDSUPPORT, isPrintingFromMedia()) : 1)
.tag(3)
.colors(isPrinting() ? normal_btn : action_btn)
.button( BTN_POS(2,9), BTN_SIZE(1,1), isPrinting() ? F("Cancel") : F("Back"));
.button(BTN_POS(2,9), BTN_SIZE(1,1), isPrinting() ? F("Cancel") : F("Back"));
}
}

View File

@ -48,14 +48,14 @@ void TuneMenu::onRedraw(draw_mode_t what) {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(font_medium)
.enabled( isPrinting()).tag(2).button( BTN_POS(1,2), BTN_SIZE(2,1), GET_TEXT_F(MSG_PRINT_SPEED))
.tag(3).button( BTN_POS(1,3), BTN_SIZE(2,1), GET_TEXT_F(MSG_BED_TEMPERATURE))
.enabled( isPrinting()).tag(2).button(BTN_POS(1,2), BTN_SIZE(2,1), GET_TEXT_F(MSG_PRINT_SPEED))
.tag(3).button(BTN_POS(1,3), BTN_SIZE(2,1), GET_TEXT_F(MSG_BED_TEMPERATURE))
.enabled(TERN_(BABYSTEPPING, true))
.tag(4).button( BTN_POS(1,4), BTN_SIZE(2,1), GET_TEXT_F(MSG_NUDGE_NOZZLE))
.enabled(!isPrinting()).tag(5).button( BTN_POS(1,5), BTN_SIZE(2,1), GET_TEXT_F(MSG_MOVE_TO_HOME))
.enabled(!isPrinting()).tag(6).button( BTN_POS(1,6), BTN_SIZE(2,1), GET_TEXT_F(MSG_RAISE_PLUNGER))
.enabled(!isPrinting()).tag(7).button( BTN_POS(1,7), BTN_SIZE(2,1), GET_TEXT_F(MSG_RELEASE_XY_AXIS))
.colors(action_btn) .tag(1).button( BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
.tag(4).button(BTN_POS(1,4), BTN_SIZE(2,1), GET_TEXT_F(MSG_NUDGE_NOZZLE))
.enabled(!isPrinting()).tag(5).button(BTN_POS(1,5), BTN_SIZE(2,1), GET_TEXT_F(MSG_MOVE_TO_HOME))
.enabled(!isPrinting()).tag(6).button(BTN_POS(1,6), BTN_SIZE(2,1), GET_TEXT_F(MSG_RAISE_PLUNGER))
.enabled(!isPrinting()).tag(7).button(BTN_POS(1,7), BTN_SIZE(2,1), GET_TEXT_F(MSG_RELEASE_XY_AXIS))
.colors(action_btn) .tag(1).button(BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
}
#undef GRID_COLS
#undef GRID_ROWS

View File

@ -56,22 +56,22 @@ void AdvancedSettingsMenu::onRedraw(draw_mode_t what) {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(Theme::font_medium)
.tag(2) .button( STEPS_PER_MM_POS, GET_TEXT_F(MSG_STEPS_PER_MM))
.tag(2) .button(STEPS_PER_MM_POS, GET_TEXT_F(MSG_STEPS_PER_MM))
.enabled(ENABLED(HAS_TRINAMIC_CONFIG))
.tag(3) .button( TMC_CURRENT_POS, GET_TEXT_F(MSG_TMC_CURRENT))
.tag(3) .button(TMC_CURRENT_POS, GET_TEXT_F(MSG_TMC_CURRENT))
.enabled(ENABLED(LIN_ADVANCE))
.tag(4) .button(LIN_ADVANCE_POS, GET_TEXT_F(MSG_LINEAR_ADVANCE))
.tag(5) .button( VELOCITY_POS, GET_TEXT_F(MSG_VELOCITY))
.tag(6) .button( ACCELERATION_POS, GET_TEXT_F(MSG_ACCELERATION))
.tag(7) .button( JERK_POS, GET_TEXT_F(TERN(HAS_JUNCTION_DEVIATION, MSG_JUNCTION_DEVIATION, MSG_JERK)))
.tag(8) .button( ENDSTOPS_POS, GET_TEXT_F(MSG_LCD_ENDSTOPS))
.tag(9) .button( INTERFACE_POS, GET_TEXT_F(MSG_INTERFACE))
.tag(10).button( DISPLAY_POS, GET_TEXT_F(MSG_DISPLAY_MENU))
.tag(5) .button(VELOCITY_POS, GET_TEXT_F(MSG_VELOCITY))
.tag(6) .button(ACCELERATION_POS, GET_TEXT_F(MSG_ACCELERATION))
.tag(7) .button(JERK_POS, GET_TEXT_F(TERN(HAS_JUNCTION_DEVIATION, MSG_JUNCTION_DEVIATION, MSG_JERK)))
.tag(8) .button(ENDSTOPS_POS, GET_TEXT_F(MSG_LCD_ENDSTOPS))
.tag(9) .button(INTERFACE_POS, GET_TEXT_F(MSG_INTERFACE))
.tag(10).button(DISPLAY_POS, GET_TEXT_F(MSG_DISPLAY_MENU))
.enabled(ENABLED(CASE_LIGHT_ENABLE))
.tag(11).button( CASE_LIGHT_POS, GET_TEXT_F(MSG_CASE_LIGHT))
.tag(12).button( RESTORE_DEFAULTS_POS, GET_TEXT_F(MSG_RESTORE_DEFAULTS))
.tag(11).button(CASE_LIGHT_POS, GET_TEXT_F(MSG_CASE_LIGHT))
.tag(12).button(RESTORE_DEFAULTS_POS, GET_TEXT_F(MSG_RESTORE_DEFAULTS))
.colors(action_btn)
.tag(1).button( BACK_POS, GET_TEXT_F(MSG_BACK));
.tag(1).button(BACK_POS, GET_TEXT_F(MSG_BACK));
}
}

View File

@ -53,16 +53,16 @@ void MainMenu::onRedraw(draw_mode_t what) {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(Theme::font_medium)
.tag(2).button( MOVE_XYZ_POS, GET_TEXT_F(MSG_XYZ_MOVE))
.tag(3).button( TEMPERATURE_POS, GET_TEXT_F(MSG_TEMPERATURE))
.tag(2).button(MOVE_XYZ_POS, GET_TEXT_F(MSG_XYZ_MOVE))
.tag(3).button(TEMPERATURE_POS, GET_TEXT_F(MSG_TEMPERATURE))
.enabled(BOTH(HAS_LEVELING, HAS_BED_PROBE))
.tag(4).button( ZPROBE_ZOFFSET_POS, GET_TEXT_F(MSG_ZPROBE_ZOFFSET))
.tag(5).button( MOVE_E_POS, GET_TEXT_F(MSG_E_MOVE))
.tag(6).button( SPEED_POS, GET_TEXT_F(MSG_PRINT_SPEED))
.tag(7).button( ADVANCED_SETTINGS_POS, GET_TEXT_F(MSG_ADVANCED_SETTINGS))
.tag(8).button( ABOUT_PRINTER_POS, GET_TEXT_F(MSG_INFO_MENU))
.tag(4).button(ZPROBE_ZOFFSET_POS, GET_TEXT_F(MSG_ZPROBE_ZOFFSET))
.tag(5).button(MOVE_E_POS, GET_TEXT_F(MSG_E_MOVE))
.tag(6).button(SPEED_POS, GET_TEXT_F(MSG_PRINT_SPEED))
.tag(7).button(ADVANCED_SETTINGS_POS, GET_TEXT_F(MSG_ADVANCED_SETTINGS))
.tag(8).button(ABOUT_PRINTER_POS, GET_TEXT_F(MSG_INFO_MENU))
.colors(action_btn)
.tag(1).button( BACK_POS, GET_TEXT_F(MSG_BACK));
.tag(1).button(BACK_POS, GET_TEXT_F(MSG_BACK));
}
}

View File

@ -53,16 +53,16 @@ void PreheatMenu::onRedraw(draw_mode_t what) {
CommandProcessor cmd;
cmd.font(Theme::font_medium)
.colors(normal_btn)
.tag(2).button( BTN_POS(1,2), w, h, F("Dark Chocolate"))
.tag(3).button( BTN_POS(1,3), w, h, F("Milk Chocolate"))
.tag(4).button( BTN_POS(1,4), w, h, F("White Chocolate"));
.tag(2).button(BTN_POS(1,2), w, h, F("Dark Chocolate"))
.tag(3).button(BTN_POS(1,3), w, h, F("Milk Chocolate"))
.tag(4).button(BTN_POS(1,4), w, h, F("White Chocolate"));
if (has_extra_heater()) {
cmd.tag(5).button( BTN_POS(2,2), w, h, F("Dark Chocolate"))
.tag(6).button( BTN_POS(2,3), w, h, F("Milk Chocolate"))
.tag(7).button( BTN_POS(2,4), w, h, F("White Chocolate"));
cmd.tag(5).button(BTN_POS(2,2), w, h, F("Dark Chocolate"))
.tag(6).button(BTN_POS(2,3), w, h, F("Milk Chocolate"))
.tag(7).button(BTN_POS(2,4), w, h, F("White Chocolate"));
}
cmd.colors(action_btn)
.tag(1) .button( BTN_POS(1,5), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
.tag(1) .button(BTN_POS(1,5), BTN_SIZE(2,1), GET_TEXT_F(MSG_BACK));
}
}

View File

@ -78,7 +78,7 @@ void PreheatTimerScreen::draw_interaction_buttons(draw_mode_t what) {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(font_medium)
.tag(1).button( BACK_POS, GET_TEXT_F(MSG_BACK));
.tag(1).button(BACK_POS, GET_TEXT_F(MSG_BACK));
}
}
@ -101,7 +101,7 @@ void PreheatTimerScreen::draw_adjuster(draw_mode_t what, uint8_t tag, progmem_st
.font(font_small);
if (what & BACKGROUND) {
cmd.text( SUB_POS(1,1), SUB_SIZE(9,1), label)
.button( SUB_POS(1,2), SUB_SIZE(5,1), F(""), OPT_FLAT);
.button(SUB_POS(1,2), SUB_SIZE(5,1), F(""), OPT_FLAT);
}
if (what & FOREGROUND) {

View File

@ -40,7 +40,7 @@ void DefaultAccelerationScreen::onRedraw(draw_mode_t what) {
w.adjuster( 4, GET_TEXT_F(MSG_ACCEL_TRAVEL), getTravelAcceleration_mm_s2() );
w.adjuster( 6, GET_TEXT_F(MSG_ACCEL_RETRACT), getRetractAcceleration_mm_s2() );
w.increments();
w.button( 8, GET_TEXT_F(MSG_SET_MAXIMUM));
w.button( 8, GET_TEXT_F(MSG_SET_MAXIMUM));
}
bool DefaultAccelerationScreen::onTouchHeld(uint8_t tag) {

View File

@ -57,32 +57,32 @@ void DeveloperMenu::onRedraw(draw_mode_t what) {
#define GRID_COLS 1
cmd.font(font_large) .text ( BTN_POS(1,1), BTN_SIZE(1,1), F("Developer Menu"))
.colors(normal_btn)
.tag(2).font(font_medium) .button( BTN_POS(1,2), BTN_SIZE(1,1), F("Show All Widgets"))
.tag(3) .button( BTN_POS(1,3), BTN_SIZE(1,1), F("Stress Test"))
.tag(4) .button( BTN_POS(1,4), BTN_SIZE(1,1), F("Show Touch Registers"))
.tag(5) .button( BTN_POS(1,5), BTN_SIZE(1,1), F("Play Song"))
.tag(6).enabled(has_media).button( BTN_POS(1,6), BTN_SIZE(1,1), F("Play Video from Media"))
.tag(7).enabled(has_flash).button( BTN_POS(1,7), BTN_SIZE(1,1), F("Play Video from SPI Flash"))
.tag(8).enabled(has_flash).button( BTN_POS(1,8), BTN_SIZE(1,1), F("Load Video to SPI Flash"))
.tag(9).enabled(has_flash).button( BTN_POS(1,9), BTN_SIZE(1,1), F("Erase SPI Flash"))
.tag(2).font(font_medium) .button(BTN_POS(1,2), BTN_SIZE(1,1), F("Show All Widgets"))
.tag(3) .button(BTN_POS(1,3), BTN_SIZE(1,1), F("Stress Test"))
.tag(4) .button(BTN_POS(1,4), BTN_SIZE(1,1), F("Show Touch Registers"))
.tag(5) .button(BTN_POS(1,5), BTN_SIZE(1,1), F("Play Song"))
.tag(6).enabled(has_media).button(BTN_POS(1,6), BTN_SIZE(1,1), F("Play Video from Media"))
.tag(7).enabled(has_flash).button(BTN_POS(1,7), BTN_SIZE(1,1), F("Play Video from SPI Flash"))
.tag(8).enabled(has_flash).button(BTN_POS(1,8), BTN_SIZE(1,1), F("Load Video to SPI Flash"))
.tag(9).enabled(has_flash).button(BTN_POS(1,9), BTN_SIZE(1,1), F("Erase SPI Flash"))
.tag(1).colors(action_btn)
.button( BTN_POS(1,10), BTN_SIZE(1,1), F("Back"));
.button(BTN_POS(1,10), BTN_SIZE(1,1), F("Back"));
#else
#define GRID_ROWS 6
#define GRID_COLS 2
cmd.font(font_medium) .text ( BTN_POS(1,1), BTN_SIZE(2,1), F("Developer Menu"))
.colors(normal_btn)
.tag(2).font(font_small) .button( BTN_POS(1,2), BTN_SIZE(1,1), F("Show All Widgets"))
.tag(3) .button( BTN_POS(1,3), BTN_SIZE(1,1), F("Show Touch Registers"))
.tag(9) .button( BTN_POS(1,4), BTN_SIZE(1,1), F("Show Pin States"))
.tag(4) .button( BTN_POS(1,5), BTN_SIZE(1,1), F("Play Song"))
.tag(5).enabled(has_media).button( BTN_POS(2,2), BTN_SIZE(1,1), F("Play Video from Media"))
.tag(6).enabled(has_flash).button( BTN_POS(2,3), BTN_SIZE(1,1), F("Play Video from SPI Flash"))
.tag(7).enabled(has_flash).button( BTN_POS(2,4), BTN_SIZE(1,1), F("Load Video to SPI Flash"))
.tag(8).enabled(has_flash).button( BTN_POS(2,5), BTN_SIZE(1,1), F("Erase SPI Flash"))
.tag(2).font(font_small) .button(BTN_POS(1,2), BTN_SIZE(1,1), F("Show All Widgets"))
.tag(3) .button(BTN_POS(1,3), BTN_SIZE(1,1), F("Show Touch Registers"))
.tag(9) .button(BTN_POS(1,4), BTN_SIZE(1,1), F("Show Pin States"))
.tag(4) .button(BTN_POS(1,5), BTN_SIZE(1,1), F("Play Song"))
.tag(5).enabled(has_media).button(BTN_POS(2,2), BTN_SIZE(1,1), F("Play Video from Media"))
.tag(6).enabled(has_flash).button(BTN_POS(2,3), BTN_SIZE(1,1), F("Play Video from SPI Flash"))
.tag(7).enabled(has_flash).button(BTN_POS(2,4), BTN_SIZE(1,1), F("Load Video to SPI Flash"))
.tag(8).enabled(has_flash).button(BTN_POS(2,5), BTN_SIZE(1,1), F("Erase SPI Flash"))
.tag(1).colors(action_btn)
.button( BTN_POS(1,6), BTN_SIZE(2,1), F("Back"));
.button(BTN_POS(1,6), BTN_SIZE(2,1), F("Back"));
#endif
}
}

View File

@ -50,20 +50,20 @@ template void DialogBoxBaseClass::drawMessage(progmem_str, int16_t font);
void DialogBoxBaseClass::drawYesNoButtons(uint8_t default_btn) {
CommandProcessor cmd;
cmd.font(font_medium)
.colors(default_btn == 1 ? action_btn : normal_btn).tag(1).button( BTN_POS(1,8), BTN_SIZE(1,1), GET_TEXT_F(MSG_YES))
.colors(default_btn == 2 ? action_btn : normal_btn).tag(2).button( BTN_POS(2,8), BTN_SIZE(1,1), GET_TEXT_F(MSG_NO));
.colors(default_btn == 1 ? action_btn : normal_btn).tag(1).button(BTN_POS(1,8), BTN_SIZE(1,1), GET_TEXT_F(MSG_YES))
.colors(default_btn == 2 ? action_btn : normal_btn).tag(2).button(BTN_POS(2,8), BTN_SIZE(1,1), GET_TEXT_F(MSG_NO));
}
void DialogBoxBaseClass::drawOkayButton() {
CommandProcessor cmd;
cmd.font(font_medium)
.tag(1).button( BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_BUTTON_OKAY));
.tag(1).button(BTN_POS(1,8), BTN_SIZE(2,1), GET_TEXT_F(MSG_BUTTON_OKAY));
}
void DialogBoxBaseClass::drawButton(const progmem_str label) {
CommandProcessor cmd;
cmd.font(font_medium)
.tag(1).button( BTN_POS(1,8), BTN_SIZE(2,1), label);
.tag(1).button(BTN_POS(1,8), BTN_SIZE(2,1), label);
}
void DialogBoxBaseClass::drawSpinner() {

View File

@ -121,7 +121,7 @@ void EndstopStatesScreen::onRedraw(draw_mode_t) {
cmd.font(font_medium)
.colors(action_btn)
.tag(1).button( BTN_POS(1,7), BTN_SIZE(6,1), GET_TEXT_F(MSG_BACK));
.tag(1).button(BTN_POS(1,7), BTN_SIZE(6,1), GET_TEXT_F(MSG_BACK));
#undef GRID_COLS
#undef GRID_ROWS
}

View File

@ -141,11 +141,11 @@ void FilesScreen::drawHeader() {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(font_small)
.tag(0).button( BTN_POS(2,1), BTN_SIZE(4,header_h), str, OPT_CENTER | OPT_FLAT)
.tag(0).button(BTN_POS(2,1), BTN_SIZE(4,header_h), str, OPT_CENTER | OPT_FLAT)
.font(font_medium)
.colors(action_btn)
.tag(241).enabled(prev_enabled).button( BTN_POS(1,1), BTN_SIZE(1,header_h), F("<"))
.tag(242).enabled(next_enabled).button( BTN_POS(6,1), BTN_SIZE(1,header_h), F(">"));
.tag(241).enabled(prev_enabled).button(BTN_POS(1,1), BTN_SIZE(1,header_h), F("<"))
.tag(242).enabled(next_enabled).button(BTN_POS(6,1), BTN_SIZE(1,header_h), F(">"));
}
void FilesScreen::drawFooter() {
@ -167,14 +167,14 @@ void FilesScreen::drawFooter() {
cmd.colors(normal_btn)
.font(font_medium)
.colors(has_selection ? normal_btn : action_btn)
.tag(back_tag).button( BTN_POS(4,y), BTN_SIZE(3,h), GET_TEXT_F(MSG_BACK))
.tag(back_tag).button(BTN_POS(4,y), BTN_SIZE(3,h), GET_TEXT_F(MSG_BACK))
.enabled(has_selection)
.colors(has_selection ? action_btn : normal_btn);
if (screen_data.FilesScreen.flags.is_dir)
cmd.tag(244).button( BTN_POS(1, y), BTN_SIZE(3,h), GET_TEXT_F(MSG_BUTTON_OPEN));
cmd.tag(244).button(BTN_POS(1, y), BTN_SIZE(3,h), GET_TEXT_F(MSG_BUTTON_OPEN));
else
cmd.tag(243).button( BTN_POS(1, y), BTN_SIZE(3,h), GET_TEXT_F(MSG_BUTTON_PRINT));
cmd.tag(243).button(BTN_POS(1, y), BTN_SIZE(3,h), GET_TEXT_F(MSG_BUTTON_PRINT));
}
void FilesScreen::onRedraw(draw_mode_t what) {

View File

@ -69,20 +69,20 @@ void MainMenu::onRedraw(draw_mode_t what) {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(Theme::font_medium)
.tag( 2).button( AUTO_HOME_POS, GET_TEXT_F(MSG_AUTO_HOME))
.tag( 2).button(AUTO_HOME_POS, GET_TEXT_F(MSG_AUTO_HOME))
.enabled(ENABLED(NOZZLE_CLEAN_FEATURE))
.tag( 3).button( CLEAN_NOZZLE_POS, GET_TEXT_F(MSG_CLEAN_NOZZLE))
.tag( 4).button( MOVE_AXIS_POS, GET_TEXT_F(MSG_MOVE_AXIS))
.tag( 5).button( DISABLE_STEPPERS_POS,GET_TEXT_F(MSG_DISABLE_STEPPERS))
.tag( 6).button( TEMPERATURE_POS, GET_TEXT_F(MSG_TEMPERATURE))
.tag( 3).button(CLEAN_NOZZLE_POS, GET_TEXT_F(MSG_CLEAN_NOZZLE))
.tag( 4).button(MOVE_AXIS_POS, GET_TEXT_F(MSG_MOVE_AXIS))
.tag( 5).button(DISABLE_STEPPERS_POS,GET_TEXT_F(MSG_DISABLE_STEPPERS))
.tag( 6).button(TEMPERATURE_POS, GET_TEXT_F(MSG_TEMPERATURE))
.enabled(IF_DISABLED(TOUCH_UI_LULZBOT_BIO, 1))
.tag( 7).button( FILAMENTCHANGE_POS, GET_TEXT_F(MSG_FILAMENTCHANGE))
.tag( 8).button( ADVANCED_SETTINGS_POS, GET_TEXT_F(MSG_ADVANCED_SETTINGS))
.tag( 7).button(FILAMENTCHANGE_POS, GET_TEXT_F(MSG_FILAMENTCHANGE))
.tag( 8).button(ADVANCED_SETTINGS_POS, GET_TEXT_F(MSG_ADVANCED_SETTINGS))
.enabled(TERN_(HAS_LEVELING, 1))
.tag( 9).button( LEVELING_POS, GET_TEXT_F(MSG_LEVELING))
.tag(10).button( ABOUT_PRINTER_POS, GET_TEXT_F(MSG_INFO_MENU))
.tag( 9).button(LEVELING_POS, GET_TEXT_F(MSG_LEVELING))
.tag(10).button(ABOUT_PRINTER_POS, GET_TEXT_F(MSG_INFO_MENU))
.colors(action_btn)
.tag(1).button( BACK_POS, GET_TEXT_F(MSG_BACK));
.tag(1).button(BACK_POS, GET_TEXT_F(MSG_BACK));
}
}

View File

@ -66,13 +66,13 @@ void StatusScreen::draw_axis_position(draw_mode_t what) {
cmd.tag(6)
.fgcolor(Theme::axis_label)
.font(Theme::font_large)
.button( UNION_POS(X_LBL_POS, X_VAL_POS), F(""), OPT_FLAT)
.button( UNION_POS(Y_LBL_POS, Y_VAL_POS), F(""), OPT_FLAT)
.button( UNION_POS(Z_LBL_POS, Z_VAL_POS), F(""), OPT_FLAT)
.button(UNION_POS(X_LBL_POS, X_VAL_POS), F(""), OPT_FLAT)
.button(UNION_POS(Y_LBL_POS, Y_VAL_POS), F(""), OPT_FLAT)
.button(UNION_POS(Z_LBL_POS, Z_VAL_POS), F(""), OPT_FLAT)
.font(Theme::font_medium)
.fgcolor(Theme::x_axis) .button( X_VAL_POS, F(""), OPT_FLAT)
.fgcolor(Theme::y_axis) .button( Y_VAL_POS, F(""), OPT_FLAT)
.fgcolor(Theme::z_axis) .button( Z_VAL_POS, F(""), OPT_FLAT)
.fgcolor(Theme::x_axis) .button(X_VAL_POS, F(""), OPT_FLAT)
.fgcolor(Theme::y_axis) .button(Y_VAL_POS, F(""), OPT_FLAT)
.fgcolor(Theme::z_axis) .button(Z_VAL_POS, F(""), OPT_FLAT)
.font(Theme::font_small)
.text ( X_LBL_POS, GET_TEXT_F(MSG_AXIS_X))
.text ( Y_LBL_POS, GET_TEXT_F(MSG_AXIS_Y))
@ -137,9 +137,9 @@ void StatusScreen::draw_temperature(draw_mode_t what) {
if (what & BACKGROUND) {
cmd.font(Theme::font_small)
.tag(5)
.fgcolor(temp) .button( TEMP_RECT_1, F(""), OPT_FLAT)
.button( TEMP_RECT_2, F(""), OPT_FLAT)
.fgcolor(fan_speed).button( FAN_POS, F(""), OPT_FLAT)
.fgcolor(temp) .button(TEMP_RECT_1, F(""), OPT_FLAT)
.button(TEMP_RECT_2, F(""), OPT_FLAT)
.fgcolor(fan_speed).button(FAN_POS, F(""), OPT_FLAT)
.tag(0);
// Draw Extruder Bitmap on Extruder Temperature Button
@ -269,7 +269,7 @@ void StatusScreen::draw_interaction_buttons(draw_mode_t what) {
.enabled(has_media)
.tag(3).button(MEDIA_BTN_POS, isPrintingFromMedia() ? GET_TEXT_F(MSG_PRINTING) : GET_TEXT_F(MSG_BUTTON_MEDIA))
.colors(!has_media ? action_btn : normal_btn)
.tag(4).button( MENU_BTN_POS, GET_TEXT_F(MSG_BUTTON_MENU));
.tag(4).button(MENU_BTN_POS, GET_TEXT_F(MSG_BUTTON_MENU));
}
#undef GRID_COLS
}
@ -287,7 +287,7 @@ void StatusScreen::draw_status_message(draw_mode_t what, const char* message) {
CommandProcessor cmd;
cmd.fgcolor(Theme::status_msg)
.tag(0)
.button( STATUS_POS, F(""), OPT_FLAT);
.button(STATUS_POS, F(""), OPT_FLAT);
draw_text_box(cmd, STATUS_POS, message, OPT_CENTER, font_large);
}

View File

@ -47,19 +47,19 @@ void TouchRegistersScreen::onRedraw(draw_mode_t) {
#define GRID_COLS 2
cmd.tag(0)
.font(font_xsmall)
.fgcolor(transformA) .button( BTN_POS(1,1), BTN_SIZE(1,1), F("TOUCH_XFORM_A"))
.fgcolor(transformB) .button( BTN_POS(1,2), BTN_SIZE(1,1), F("TOUCH_XFORM_B"))
.fgcolor(transformC) .button( BTN_POS(1,3), BTN_SIZE(1,1), F("TOUCH_XFORM_C"))
.fgcolor(transformD) .button( BTN_POS(1,4), BTN_SIZE(1,1), F("TOUCH_XFORM_D"))
.fgcolor(transformE) .button( BTN_POS(1,5), BTN_SIZE(1,1), F("TOUCH_XFORM_E"))
.fgcolor(transformF) .button( BTN_POS(1,6), BTN_SIZE(1,1), F("TOUCH_XFORM_F"))
.fgcolor(transformA) .button(BTN_POS(1,1), BTN_SIZE(1,1), F("TOUCH_XFORM_A"))
.fgcolor(transformB) .button(BTN_POS(1,2), BTN_SIZE(1,1), F("TOUCH_XFORM_B"))
.fgcolor(transformC) .button(BTN_POS(1,3), BTN_SIZE(1,1), F("TOUCH_XFORM_C"))
.fgcolor(transformD) .button(BTN_POS(1,4), BTN_SIZE(1,1), F("TOUCH_XFORM_D"))
.fgcolor(transformE) .button(BTN_POS(1,5), BTN_SIZE(1,1), F("TOUCH_XFORM_E"))
.fgcolor(transformF) .button(BTN_POS(1,6), BTN_SIZE(1,1), F("TOUCH_XFORM_F"))
.fgcolor(transformVal).button( BTN_POS(2,1), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button( BTN_POS(2,2), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button( BTN_POS(2,3), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button( BTN_POS(2,4), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button( BTN_POS(2,5), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button( BTN_POS(2,6), BTN_SIZE(1,1), F(""), OPT_FLAT);
.fgcolor(transformVal).button(BTN_POS(2,1), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button(BTN_POS(2,2), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button(BTN_POS(2,3), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button(BTN_POS(2,4), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button(BTN_POS(2,5), BTN_SIZE(1,1), F(""), OPT_FLAT)
.fgcolor(transformVal).button(BTN_POS(2,6), BTN_SIZE(1,1), F(""), OPT_FLAT);
sprintf_P(b, PSTR("0x%08lX"), T_Transform_A); cmd.text( BTN_POS(2,1), BTN_SIZE(1,1), b);
sprintf_P(b, PSTR("0x%08lX"), T_Transform_B); cmd.text( BTN_POS(2,2), BTN_SIZE(1,1), b);
@ -69,7 +69,7 @@ void TouchRegistersScreen::onRedraw(draw_mode_t) {
sprintf_P(b, PSTR("0x%08lX"), T_Transform_F); cmd.text( BTN_POS(2,6), BTN_SIZE(1,1), b);
cmd.colors(action_btn).font(font_medium)
.tag(1).button( BTN_POS(2,7), BTN_SIZE(1,1), F("Back"));
.tag(1).button(BTN_POS(2,7), BTN_SIZE(1,1), F("Back"));
#undef GRID_COLS
#undef GRID_ROWS
}

View File

@ -71,23 +71,23 @@ void TuneMenu::onRedraw(draw_mode_t what) {
CommandProcessor cmd;
cmd.colors(normal_btn)
.font(font_medium)
.tag(2).button( TEMPERATURE_POS, GET_TEXT_F(MSG_TEMPERATURE))
.tag(2).button(TEMPERATURE_POS, GET_TEXT_F(MSG_TEMPERATURE))
.enabled(!sdOrHostPrinting || sdOrHostPaused)
.tag(3).button( FIL_CHANGE_POS, GET_TEXT_F(MSG_FILAMENTCHANGE))
.tag(3).button(FIL_CHANGE_POS, GET_TEXT_F(MSG_FILAMENTCHANGE))
.enabled(EITHER(LIN_ADVANCE, FILAMENT_RUNOUT_SENSOR))
.tag(9).button( FILAMENT_POS, GET_TEXT_F(MSG_FILAMENT))
.tag(9).button(FILAMENT_POS, GET_TEXT_F(MSG_FILAMENT))
.enabled(BOTH(HAS_LEVELING, HAS_BED_PROBE) || ENABLED(BABYSTEPPING))
.tag(4).button( NUDGE_NOZ_POS, GET_TEXT_F(TERN(BABYSTEPPING, MSG_NUDGE_NOZZLE, MSG_ZPROBE_ZOFFSET)))
.tag(5).button( SPEED_POS, GET_TEXT_F(MSG_PRINT_SPEED))
.tag(4).button(NUDGE_NOZ_POS, GET_TEXT_F(TERN(BABYSTEPPING, MSG_NUDGE_NOZZLE, MSG_ZPROBE_ZOFFSET)))
.tag(5).button(SPEED_POS, GET_TEXT_F(MSG_PRINT_SPEED))
.enabled(sdOrHostPrinting)
.tag(sdOrHostPaused ? 7 : 6)
.button( PAUSE_POS, sdOrHostPaused ? GET_TEXT_F(MSG_RESUME_PRINT) : GET_TEXT_F(MSG_PAUSE_PRINT))
.button(PAUSE_POS, sdOrHostPaused ? GET_TEXT_F(MSG_RESUME_PRINT) : GET_TEXT_F(MSG_PAUSE_PRINT))
.enabled(sdOrHostPrinting)
.tag(8).button( STOP_POS, GET_TEXT_F(MSG_STOP_PRINT))
.tag(8).button(STOP_POS, GET_TEXT_F(MSG_STOP_PRINT))
.enabled(ENABLED(CASE_LIGHT_ENABLE))
.tag(10).button( CASE_LIGHT_POS, GET_TEXT_F(MSG_CASE_LIGHT))
.tag(10).button(CASE_LIGHT_POS, GET_TEXT_F(MSG_CASE_LIGHT))
.tag(1).colors(action_btn)
.button( BACK_POS, GET_TEXT_F(MSG_BACK));
.button(BACK_POS, GET_TEXT_F(MSG_BACK));
}
#undef GRID_COLS
#undef GRID_ROWS