pyqt pyside 归中窗口

pyqt pyside 归中窗口

def centerWidgetToAnother(widget, another):
    geo = widget.geometry()
    geo.moveCenter(another.geometry().center())
    widget.setGeometry(geo)

 

posted @ 2023-02-01 11:35  ibingshan  阅读(67)  评论(0编辑  收藏  举报