tuxemon.ui.draw module
- class tuxemon.ui.draw.GraphicBox(border=None, background=None, color=None, fill_tiles=False)[source]
Bases:
Sprite
Generic class for drawing graphical boxes.
Draws a border and can fill in the box with a _color from the border file, an external file, or a solid _color.
box = GraphicBox(‘border.png’) box.draw(surface, rect)
The border graphic must contain 9 tiles laid out in a box.
- Parameters:
border (Optional[pygame.surface.Surface]) –
background (Optional[pygame.surface.Surface]) –
color (Optional[ColorLike]) –
fill_tiles (bool) –