本文整理汇总了Python中PyQt4.QtGui.QDialogButtonBox方法的典型用法代码示例。如果您正苦于以下问题:Python QtGui.QDialogButtonBox方法的具体用法?Python QtGui.QDialogButtonBox怎么用?Python QtGui.QDialogButtonBox使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PyQt4.QtGui
的用法示例。
在下文中一共展示了QtGui.QDialogButtonBox方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: initUI
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def initUI(self):
grid = QtGui.QGridLayout()
grid.addWidget(QtGui.QLabel(u'过滤规则:', parent=self), 0, 0, 1, 1)
self.filter = QtGui.QLineEdit(parent=self)
grid.addWidget(self.filter, 0, 1, 1, 1)
# 创建ButtonBox,用户确定和取消
buttonBox = QtGui.QDialogButtonBox(parent=self)
buttonBox.setOrientation(QtCore.Qt.Horizontal) # 设置为水平方向
buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok) # 确定和取消两个按钮
# 连接信号和槽
buttonBox.accepted.connect(self.accept) # 确定
buttonBox.rejected.connect(self.reject) # 取消
# 垂直布局,布局表格及按钮
layout = QtGui.QVBoxLayout()
# 加入前面创建的表格布局
layout.addLayout(grid)
# 放一个间隔对象美化布局
spacerItem = QtGui.QSpacerItem(20, 48, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
layout.addItem(spacerItem)
# ButtonBox
layout.addWidget(buttonBox)
self.setLayout(layout)
示例2: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, EmoticonDialog):
EmoticonDialog.setObjectName(_fromUtf8("EmoticonDialog"))
EmoticonDialog.resize(300, 500)
self.verticalLayout = QtGui.QVBoxLayout(EmoticonDialog)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.label = QtGui.QLabel(EmoticonDialog)
self.label.setObjectName(_fromUtf8("label"))
self.verticalLayout.addWidget(self.label)
self.uiEmoticonTextEdit = QtGui.QTextEdit(EmoticonDialog)
self.uiEmoticonTextEdit.setObjectName(_fromUtf8("uiEmoticonTextEdit"))
self.verticalLayout.addWidget(self.uiEmoticonTextEdit)
self.buttonBox = QtGui.QDialogButtonBox(EmoticonDialog)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.verticalLayout.addWidget(self.buttonBox)
self.retranslateUi(EmoticonDialog)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), EmoticonDialog.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), EmoticonDialog.reject)
QtCore.QMetaObject.connectSlotsByName(EmoticonDialog)
示例3: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, LookupValueSelector):
LookupValueSelector.setObjectName(_fromUtf8("LookupValueSelector"))
LookupValueSelector.resize(295, 283)
self.verticalLayout = QtGui.QVBoxLayout(LookupValueSelector)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.notice_bar = QtGui.QVBoxLayout()
self.notice_bar.setObjectName(_fromUtf8("notice_bar"))
self.verticalLayout.addLayout(self.notice_bar)
self.value_list_box = QtGui.QTreeView(LookupValueSelector)
self.value_list_box.setEditTriggers(QtGui.QAbstractItemView.NoEditTriggers)
self.value_list_box.setAlternatingRowColors(True)
self.value_list_box.setRootIsDecorated(False)
self.value_list_box.setUniformRowHeights(True)
self.value_list_box.setObjectName(_fromUtf8("value_list_box"))
self.verticalLayout.addWidget(self.value_list_box)
self.buttonBox = QtGui.QDialogButtonBox(LookupValueSelector)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.verticalLayout.addWidget(self.buttonBox)
self.retranslateUi(LookupValueSelector)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), LookupValueSelector.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), LookupValueSelector.reject)
QtCore.QMetaObject.connectSlotsByName(LookupValueSelector)
示例4: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, SpatialUnitTenureDialog):
SpatialUnitTenureDialog.setObjectName(_fromUtf8("SpatialUnitTenureDialog"))
SpatialUnitTenureDialog.resize(318, 252)
self.gridLayout = QtGui.QGridLayout(SpatialUnitTenureDialog)
self.gridLayout.setObjectName(_fromUtf8("gridLayout"))
self.buttonBox = QtGui.QDialogButtonBox(SpatialUnitTenureDialog)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.gridLayout.addWidget(self.buttonBox, 2, 0, 1, 1)
self.sp_tenure_view = ListPairTableView(SpatialUnitTenureDialog)
self.sp_tenure_view.setObjectName(_fromUtf8("sp_tenure_view"))
self.gridLayout.addWidget(self.sp_tenure_view, 1, 0, 1, 1)
self.label = QtGui.QLabel(SpatialUnitTenureDialog)
self.label.setObjectName(_fromUtf8("label"))
self.gridLayout.addWidget(self.label, 0, 0, 1, 1)
self.retranslateUi(SpatialUnitTenureDialog)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), SpatialUnitTenureDialog.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), SpatialUnitTenureDialog.reject)
QtCore.QMetaObject.connectSlotsByName(SpatialUnitTenureDialog)
示例5: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, VarcharProperty):
VarcharProperty.setObjectName(_fromUtf8("VarcharProperty"))
VarcharProperty.resize(246, 67)
self.formLayout = QtGui.QFormLayout(VarcharProperty)
self.formLayout.setObjectName(_fromUtf8("formLayout"))
self.label = QtGui.QLabel(VarcharProperty)
self.label.setObjectName(_fromUtf8("label"))
self.formLayout.setWidget(0, QtGui.QFormLayout.LabelRole, self.label)
self.edtCharLen = QtGui.QLineEdit(VarcharProperty)
self.edtCharLen.setObjectName(_fromUtf8("edtCharLen"))
self.formLayout.setWidget(0, QtGui.QFormLayout.FieldRole, self.edtCharLen)
self.buttonBox = QtGui.QDialogButtonBox(VarcharProperty)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.formLayout.setWidget(1, QtGui.QFormLayout.SpanningRole, self.buttonBox)
self.retranslateUi(VarcharProperty)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), VarcharProperty.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), VarcharProperty.reject)
QtCore.QMetaObject.connectSlotsByName(VarcharProperty)
示例6: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, ChangeLog):
ChangeLog.setObjectName(_fromUtf8("ChangeLog"))
ChangeLog.resize(714, 557)
self.verticalLayout = QtGui.QVBoxLayout(ChangeLog)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.webView = QtWebKit.QWebView(ChangeLog)
self.webView.setUrl(QtCore.QUrl(_fromUtf8("about:blank")))
self.webView.setObjectName(_fromUtf8("webView"))
self.verticalLayout.addWidget(self.webView)
self.horizontalLayout = QtGui.QHBoxLayout()
self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
self.buttonBox = QtGui.QDialogButtonBox(ChangeLog)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.horizontalLayout.addWidget(self.buttonBox)
spacerItem = QtGui.QSpacerItem(600000, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout.addItem(spacerItem)
self.verticalLayout.addLayout(self.horizontalLayout)
self.retranslateUi(ChangeLog)
QtCore.QMetaObject.connectSlotsByName(ChangeLog)
示例7: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, FileBrowser):
FileBrowser.setObjectName("FileBrowser")
FileBrowser.resize(400, 300)
self.verticalLayout = QtGui.QVBoxLayout(FileBrowser)
self.verticalLayout.setObjectName("verticalLayout")
self.splitter = QtGui.QSplitter(FileBrowser)
self.splitter.setOrientation(QtCore.Qt.Vertical)
self.splitter.setObjectName("splitter")
self.treeView = QtGui.QTreeView(self.splitter)
self.treeView.setObjectName("treeView")
self.buttonBox = QtGui.QDialogButtonBox(self.splitter)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName("buttonBox")
self.verticalLayout.addWidget(self.splitter)
self.retranslateUi(FileBrowser)
QtCore.QMetaObject.connectSlotsByName(FileBrowser)
示例8: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, Alert):
Alert.setObjectName("Alert")
Alert.resize(400, 93)
self.verticalLayout = QtGui.QVBoxLayout(Alert)
self.verticalLayout.setObjectName("verticalLayout")
self.gridLayout = QtGui.QGridLayout()
self.gridLayout.setObjectName("gridLayout")
spacerItem = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.gridLayout.addItem(spacerItem, 0, 0, 1, 1)
self.label = QtGui.QLabel(Alert)
self.label.setObjectName("label")
self.gridLayout.addWidget(self.label, 0, 1, 1, 1)
spacerItem1 = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.gridLayout.addItem(spacerItem1, 0, 2, 1, 1)
self.verticalLayout.addLayout(self.gridLayout)
self.buttonBox = QtGui.QDialogButtonBox(Alert)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName("buttonBox")
self.verticalLayout.addWidget(self.buttonBox)
self.retranslateUi(Alert)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("accepted()"), Alert.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("rejected()"), Alert.reject)
QtCore.QMetaObject.connectSlotsByName(Alert)
示例9: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, TrezorPassphraseDialog):
TrezorPassphraseDialog.setObjectName(_fromUtf8("TrezorPassphraseDialog"))
TrezorPassphraseDialog.resize(400, 133)
self.verticalLayout = QtGui.QVBoxLayout(TrezorPassphraseDialog)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.label = QtGui.QLabel(TrezorPassphraseDialog)
self.label.setObjectName(_fromUtf8("label"))
self.verticalLayout.addWidget(self.label)
self.passphraseEdit = QtGui.QLineEdit(TrezorPassphraseDialog)
self.passphraseEdit.setEchoMode(QtGui.QLineEdit.Password)
self.passphraseEdit.setObjectName(_fromUtf8("passphraseEdit"))
self.verticalLayout.addWidget(self.passphraseEdit)
spacerItem = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout.addItem(spacerItem)
self.buttonBox = QtGui.QDialogButtonBox(TrezorPassphraseDialog)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.verticalLayout.addWidget(self.buttonBox)
self.retranslateUi(TrezorPassphraseDialog)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), TrezorPassphraseDialog.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), TrezorPassphraseDialog.reject)
QtCore.QMetaObject.connectSlotsByName(TrezorPassphraseDialog)
示例10: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, AddGroupDialog):
AddGroupDialog.setObjectName(_fromUtf8("AddGroupDialog"))
AddGroupDialog.resize(415, 111)
self.verticalLayout = QtGui.QVBoxLayout(AddGroupDialog)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.label = QtGui.QLabel(AddGroupDialog)
self.label.setObjectName(_fromUtf8("label"))
self.verticalLayout.addWidget(self.label)
self.newGroupEdit = QtGui.QLineEdit(AddGroupDialog)
self.newGroupEdit.setMaxLength(64)
self.newGroupEdit.setObjectName(_fromUtf8("newGroupEdit"))
self.verticalLayout.addWidget(self.newGroupEdit)
spacerItem = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout.addItem(spacerItem)
self.buttonBox = QtGui.QDialogButtonBox(AddGroupDialog)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.verticalLayout.addWidget(self.buttonBox)
self.retranslateUi(AddGroupDialog)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), AddGroupDialog.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), AddGroupDialog.reject)
QtCore.QMetaObject.connectSlotsByName(AddGroupDialog)
示例11: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, TrezorChooserDialog):
TrezorChooserDialog.setObjectName(_fromUtf8("TrezorChooserDialog"))
TrezorChooserDialog.resize(400, 300)
self.verticalLayout = QtGui.QVBoxLayout(TrezorChooserDialog)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.label = QtGui.QLabel(TrezorChooserDialog)
self.label.setObjectName(_fromUtf8("label"))
self.verticalLayout.addWidget(self.label)
self.trezorList = QtGui.QListWidget(TrezorChooserDialog)
self.trezorList.setObjectName(_fromUtf8("trezorList"))
self.verticalLayout.addWidget(self.trezorList)
self.buttonBox = QtGui.QDialogButtonBox(TrezorChooserDialog)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.verticalLayout.addWidget(self.buttonBox)
self.retranslateUi(TrezorChooserDialog)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), TrezorChooserDialog.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), TrezorChooserDialog.reject)
QtCore.QMetaObject.connectSlotsByName(TrezorChooserDialog)
示例12: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, qgpkgDlg):
qgpkgDlg.setObjectName(_fromUtf8("qgpkgDlg"))
qgpkgDlg.resize(456, 358)
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(_fromUtf8(":/plugins/QgisGeopackage/about.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
qgpkgDlg.setWindowIcon(icon)
self.verticalLayout = QtGui.QVBoxLayout(qgpkgDlg)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.textEdit = QtGui.QTextEdit(qgpkgDlg)
self.textEdit.setReadOnly(True)
self.textEdit.setObjectName(_fromUtf8("textEdit"))
self.verticalLayout.addWidget(self.textEdit)
self.button_box = QtGui.QDialogButtonBox(qgpkgDlg)
self.button_box.setOrientation(QtCore.Qt.Horizontal)
self.button_box.setStandardButtons(QtGui.QDialogButtonBox.Close)
self.button_box.setObjectName(_fromUtf8("button_box"))
self.verticalLayout.addWidget(self.button_box)
self.retranslateUi(qgpkgDlg)
QtCore.QObject.connect(self.button_box, QtCore.SIGNAL(_fromUtf8("accepted()")), qgpkgDlg.accept)
QtCore.QObject.connect(self.button_box, QtCore.SIGNAL(_fromUtf8("rejected()")), qgpkgDlg.reject)
QtCore.QMetaObject.connectSlotsByName(qgpkgDlg)
示例13: manual
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def manual(self):
data=QtCore.QFile("ar/help_body.html");
if (data.open(QtCore.QFile.ReadOnly)):
textstream=QtCore.QTextStream(data);
textstream.setCodec("UTF-8");
text=textstream.readAll();
else:
text=u"لا يمكن فتح ملف المساعدة"
Dialog=QtGui.QDialog(self.centralwidget)
Dialog.setObjectName("Dialog")
Dialog.resize(480, 480)
Dialog.setWindowTitle(u'دليل الاستعمال')
gridLayout = QtGui.QGridLayout(Dialog)
gridLayout.setObjectName("gridLayout")
textBrowser = QtGui.QTextBrowser(Dialog)
textBrowser.setObjectName("textBrowser")
gridLayout.addWidget(textBrowser, 0, 0, 1, 1)
buttonBox = QtGui.QDialogButtonBox(Dialog)
buttonBox.setOrientation(QtCore.Qt.Horizontal)
buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Ok)
buttonBox.setObjectName("buttonBox")
gridLayout.addWidget(buttonBox, 1, 0, 1, 1)
QtCore.QObject.connect(buttonBox, QtCore.SIGNAL("accepted()"), Dialog.accept)
QtCore.QMetaObject.connectSlotsByName(Dialog)
text2=unicode(text)
textBrowser.setText(text2)
RightToLeft=1;
Dialog.setLayoutDirection(RightToLeft);
Dialog.show();
示例14: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, SavestatesDialog):
SavestatesDialog.setObjectName(_fromUtf8("SavestatesDialog"))
SavestatesDialog.resize(630, 600)
SavestatesDialog.setWindowTitle(QtGui.QApplication.translate("SavestatesDialog", "Unsupported game savestates", None, QtGui.QApplication.UnicodeUTF8))
self.verticalLayout = QtGui.QVBoxLayout(SavestatesDialog)
self.verticalLayout.setContentsMargins(2, 0, 2, 6)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.horizontalLayout = QtGui.QHBoxLayout()
self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
self.label = QtGui.QLabel(SavestatesDialog)
self.label.setText(QtGui.QApplication.translate("SavestatesDialog", "Filter:", None, QtGui.QApplication.UnicodeUTF8))
self.label.setObjectName(_fromUtf8("label"))
self.horizontalLayout.addWidget(self.label)
self.uiFilterLineEdit = QtGui.QLineEdit(SavestatesDialog)
self.uiFilterLineEdit.setText(_fromUtf8(""))
self.uiFilterLineEdit.setObjectName(_fromUtf8("uiFilterLineEdit"))
self.horizontalLayout.addWidget(self.uiFilterLineEdit)
self.verticalLayout.addLayout(self.horizontalLayout)
self.uiSavestatesTblv = QtGui.QTableView(SavestatesDialog)
self.uiSavestatesTblv.setObjectName(_fromUtf8("uiSavestatesTblv"))
self.verticalLayout.addWidget(self.uiSavestatesTblv)
self.uiButtonBox = QtGui.QDialogButtonBox(SavestatesDialog)
self.uiButtonBox.setOrientation(QtCore.Qt.Horizontal)
self.uiButtonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.uiButtonBox.setObjectName(_fromUtf8("uiButtonBox"))
self.verticalLayout.addWidget(self.uiButtonBox)
self.retranslateUi(SavestatesDialog)
QtCore.QObject.connect(self.uiButtonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), SavestatesDialog.accept)
QtCore.QObject.connect(self.uiButtonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), SavestatesDialog.reject)
QtCore.QMetaObject.connectSlotsByName(SavestatesDialog)
SavestatesDialog.setTabOrder(self.uiFilterLineEdit, self.uiSavestatesTblv)
SavestatesDialog.setTabOrder(self.uiSavestatesTblv, self.uiButtonBox)
示例15: setupUi
# 需要导入模块: from PyQt4 import QtGui [as 别名]
# 或者: from PyQt4.QtGui import QDialogButtonBox [as 别名]
def setupUi(self, Dialog):
Dialog.setObjectName(_fromUtf8("Dialog"))
Dialog.resize(452, 139)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(Dialog.sizePolicy().hasHeightForWidth())
Dialog.setSizePolicy(sizePolicy)
self.gridLayout = QtGui.QGridLayout(Dialog)
self.gridLayout.setObjectName(_fromUtf8("gridLayout"))
self.label = QtGui.QLabel(Dialog)
self.label.setAlignment(QtCore.Qt.AlignCenter)
self.label.setWordWrap(True)
self.label.setObjectName(_fromUtf8("label"))
self.gridLayout.addWidget(self.label, 0, 0, 1, 1)
self.progressBar = QtGui.QProgressBar(Dialog)
self.progressBar.setMinimum(0)
self.progressBar.setMaximum(0)
self.progressBar.setProperty("value", -1)
self.progressBar.setObjectName(_fromUtf8("progressBar"))
self.gridLayout.addWidget(self.progressBar, 1, 0, 1, 1)
self.buttonBox = QtGui.QDialogButtonBox(Dialog)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Help)
self.buttonBox.setObjectName(_fromUtf8("buttonBox"))
self.gridLayout.addWidget(self.buttonBox, 2, 0, 1, 1)
self.retranslateUi(Dialog)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), Dialog.accept)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("rejected()")), Dialog.reject)
QtCore.QMetaObject.connectSlotsByName(Dialog)