Skip to content

Commit 1178bb8

Browse files
committed
Fix: Artifacts when writing second line > chars than first
1 parent 4fe998a commit 1178bb8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/components/display/drivers/dispDrvSt7789.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,8 +245,9 @@ class dispDrvSt7789 : public dispDrvBase {
245245
return;
246246

247247
// Clear only the area below the status bar
248-
_display->fillRect(0, ST7789_STATUSBAR_HEIGHT, _width,
249-
_height - ST7789_STATUSBAR_HEIGHT, ST77XX_BLACK);
248+
_display->fillRect(0, ST7789_STATUSBAR_HEIGHT, _display->width(),
249+
_display->height() - ST7789_STATUSBAR_HEIGHT,
250+
ST77XX_BLACK);
250251
int16_t y_idx = ST7789_STATUSBAR_HEIGHT;
251252

252253
// Calculate the line height based on the text size (NOTE: base height is

0 commit comments

Comments
 (0)