How To Create An Abstract Base Class In Python Which Derived From Qobject
I'm trying to create an abstract base class for an interface, but I need it to derive from QObject for signals and slots. My class definition looks like this: import abc from PyQt5
Solution 1:
Based on Multiple inheritance metaclass conflict
Try
import abc
from PyQt5.QtCore import QObject, pyqtWrapperType
classFinalMeta(pyqtWrapperType, abc.ABCMeta):
passclassinterface_class(QObject, metaclass=FinalMeta):
pass
Post a Comment for "How To Create An Abstract Base Class In Python Which Derived From Qobject"