0
我有一个操作按钮调用,我已经做了一个对话框:设定值从filepicker到对话框,把它称为
class MainPanelManager(QtWidgets.QMainWindow, Ui_MainWindow):
def __init__(self):
super().__init__()
self.setupUi(self)
self.actionLocation.triggered.connect(self.editsettings)
def editsettings(self):
dialog = QDialog()
dialog.ui = Ui_Dialog()
dialog.ui.setupUi(dialog)
dialog.ui.pushButton.clicked.connect(self.openfile)
dialog.exec_()
def openfile(self):
folder = QFileDialog.getExistingDirectory(self, 'Select Folder', 'C:/')
# folder value must be set to dialog textedit
对话框作品和按下按钮时打开文件选择器。如何设置选择文件夹时的值。我需要把值放在textedit