I'm trying to make a custom QLabel class but I always got an error code -1073740791. Any idea how to make it work? Coding on PyCharm. Thanks
Code:
from PySide6.QtWidgets import*
class IconLabel(QLabel):
def __init__(self):
super().__init__()
lab = IconLabel()
Try to make a custom QLabel object to display specific icon on demand into it, but can't initiate the object before adding the function. Error code without details or info from the web.
Ok so to init a QLabel you need to pass a widget parent to it and create a QApplication before it, then you declare the previous widget as parent:
Thanks @mahkitah