feat(colorlcd): Value widget text alignment options (#3080)

* Adds option to align value widget label and value to left, center or right border of the widget zone.

* Cpn sync

* Typofix thx to @Eldenroot

* fix: Add `TW` translation

* fix: Two spaces for indent

---------

Co-authored-by: elecpower <neilh713@tpg.com.au>
This commit is contained in:
Risto
2023-02-20 14:57:58 +10:00
committed by GitHub
co-authored by elecpower
parent 688addd5d2
commit 97c57cf9ee
24 changed files with 538 additions and 368 deletions
+2 -1
View File
@@ -162,7 +162,8 @@ ZoneOption *createOptionsArray(int reference, uint8_t maxOptions)
option->deflt.signedValue = lua_tointeger(lsWidgets, -1);
// TRACE("default signed = %d", option->deflt.signedValue);
} else if (option->type == ZoneOption::Source ||
option->type == ZoneOption::TextSize) {
option->type == ZoneOption::TextSize ||
option->type == ZoneOption::Align) {
luaL_checktype(lsWidgets, -1, LUA_TNUMBER); // value is number
option->deflt.unsignedValue = lua_tounsigned(lsWidgets, -1);
// TRACE("default unsigned = %u", option->deflt.unsignedValue);