本文整理汇总了Python中PySide.QtGui.QListWidget.setObjectName方法的典型用法代码示例。如果您正苦于以下问题:Python QListWidget.setObjectName方法的具体用法?Python QListWidget.setObjectName怎么用?Python QListWidget.setObjectName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PySide.QtGui.QListWidget
的用法示例。
在下文中一共展示了QListWidget.setObjectName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: addTab
# 需要导入模块: from PySide.QtGui import QListWidget [as 别名]
# 或者: from PySide.QtGui.QListWidget import setObjectName [as 别名]
def addTab(self, label ):
layoutWidget = QWidget()
vLayout = QVBoxLayout(layoutWidget)
vLayout.setContentsMargins(5,5,5,5)
setFolderLayout = QHBoxLayout()
listWidget = QListWidget()
listWidget.setSelectionMode( QAbstractItemView.ExtendedSelection )
vLayout.addLayout( setFolderLayout )
vLayout.addWidget( listWidget )
lineEdit = QLineEdit()
setFolderButton = QPushButton( 'Set Folder' )
setFolderLayout.addWidget( lineEdit )
setFolderLayout.addWidget( setFolderButton )
QtCore.QObject.connect( setFolderButton, QtCore.SIGNAL( 'clicked()' ), Functions.setFolder )
QtCore.QObject.connect( listWidget, QtCore.SIGNAL( 'itemSelectionChanged()' ), Functions.loadImagePathArea )
QtCore.QObject.connect( lineEdit, QtCore.SIGNAL( 'textChanged()' ), Functions.lineEdited )
listWidget.setObjectName( Window_global.listWidgetObjectName )
lineEdit.setContextMenuPolicy( QtCore.Qt.NoContextMenu )
lineEdit.setObjectName( Window_global.lineEditObjectName )
lineEdit.returnPressed.connect( Functions.lineEdited )
super( Tab, self ).addTab( layoutWidget, label )
示例2: Ui_MainWindow
# 需要导入模块: from PySide.QtGui import QListWidget [as 别名]
# 或者: from PySide.QtGui.QListWidget import setObjectName [as 别名]
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
lbMinWidth = 65
# leMinWidth = 200
MainWindow.setObjectName("MainWindow")
MainWindow.resize(400, 310)
# self.centralwidget = QWidget(MainWindow)
self.mainSplitter = QSplitter(Qt.Horizontal, MainWindow)
self.mainSplitter.setObjectName("centralwidget")
self.mainSplitter.setProperty("childrenCollapsible", False)
MainWindow.setCentralWidget(self.mainSplitter)
self.leftSplitter = QSplitter(Qt.Vertical, self.mainSplitter)
self.leftSplitter.setProperty("childrenCollapsible", False)
##### login_gbox
self.login_gbox = QGroupBox(self.leftSplitter)
self.login_gbox.setFlat(True)
self.login_gbox.setObjectName("login_gbox")
login_gbox_layout = QVBoxLayout(self.login_gbox)
login_gbox_csf_layout = QHBoxLayout()
login_gbox_account_layout = QHBoxLayout()
login_gbox_connect_layout = QHBoxLayout()
login_gbox_layout.addLayout(login_gbox_csf_layout)
login_gbox_layout.addLayout(login_gbox_account_layout)
login_gbox_layout.addLayout(login_gbox_connect_layout)
self.lb_client_secrets_file_path = QLabel(self.login_gbox)
self.lb_client_secrets_file_path.setObjectName("lb_client_secrets_file_path")
self.lb_client_secrets_file_path.setMinimumWidth(lbMinWidth)
self.client_secrets_file_path_le = QLineEdit(self.login_gbox)
self.client_secrets_file_path_le.setObjectName("client_secrets_file_path_le")
self.client_secret_file_path_tBtn = QToolButton(self.login_gbox)
self.client_secret_file_path_tBtn.setObjectName("client_secret_file_path_tBtn")
login_gbox_csf_layout.addWidget(self.lb_client_secrets_file_path)
login_gbox_csf_layout.addWidget(self.client_secrets_file_path_le)
login_gbox_csf_layout.addWidget(self.client_secret_file_path_tBtn)
self.lb_account = QLabel(self.login_gbox)
self.lb_account.setMaximumWidth(lbMinWidth)
self.lb_account.setObjectName("lb_account")
self.remove_account_btn = QToolButton(self.login_gbox)
self.remove_account_btn.setObjectName("remove_account_btn")
self.remove_account_btn.setMinimumWidth(20)
self.remove_account_btn.setEnabled(False)
self.add_account_btn = QToolButton(self.login_gbox)
self.add_account_btn.setObjectName("add_account_btn")
self.add_account_btn.setMinimumWidth(20)
self.accounts_cb = QComboBox(self.login_gbox)
self.accounts_cb.setObjectName("accounts_cb")
login_gbox_account_layout.addWidget(self.lb_account)
login_gbox_account_layout.addWidget(self.remove_account_btn)
login_gbox_account_layout.addWidget(self.add_account_btn)
login_gbox_account_layout.addWidget(self.accounts_cb)
self.lb_decryption_key = QLabel(self.login_gbox)
self.lb_decryption_key.setObjectName("lb_decryption_key")
self.lb_decryption_key.setMinimumWidth(lbMinWidth)
self.lb_decryption_key.hide()
self.decryption_key_le = QLineEdit(self.login_gbox)
self.decryption_key_le.setEchoMode(QLineEdit.Password)
self.decryption_key_le.setObjectName("decryption_key_le")
self.decryption_key_le.hide()
self.connect_btn = QPushButton(self.login_gbox)
self.connect_btn.setEnabled(False)
self.connect_btn.setObjectName("connect_btn")
login_gbox_connect_layout.addWidget(self.lb_decryption_key)
login_gbox_connect_layout.addWidget(self.decryption_key_le)
login_gbox_connect_layout.addWidget(self.connect_btn)
#### search_gbox
self.search_gbox = QGroupBox(self.leftSplitter)
self.search_gbox.setFlat(True)
self.search_gbox.setObjectName("search_gbox")
self.search_gbox.hide()
search_gbox_layout = QVBoxLayout(self.search_gbox)
search_gbox_mailbox_layout = QVBoxLayout()
search_gbox_date_layout = QHBoxLayout()
search_gbox_from_layout = QHBoxLayout()
search_gbox_to_layout = QHBoxLayout()
search_gbox_subject_layout = QHBoxLayout()
search_gbox_threads_layout = QHBoxLayout()
search_gbox_paramaters_layout = QHBoxLayout()
search_gbox_layout.addLayout(search_gbox_mailbox_layout)
search_gbox_layout.addLayout(search_gbox_date_layout)
#.........这里部分代码省略.........
示例3: Ui_MainWindow
# 需要导入模块: from PySide.QtGui import QListWidget [as 别名]
# 或者: from PySide.QtGui.QListWidget import setObjectName [as 别名]
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName("MainWindow")
MainWindow.resize(810, 492)
lbMinWidth = 65
lbMinWidthLogin = 110
# leMinWidth = 200
# self.centralwidget = QWidget(MainWindow)
self.mainSplitter = QSplitter(Qt.Horizontal, MainWindow)
self.mainSplitter.setObjectName("centralwidget")
self.mainSplitter.setProperty("childrenCollapsible", False)
MainWindow.setCentralWidget(self.mainSplitter)
self.leftSplitter = QSplitter(Qt.Vertical, self.mainSplitter)
self.leftSplitter.setProperty("childrenCollapsible", False)
# login_gbox
self.login_gbox = QGroupBox(self.leftSplitter)
self.login_gbox.setFlat(True)
self.login_gbox.setObjectName("login_gbox")
login_gbox_layout = QVBoxLayout(self.login_gbox)
login_gbox_presets_layout = QHBoxLayout()
login_gbox_server_layout = QHBoxLayout()
login_gbox_ssl_layout = QHBoxLayout()
login_gbox_address_layout = QHBoxLayout()
login_gbox_pass_layout = QHBoxLayout()
login_gbox_connect_layout = QHBoxLayout()
login_gbox_layout.addLayout(login_gbox_presets_layout)
login_gbox_layout.addLayout(login_gbox_server_layout)
login_gbox_layout.addLayout(login_gbox_ssl_layout)
login_gbox_layout.addLayout(login_gbox_address_layout)
login_gbox_layout.addLayout(login_gbox_pass_layout)
login_gbox_layout.addLayout(login_gbox_connect_layout)
self.lb_presets = QLabel(self.login_gbox)
self.lb_presets.setObjectName("lb_presets")
self.lb_presets.setMinimumWidth(lbMinWidthLogin)
self.lb_presets.setMaximumWidth(lbMinWidthLogin)
self.presets_cbox = QComboBox(self.login_gbox)
self.presets_cbox.setObjectName("presets_cbox")
self.add_preset_btn = QPushButton(self.login_gbox)
self.add_preset_btn.setObjectName("add_preset_btn")
self.add_preset_btn.setMaximumWidth(30)
self.remove_preset_btn = QPushButton(self.login_gbox)
self.remove_preset_btn.setObjectName("remove_preset_btn")
self.remove_preset_btn.setMaximumWidth(20)
login_gbox_presets_layout.addWidget(self.lb_presets)
login_gbox_presets_layout.addWidget(self.presets_cbox)
login_gbox_presets_layout.addWidget(self.add_preset_btn)
login_gbox_presets_layout.addWidget(self.remove_preset_btn)
self.lb_imap_server = QLabel(self.login_gbox)
self.lb_imap_server.setObjectName("lb_imap_server")
self.lb_imap_server.setMinimumWidth(lbMinWidthLogin)
self.imap_server_le = QLineEdit(self.login_gbox)
self.imap_server_le.setObjectName("imap_server_le")
login_gbox_server_layout.addWidget(self.lb_imap_server)
login_gbox_server_layout.addWidget(self.imap_server_le)
self.lb_ssl = QLabel(self.login_gbox)
self.lb_ssl.setObjectName("lb_ssl")
self.lb_ssl.setMinimumWidth(lbMinWidthLogin)
self.lb_ssl.setMaximumWidth(lbMinWidthLogin)
self.ssl_cb = QCheckBox(self.login_gbox)
self.ssl_cb.setEnabled(False)
self.ssl_cb.setCheckable(True)
self.ssl_cb.setChecked(True)
self.ssl_cb.setObjectName("ssl_cb")
login_gbox_ssl_layout.addWidget(self.lb_ssl)
login_gbox_ssl_layout.addWidget(self.ssl_cb)
self.lb_adress = QLabel(self.login_gbox)
self.lb_adress.setObjectName("lb_adress")
self.lb_adress.setMinimumWidth(lbMinWidthLogin)
self.adress_le = QLineEdit(self.login_gbox)
self.adress_le.setInputMethodHints(Qt.ImhNone)
self.adress_le.setObjectName("adress_le")
login_gbox_address_layout.addWidget(self.lb_adress)
login_gbox_address_layout.addWidget(self.adress_le)
self.lb_pass = QLabel(self.login_gbox)
self.lb_pass.setObjectName("lb_pass")
self.lb_pass.setMinimumWidth(lbMinWidthLogin)
self.pass_le = QLineEdit(self.login_gbox)
self.pass_le.setText("")
self.pass_le.setEchoMode(QLineEdit.Password)
self.pass_le.setObjectName("pass_le")
login_gbox_pass_layout.addWidget(self.lb_pass)
login_gbox_pass_layout.addWidget(self.pass_le)
self.connect_btn = QPushButton(self.login_gbox)
self.connect_btn.setObjectName("connect_btn")
login_gbox_connect_layout.addStretch()
login_gbox_connect_layout.addWidget(self.connect_btn)
# search_gbox
#.........这里部分代码省略.........