From bf19811a05740044a63cd1658c9021d4fade4dbf Mon Sep 17 00:00:00 2001 From: Nick Martinez Date: Fri, 15 May 2020 14:08:14 -0700 Subject: [PATCH] Add font_name to BitmapFont call for custom fonts --- adafruit_framebuf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/adafruit_framebuf.py b/adafruit_framebuf.py index 96d68c9..55e5fd7 100755 --- a/adafruit_framebuf.py +++ b/adafruit_framebuf.py @@ -359,7 +359,7 @@ def text(self, string, x, y, color, *, font_name="font5x8.bin", size=1): for chunk in string.split("\n"): if not self._font or self._font.font_name != font_name: # load the font! - self._font = BitmapFont() + self._font = BitmapFont(font_name) w = self._font.font_width for i, char in enumerate(chunk): self._font.draw_char(