summaryrefslogtreecommitdiff
path: root/include/object/framebuffer.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/object/framebuffer.h')
-rw-r--r--include/object/framebuffer.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/object/framebuffer.h b/include/object/framebuffer.h
index c2edf22..119980a 100644
--- a/include/object/framebuffer.h
+++ b/include/object/framebuffer.h
@@ -9,12 +9,13 @@ class Framebuffer : public OutputStream
Framebuffer(Framebuffer& copy);
const glyph_t *font;
unsigned int fontX, fontY;
+ unsigned char fontSize;
unsigned char scale;
public:
unsigned char *data;
- Framebuffer(unsigned char *data) : font(0), fontX(0), fontY(0), scale(1), data(data) {}
+ Framebuffer(unsigned char *data) : font(0), fontX(0), fontY(0), fontSize(1), scale(1), data(data) {}
constexpr static unsigned int const width = CONFIG_framebuffer_width;
constexpr static unsigned int const height = CONFIG_framebuffer_height;
@@ -24,7 +25,7 @@ class Framebuffer : public OutputStream
void fillBox(unsigned int x, unsigned int y, unsigned int w, unsigned int h);
void drawAt(unsigned int x, unsigned int y, unsigned int w, unsigned int h, unsigned char *image);
void drawBattery(unsigned int x, unsigned int y, unsigned char percent, bool charging = false);
- void setFont(const glyph_t *font) { this->font = font; }
+ void setFont(const glyph_t *font, unsigned char fontSize = 1) { this->font = font; this->fontSize = fontSize; }
void setPos(unsigned int newX, unsigned int newY) { fontX = newX; fontY = newY; }
virtual void put(char c) override;
};