How do I hide the window title bar from QDockWidget
-
@mrjj said in How do I hide the window title bar from QTabWidget:
setContentsMargins(0,0,0,0);
I would guess that the OP call that on the widget, not the layout...
Ah...maybe not...
I'm not sure what's the current situation now. I thought the gap in the later picture would be that titlebar? -
@Yunus
Hi
Sadly not. That flag removes the decorations. ( the frame) and those are used by the OS to resize.
It's possible to hand code it but it's hard work.
Often people use less code-intensive solution and allow resize from right, bottom corner only.
Using this class
https://doc.qt.io/qt-6/qsizegrip.html -
Hi
There is also
https://github.com/dfct/TrueFramelessWindow
which supports most features like resizing and dragging -
I want to hide the default "window title" bar that's on top of the dockwidget.
@lansing,
stackoverflow.com/revisions/21701604/1
should work:dockWidget->setTitleBarWidget(new QWidget());
Otherwise, maybe follow
stackoverflow.com/q/18918496
.