mirror of https://github.com/borgbase/vorta
Reduce icon memory usage. By @samuel-w (#656)
This commit is contained in:
parent
a86683e2b8
commit
b161296996
|
@ -10,4 +10,8 @@ def get_colored_icon(icon_name):
|
|||
if uses_dark_mode():
|
||||
svg_str = svg_str.replace(b'#00000', b'#ffffff')
|
||||
svg_img = QImage.fromData(svg_str)
|
||||
|
||||
# Reduce image size to 1/14th
|
||||
svg_img = svg_img.scaled(svg_img.size() / 14)
|
||||
|
||||
return QIcon(QPixmap(svg_img))
|
||||
|
|
Loading…
Reference in New Issue