本文整理汇总了Python中PySide.QtGui.QDialog.setWindowTitle方法的典型用法代码示例。如果您正苦于以下问题:Python QDialog.setWindowTitle方法的具体用法?Python QDialog.setWindowTitle怎么用?Python QDialog.setWindowTitle使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PySide.QtGui.QDialog
的用法示例。
在下文中一共展示了QDialog.setWindowTitle方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: deleteTab
# 需要导入模块: from PySide.QtGui import QDialog [as 别名]
# 或者: from PySide.QtGui.QDialog import setWindowTitle [as 别名]
def deleteTab(self):
dialog = QDialog( self )
dialog.setWindowTitle( "Remove Tab" )
dialog.resize( 300, 50 )
mainLayout = QVBoxLayout(dialog)
description = QLabel( "'%s' ���� �����Ͻð� ���ϱ�?".decode('utf-8') % self.tabText( self.currentIndex() ) )
layoutButtons = QHBoxLayout()
buttonDelete = QPushButton( "�����".decode('utf-8') )
buttonCancel = QPushButton( "���".decode('utf-8') )
layoutButtons.addWidget( buttonDelete )
layoutButtons.addWidget( buttonCancel )
mainLayout.addWidget( description )
mainLayout.addLayout( layoutButtons )
dialog.show()
def cmd_delete():
self.removeTab( self.indexOf( self.currentWidget() ) )
dialog.close()
def cmd_cancel():
dialog.close()
QtCore.QObject.connect( buttonDelete, QtCore.SIGNAL('clicked()'), cmd_delete )
QtCore.QObject.connect( buttonCancel, QtCore.SIGNAL('clicked()'), cmd_cancel )
示例2: settings
# 需要导入模块: from PySide.QtGui import QDialog [as 别名]
# 或者: from PySide.QtGui.QDialog import setWindowTitle [as 别名]
def settings(self):
if self.settings_window is None:
window = QDialog(self)
self.settings_window = window
else: window = self.settings_window
window = self.settings_window
window.setWindowTitle('Settings')
window.notelabel = QLabel("Currently these settings are only guaranteed to work prior to loading the first MIDI!\nYou'll have to restart ADLMIDI pyGui to change them again if they stop working. \n\nSorry! This will be fixed soon!")
window.notelabel.setWordWrap(True)
window.notelabel.setStyleSheet("font-size: 8pt; border-style: dotted; border-width: 1px; padding: 12px;")
window.banklabel = QLabel("<B>Choose Instrument Bank</B>")
window.space = QLabel("")
window.optlabel = QLabel("<B>Options</B>")
window.combo = QComboBox()
window.combo.addItems(self.banks)
#window.combo.setMaximumWidth(350)
window.combo.setMaxVisibleItems(12)
window.combo.setStyleSheet("combobox-popup: 0;")
window.combo.setCurrentIndex(int(self.progset.value("sound/bank", 1)))
window.combo.currentIndexChanged.connect(self.saveSettings)
window.perc = QCheckBox("Adlib Percussion Instrument Mode")
#window.perc.stateChanged.connect(self.checkOpts)
window.tremamp = QCheckBox("Tremolo Amplification Mode")
#window.tremamp.stateChanged.connect(self.checkOpts)
window.vibamp = QCheckBox("Vibrato Amplification Mode")
#window.vibamp.stateChanged.connect(self.checkOpts)
window.modscale = QCheckBox("Scaling of Modulator Volume")
#window.modscale.stateChanged.connect(self.checkOpts)
window.okButton = QPushButton('OK')
window.okButton.clicked.connect(window.hide)
vbox = QVBoxLayout()
vbox.addWidget(window.space)
vbox.addWidget(window.banklabel)
vbox.addWidget(window.combo)
vbox.addWidget(window.space)
vbox.addWidget(window.optlabel)
vbox.addWidget(window.perc)
vbox.addWidget(window.tremamp)
vbox.addWidget(window.vibamp)
vbox.addWidget(window.modscale)
vbox.addWidget(window.notelabel)
hbox = QHBoxLayout()
hbox.addStretch(1)
hbox.addWidget(window.okButton)
vbox.addLayout(hbox)
window.setLayout(vbox)
window.setFixedSize(530, 369)
window.show()
window.activateWindow()
window.raise_()
示例3: _create_control
# 需要导入模块: from PySide.QtGui import QDialog [as 别名]
# 或者: from PySide.QtGui.QDialog import setWindowTitle [as 别名]
def _create_control ( self, parent ):
dlg = QDialog( parent )
if self.size != ( -1, -1 ):
dlg.resize( *self.size )
# FIXME v3: Decide what to do with the resizable facet (ie. set the
# size policy):
dlg.setWindowTitle( self.title )
return dlg
#-- EOF ------------------------------------------------------------------------
示例4: addTab
# 需要导入模块: from PySide.QtGui import QDialog [as 别名]
# 或者: from PySide.QtGui.QDialog import setWindowTitle [as 别名]
def addTab(self):
dialog = QDialog( self )
dialog.setWindowTitle( 'Add Tab' )
dialog.resize( 300, 50 )
mainLayout = QVBoxLayout( dialog )
tabNameLayout = QHBoxLayout()
labelTabName = QLabel( 'Tab Name : ' )
lineEditTabName = QLineEdit()
tabNameLayout.addWidget( labelTabName )
tabNameLayout.addWidget( lineEditTabName )
buttonsLayout = QHBoxLayout()
buttonCreate = QPushButton( "Create" )
buttonCancel = QPushButton( "Cancel")
buttonsLayout.addWidget( buttonCreate )
buttonsLayout.addWidget( buttonCancel )
mainLayout.addLayout( tabNameLayout )
mainLayout.addLayout( buttonsLayout )
dialog.show()
def cmd_create():
tabName = lineEditTabName.text()
if not tabName:
msgbox = QMessageBox( self )
msgbox.setText( "�̸��� �������ּ���".decode( 'utf-8' ) )
msgbox.exec_()
return
self.tabWidget.addTab( tabName )
dialog.close()
def cmd_cancel():
dialog.close()
QtCore.QObject.connect( lineEditTabName, QtCore.SIGNAL( 'returnPressed()' ), cmd_create )
QtCore.QObject.connect( buttonCreate, QtCore.SIGNAL( 'clicked()' ), cmd_create )
QtCore.QObject.connect( buttonCancel, QtCore.SIGNAL( 'clicked()' ), cmd_cancel )
示例5: _create_control
# 需要导入模块: from PySide.QtGui import QDialog [as 别名]
# 或者: from PySide.QtGui.QDialog import setWindowTitle [as 别名]
def _create_control ( self, parent ):
control = QDialog( parent )
control.setWindowTitle( self.title )
return control