Implement crop mode for cover image on sleep screen.

This commit is contained in:
Jonas Diemer
2026-01-03 13:48:46 +01:00
parent 5fdf23f1d2
commit a99ad3b6cd
6 changed files with 44 additions and 16 deletions

View File

@@ -66,7 +66,8 @@ class GfxRenderer {
void drawRect(int x, int y, int width, int height, bool state = true) const;
void fillRect(int x, int y, int width, int height, bool state = true) const;
void drawImage(const uint8_t bitmap[], int x, int y, int width, int height) const;
void drawBitmap(const Bitmap& bitmap, int x, int y, int maxWidth, int maxHeight) const;
void drawBitmap(const Bitmap& bitmap, int x, int y, int maxWidth, int maxHeight, float cropX = 0,
float cropY = 0) const;
// Text
int getTextWidth(int fontId, const char* text, EpdFontFamily::Style style = EpdFontFamily::REGULAR) const;