mirror of
https://gitee.com/gfdgd-xi/deep-wine-runner
synced 2025-12-13 18:42:03 +08:00
支持将窗口作为组件引入
This commit is contained in:
12
test.py
Normal file
12
test.py
Normal file
@@ -0,0 +1,12 @@
|
||||
import sys
|
||||
import globalenv
|
||||
import PyQt5.QtWidgets as QtWidgets
|
||||
app = QtWidgets.QApplication(sys.argv)
|
||||
window = QtWidgets.QMainWindow()
|
||||
globalenv._init()
|
||||
globalenv.set_value("app", app)
|
||||
|
||||
import mainwindow
|
||||
window.setCentralWidget(mainwindow.window)
|
||||
window.show()
|
||||
app.exec_()
|
||||
Reference in New Issue
Block a user