| 1 | #include "scrollableTextArea.h" |
| 2 | #define _scrollBuffer tft |
| 3 | ScrollableTextArea::ScrollableTextArea(const String &title) |
| 4 | : firstVisibleLine{0}, _redraw{true}, _title(title), _fontSize(FP), _startX(BORDER_PAD_X), |
| 5 | _startY(BORDER_PAD_Y), _width(tftWidth - 2 * BORDER_PAD_X), |
| 6 | _height(tftHeight - BORDER_PAD_X - BORDER_PAD_Y) { |
| 7 | drawMainBorder(); |
| 8 | |
| 9 | if (!_title.isEmpty()) { |
| 10 | printTitle(_title); |
| 11 | _startY = tft.getCursorY(); |
| 12 | _height -= (_startY - BORDER_PAD_Y); |
| 13 | } |
| 14 | |
| 15 | setup(); |
| 16 | } |
| 17 | |
| 18 | ScrollableTextArea::ScrollableTextArea( |
| 19 | uint8_t fontSize, int16_t startX, int16_t startY, int32_t width, int32_t height, bool drawBorders, |
nothing calls this directly
no test coverage detected