Questions tagged [qdockwidget]

QDockWidget is a class from the Qt framework which represents a widget which can be docked inside a QMainWindow or floated as a top-level window in the desktop. Instances of this class are also called "dock widgets", "tool palettes" and "utility windows".

Dock widgets can be placed (docked) in a special area of a QMainWindow called dock widget area, which is the area surrounding the central widget. They can also be floated (undocked) by the end user.

231 questions
5
votes
1 answer

Qt resize event for docks

Is there a way to catch resize events for docks in Qt? I need to be able to detect when a dock is resized (and not only when its location or 'features' change). It looks like there is no 'resized' signal for QDockWidget.
J. V.
  • 1,555
  • 1
  • 11
  • 17
5
votes
3 answers

Paint/Draw on top of docked widgets in QDodckWidget

I have a class in Qt that inherits QDockWidget. And that class contains another widget. Is there any possibility to define a function in my QDockWidget inherited class that draws stuff on top of the contained widget? Like the painting to be…
user1433602
4
votes
2 answers

Get reference of dock-widget added to QMainWindow

I use a software written using Qt and it has a QMainWindow object. I need to get the reference of a widget when added to QMainWindow object already exists. I have looked at Qt documentation. I hoped there was an event childAdded or something, but I…
Kadir Şahbaz
  • 418
  • 7
  • 21
4
votes
1 answer

QDockWidget::restoreGeometry not working correctly when QMainWindow is maximized

I have a number of QDockWidgets, all docked in a single QMainWindow. I have overridden the showEvent, and after passing the event on to the base class I am restoring the dock widget's geometry void DockWidget::showEvent(QShowEvent* ev) { …
Steve Lorimer
  • 27,059
  • 17
  • 118
  • 213
4
votes
4 answers

QDockWidget layout with no central widget

I have a problem with QDockWidget. I'm using Qt Designer, and I would like to build an app with only dock-widgets, and have a small bar above for properties. The problem is that I cannot build the app without a main QWidget (I mean with only…
4
votes
1 answer

How to disable/hide the Close button in a pyQt QDockWidget

Im trying to disable the close 'x' button, and I assumed that it would work by setting the DockWidgetFeature to only movable and floatable. def CreateDockWidget (self): Pane = QtGui.QDockWidget() Pane.DockWidgetFeatures = …
thefog
  • 181
  • 1
  • 4
  • 13
4
votes
1 answer

Disable splitter cursor for QDockWidget

I have the following widget structure. CDockWidgetInfoBar is just a QDockWidget derived class When I move over the QDockWidget (CDockWidgetInfoBar), I see this splitter cursor. Where is it coming from? Can I disable it? Is it part of…
Horst Walter
  • 13,663
  • 32
  • 126
  • 228
4
votes
1 answer

Auto resizing of contents of QDockWidget

I've created a dock widget which contains a QTreeView. The size of the tree view remains static when the dock is resized. How can I get it to change it's size automatically to fill the dock area? I've created the dock widget using the designer and…
Gayan
  • 1,697
  • 7
  • 26
  • 35
4
votes
2 answers

Tooltips for QDockWidget close button & float button?

Is there a way to set a tool tip text for the close button & float button in a QDockWidget ?
warunanc
  • 2,221
  • 1
  • 23
  • 40
4
votes
2 answers

PyQt how to get sender (widget) in closeEvent?

I'm trying to catch a closeEvent for several dockWidgets that get added dynamically to a QMainWindow. It is unclear to me how I can figure out which widget has been closed.. Here's an simplified example: class Example(QtGui.QMainWindow): def…
joplaete
  • 113
  • 1
  • 9
3
votes
2 answers

qdockwidget title bar font color

How to change the font color of the button text in qtoolbar and title bar text of qdockwidget. I have tried to change the font color using qt stylesheet color label, but it does not seem to work for qdockwidget::title bar and qdock tool bar.
Aashu
  • 51
  • 2
  • 6
3
votes
1 answer

Set top QDockWidget for a bunch of tabbified QDockWidgets

H there. Can someone please tell me how to set a tabbified QDockWidget to pop to the front (be the active dock)? In the picture below, the "full" tab is selected and it's contents are visible but I want to set the "mouth" tab to the selected tab and…
Jay
  • 3,373
  • 6
  • 38
  • 55
3
votes
1 answer

How to display RGB image in pyqt

I Have a image in RBG Mode, when i try to display it on qdockWidget, the image does not appear properly. I can print the image in "L" mode. what i am missing. Thanks in Advance :) Below is the code: from PyQt5 import QtWidgets, QtGui from…
3
votes
1 answer

How to add an image in pyqt qdock widget

I am trying to create a image viewer using pyqt. What i am trying is to create a qdockwidget to display the image. I have created the qPixmap objecte and tried to add it as a widget in qdockwidget. from PyQt5 import QtWidgets, QtGui from…
3
votes
3 answers

How to make Transparent QT Dock Widget

On Windows ,I am trying to create Qt application with transparent DOCKWIDGETS, where background of dock widget is transparent when it is floated. So we can see through dock widget. Currently it looks black as below. Code as below QDockWidget…
living on edge
  • 401
  • 1
  • 6
  • 13
1 2
3
15 16