[PyQt] DockWidget hide title bar

Vincent Vande Vyvre vincent.vandevyvre at swing.be
Tue Apr 13 10:29:31 BST 2010


Hi,

There's a way to hide the title bar in a dock widget ?

I see in :

http://www.riverbankcomputing.co.uk/static/Docs/PyQt4/html/qdockwidget.html#setTitleBarWidget

" ...If widget is 0, the title bar widget is removed, but not deleted."

Argument 0 return an error, if I replace it by None, there's no more
error but the title bar
is not hidden.


    self.dock_text = QtGui.QDockWidget(MainWindow)
    self.dock_text.setAllowedAreas(QtCore.Qt.BottomDockWidgetArea)
    self.dock_text.setFeatures(QtGui.QDockWidget.NoDockWidgetFeatures)
    self.dock_text.setTitleBarWidget(None)

Thanks for all ideas, vincent



More information about the PyQt mailing list