draw black bg behind BigButton

This commit is contained in:
Shane Smiskol
2026-02-17 15:01:07 -08:00
parent 0a98ee9e4f
commit 7dc56dc064
+4
View File
@@ -220,6 +220,10 @@ class BigButton(Widget):
btn_x = self._rect.x + (self._rect.width * (1 - scale)) / 2
btn_y = self._rect.y + (self._rect.height * (1 - scale)) / 2
# draw black background since images are transparent
scaled_rect = rl.Rectangle(btn_x, btn_y, self._rect.width * scale, self._rect.height * scale)
rl.draw_rectangle_rounded(scaled_rect, 0.4, 7, rl.Color(0, 0, 0, int(255 * 0.5)))
self._draw_content(btn_y)
rl.draw_texture_ex(txt_bg, (btn_x, btn_y), 0, scale, rl.WHITE)