#405 #340 rtu and supervisor configurator control of theme and color mode

This commit is contained in:
Mikayla Fischler
2024-03-07 19:23:46 -05:00
parent 48a8eadc55
commit fc7896ebd3
16 changed files with 373 additions and 62 deletions

View File

@@ -19,11 +19,15 @@ local ui = {
}
-- try to start the UI
---@param theme integer front panel theme ID (1 = sandstone, 2 = basalt)
---@return boolean success, any error_msg
function renderer.try_start_ui()
function renderer.try_start_ui(theme)
local status, msg = true, nil
if ui.display == nil then
-- set theme
style.set_theme(theme)
-- reset terminal
term.setTextColor(colors.white)
term.setBackgroundColor(colors.black)