From a167ae70c343a28a580a02258d9dc16d1f9d4f23 Mon Sep 17 00:00:00 2001 From: EKNr1 Date: Thu, 5 Dec 2024 17:38:22 +0100 Subject: [PATCH] Made the examples work again. --- examples/gui.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/gui.py b/examples/gui.py index 099b48a..4d38b28 100644 --- a/examples/gui.py +++ b/examples/gui.py @@ -82,7 +82,7 @@ class ExampleMenu(Page): i = 0 for button in buttons: - if x + button.surface.get_width() > self.app.screen.get_width(): + if x + button.image.get_width() > self.app.screen.get_width(): x = start_pos[0] y += button.surface.get_height() + spacing @@ -98,7 +98,7 @@ class ExampleMenu(Page): buttons[i] = button - x += button.surface.get_width() + spacing + x += button.image.get_width() + spacing i += 1