matrix.py 文件源码

python
阅读 29 收藏 0 点赞 0 评论 0

项目:pcbre 作者: pcbre 项目源码 文件源码
def __init__(self, *args, **kwargs):
        if len(args) == 2:
            self.width, self.height = args
        elif len(args) == 1 and isinstance(args[0], (QtCore.QRect, QtCore.QRectF)):
            self.width = args[0].width()
            self.width = args[0].height()
        elif len(args) == 1 and len(args[0]) == 2:
            self.width, self.height = args[0]
        elif len(kwargs) == 2 and "width" in kwargs and "height" in kwargs:
            self.width = kwargs["width"]
            self.height = kwards["height"]
        else:
            raise TypeError
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号