本文整理匯總了Python中PySide.QtGui.QFrame.isHidden方法的典型用法代碼示例。如果您正苦於以下問題:Python QFrame.isHidden方法的具體用法?Python QFrame.isHidden怎麽用?Python QFrame.isHidden使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類PySide.QtGui.QFrame
的用法示例。
在下文中一共展示了QFrame.isHidden方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: window
# 需要導入模塊: from PySide.QtGui import QFrame [as 別名]
# 或者: from PySide.QtGui.QFrame import isHidden [as 別名]
#.........這裏部分代碼省略.........
sequence = QKeySequence(Qt.CTRL + Qt.ALT + Qt.Key_U)
QShortcut(sequence, self, self.handleShowInspector)
# make an accelerator to toggle bookmark
sequence = QKeySequence(Qt.CTRL + Qt.Key_D)
QShortcut(sequence, self, self.bookmark)
# make an accelerator to toggle task/project-list
sequence = QKeySequence(Qt.CTRL + Qt.SHIFT + Qt.Key_L)
QShortcut(sequence, self, self.toggleTaskBar)
# finally set the attribute need to rotate
# try:
# self.setAttribute(Qt.WA_Maemo5AutoOrientation, True)
# except:
# print "not maemo"
self.statusbar.show()
def press_button(self):
"""On button press. Connected."""
self.sender().setStyleSheet('background-color: rgba(228, 228, 228)')
def release_button(self):
"""On button release. Connected."""
self.sender().setStyleSheet('background-color: rgba(252, 252, 252)')
def goHome(self):
"""Go to startpage."""
self.tabs.currentWidget().findChild(QFrame, unicode('pageWidget')).findChild(QWebView, unicode('webView')).setUrl(QUrl(self.startpage))
def handleShowInspector(self):
"""Toggle web inspector."""
self.tabs.currentWidget().findChild(QFrame, unicode('pageWidget')).findChild(QWebInspector, unicode('webInspector')).setShown(self.tabs.currentWidget().findChild(QFrame, unicode('pageWidget')).findChild(QWebInspector, unicode('webInspector')).isHidden())
def toggleTaskBar(self):
"""Toggle task bar."""
if self.tabs.currentWidget().findChild(QTreeView, unicode('taskList')).isHidden():
self.tabs.currentWidget().findChild(QTreeView, unicode('taskList')).setModel(self.tasklist)
self.tabs.currentWidget().findChild(QTreeView, unicode('taskList')).setShown(self.tabs.currentWidget().findChild(QTreeView, unicode('taskList')).isHidden())
#self.tasklist.setShown(self.tasklist.isHidden())
def focus_adress(self):
"""Focus adress bar."""
self.edit.selectAll()
self.edit.setFocus()
def toggle_input(self):
"""Toggle input visibility."""
if self.input_widget.isVisible():
visible = False
else:
visible = True
self.input_widget.setVisible(visible)
def toggle_fullscreen(self):
"""Toggle fullscreen."""
if self.isFullScreen():
self.showNormal()
else:
self.showFullScreen()
self.change_tab()
def linkHover(self, l):
"""Show link adress in status bar on mouse hover."""
self.statusbar.showMessage(l)