import GUI.Widget as Widget
import Texture
-from enum import Enum
import pygame
import os
def setSurface(self, buttonState) -> None:
sourceRect = (buttonState * self.screenW, 0, self.screenW, self.screenH)
self.surface.blit(self.buttonImage, (0,0), sourceRect)
- text = Texture.fontDict[self.textSize].render(self.text, False, self.textCol)
+ text = Texture.fontDictDict[self.font][self.fontSize].render(self.text, False, self.colour)
textRect = text.get_rect()
textOriginX = (self.screenW / 2) - (textRect.w / 2)
textOriginY = (self.screenH / 2) - (textRect.h / 2)