v0.9.676
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
#define options_h
|
||||
#pragma once
|
||||
|
||||
#define YOVERSION "0.9.670"
|
||||
#define YOVERSION "0.9.676"
|
||||
|
||||
/*******************************************************
|
||||
DO NOT EDIT THIS FILE.
|
||||
|
||||
@@ -66,6 +66,6 @@ const char bitrateFmt[] PROGMEM = "%d kBs";
|
||||
/* MOVES */ /* { left, top, width } */
|
||||
const MoveConfig clockMove PROGMEM = { 0, 176, -1 };
|
||||
const MoveConfig weatherMove PROGMEM = { 8, 97, MAX_WIDTH };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 70, 97, 250 };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 70, 97, MAX_WIDTH-70+TFT_FRAMEWDT };
|
||||
|
||||
#endif
|
||||
|
||||
@@ -67,6 +67,6 @@ const char bitrateFmt[] PROGMEM = "%d kBs";
|
||||
/* MOVES */ /* { left, top, width } */
|
||||
const MoveConfig clockMove PROGMEM = { 0, 230, -1 };
|
||||
const MoveConfig weatherMove PROGMEM = { 8, 120, MAX_WIDTH };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 89, 120, 381 };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 89, 120, MAX_WIDTH-89+TFT_FRAMEWDT };
|
||||
|
||||
#endif
|
||||
|
||||
@@ -65,6 +65,6 @@ const char bitrateFmt[] PROGMEM = "%d";
|
||||
/* MOVES */ /* { left, top, width (0 - auto, -1 - lock } */
|
||||
const MoveConfig clockMove PROGMEM = { 14, 94, 0};
|
||||
const MoveConfig weatherMove PROGMEM = {TFT_FRAMEWDT, 48, MAX_WIDTH};
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 34, 48, 122 };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 34, 48, MAX_WIDTH-34+TFT_FRAMEWDT };
|
||||
|
||||
#endif
|
||||
|
||||
@@ -69,6 +69,6 @@ const char bitrateFmt[] PROGMEM = "%d kBs";
|
||||
/* MOVES */ /* { left, top, width } */
|
||||
const MoveConfig clockMove PROGMEM = { 8, 180, -1 };
|
||||
const MoveConfig weatherMove PROGMEM = { 8, 97, MAX_WIDTH };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 70, 97, 250 };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 70, 97, MAX_WIDTH-70+TFT_FRAMEWDT };
|
||||
|
||||
#endif
|
||||
|
||||
@@ -67,6 +67,6 @@ const char bitrateFmt[] PROGMEM = "%d kBs";
|
||||
/* MOVES */ /* { left, top, width } */
|
||||
const MoveConfig clockMove PROGMEM = { 0, 176, -1 };
|
||||
const MoveConfig weatherMove PROGMEM = { 8, 120, MAX_WIDTH };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 89, 120, 381 };
|
||||
const MoveConfig weatherMoveVU PROGMEM = { 89, 120, MAX_WIDTH-89+TFT_FRAMEWDT };
|
||||
|
||||
#endif
|
||||
|
||||
@@ -167,14 +167,14 @@ void ScrollWidget::setText(const char* txt) {
|
||||
#ifdef PSFBUFFER
|
||||
_fb->fillRect(0, 0, _width, _textheight, _bgcolor);
|
||||
_fb->setCursor(0, 0);
|
||||
snprintf(_window, _width / _charWidth + 1, "%s", _text); //TODO
|
||||
snprintf(_window, _width / _charWidth + 2, "%s", _text); //TODO
|
||||
_fb->print(_window);
|
||||
_fb->display();
|
||||
#endif
|
||||
} else {
|
||||
dsp.fillRect(_config.left, _config.top, _width, _textheight, _bgcolor);
|
||||
dsp.setCursor(_config.left, _config.top);
|
||||
snprintf(_window, _width / _charWidth + 1, "%s", _text); //TODO
|
||||
snprintf(_window, _width / _charWidth + 2, "%s", _text); //TODO
|
||||
dsp.setClipping({_config.left, _config.top, _width, _textheight});
|
||||
dsp.print(_window);
|
||||
dsp.clearClipping();
|
||||
@@ -235,10 +235,10 @@ void ScrollWidget::_draw() {
|
||||
const char* _cursor = _text + _newx / _charWidth;
|
||||
uint16_t hiddenChars = _cursor - _text;
|
||||
if (hiddenChars < strlen(_text)) {
|
||||
snprintf(_window, _width / _charWidth + 1, "%s%s%s", _cursor, _sep, _text);
|
||||
snprintf(_window, _width / _charWidth + 2, "%s%s%s", _cursor, _sep, _text);
|
||||
} else {
|
||||
const char* _scursor = _sep + (_cursor - (_text + strlen(_text)));
|
||||
snprintf(_window, _width / _charWidth + 1, "%s%s", _scursor, _text);
|
||||
snprintf(_window, _width / _charWidth + 2, "%s%s", _scursor, _text);
|
||||
}
|
||||
if(_fb->ready()){
|
||||
#ifdef PSFBUFFER
|
||||
|
||||
Reference in New Issue
Block a user