我有一段看起来像这样的代码:
app = QApplication(sys.argv)
self.interface = Interface()
# The figure
self.fig = self.interface.fig
self.ax = self.fig.add_subplot(111)
self.interface.show()
app.exec_()
print 'this is not printed'
问题在于一旦执行了app.exec_()
,除非我关闭弹出的窗口,否则不会有任何反应。如何继续运行代码?
如何保持代码继续运行?
app.exec_()
之后运行代码?是否可能只是打开一个窗口,做一些事情,然后关闭它,然后再运行代码? - cgf