2 from librarian import get_resource
3 from .base import Widget
6 class ImageWidget(Widget):
8 img = PIL.Image.open(self.image_path)
9 img = img.resize((round(img.size[0] / img.size[1] * h), h))
13 class WLLogo(ImageWidget):
16 if self.cover.color_scheme['text'] == '#fff':
17 return get_resource('res/cover/logo_WL_invert.png')
19 return get_resource('res/cover/logo_WL.png')
22 class Label(ImageWidget):
25 if self.cover.is_very_bright:
26 return get_resource('res/cover/label_WLpolecaja.szary.png')
28 return get_resource('res/cover/label_WLpolecaja.png')