Dan Albert 306971230b Update to PySide6.
It sounds like PySide2 will not be moving to Python 3.11, so we're stuck
on 3.10 without this. Upgrading to a newer Qt also fixes some high DPI
bugs (the file browser dialog for save/load is no longer tiny on 4k).

https://github.com/pyinstaller/pyinstaller/issues/5414 previously
blocked this, but the bug appears to be fixed now.
2022-12-29 16:26:50 -08:00

19 lines
556 B
Python

from PySide6.QtWidgets import QFrame, QLabel, QGridLayout
from game.infos.information import Information
class QInfoWidget(QFrame):
def __init__(self, info: Information):
super(QInfoWidget, self).__init__()
self.info = info
self.titleLabel = QLabel("<b>" + info.title + "</b>")
self.textLabel = QLabel(info.text)
self.init_ui()
def init_ui(self):
layout = QGridLayout()
layout.addWidget(self.titleLabel, 0, 0)
layout.addWidget(self.textLabel, 1, 0)
self.setLayout(layout)