1
0
forked from me/IronOS

Number Bounded draw

This commit is contained in:
Ben V. Brown
2023-06-29 18:46:19 +10:00
parent da7dbd4b55
commit 45639e5c23
2 changed files with 43 additions and 10 deletions

View File

@@ -101,10 +101,13 @@ public:
static void setBrightness(uint8_t contrast);
static void setInverseDisplay(bool inverted);
static int16_t getCursorX() { return cursor_x; }
static void printBounded(const char *str, const uint8_t x, const uint8_t y, const uint8_t w, const uint8_t h);
static void print(const char *string, FontStyle fontStyle,
uint8_t length = 255); // Draw a string to the current location, with selected font; optionally - with MAX length only
static void printWholeScreen(const char *string);
static void printBounded(const char *str, const uint8_t x, const uint8_t y, const uint8_t w, const uint8_t h, FontStyle fontStyle = FontStyle::FROM_TEXT);
void printNumberBounded(const uint16_t num, bool noLeaderZeros, const uint8_t x, const uint8_t y, const uint8_t w, const uint8_t h);
static void print(const char *string, FontStyle fontStyle,
uint8_t length = 255); // Draw a string to the current location, with selected font; optionally - with MAX length only
static void printWholeScreen(const char *string);
// Set the cursor location by pixels
static void setCursor(int16_t x, int16_t y) {
cursor_x = x;