From aab779d4e1a16d9f5536c964f73b966c26955674 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Czeka=C5=84ski?= Date: Thu, 14 May 2020 21:18:57 +0200 Subject: [PATCH] Add comments in UiImage.py --- src/ui/UiImage.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/ui/UiImage.py b/src/ui/UiImage.py index 6dbb5fc..23ed761 100644 --- a/src/ui/UiImage.py +++ b/src/ui/UiImage.py @@ -3,7 +3,14 @@ import pygame class UiImage(UiElement): + image: pygame.Surface + def __init__(self, rect: pygame.Rect, image: pygame.Surface): + """ + Creates UiImage object. + :param rect: Rectangle on which image will be displayed + :param image: Image to display + """ super().__init__(rect) self.image = pygame.transform.scale(image, (rect.width, rect.height))