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. 回答1: If you do not wish to subclass to just get resize event control, you can installEventFilter Small example would look like ( MainWindow.h ): (MainWindow holds DockWidget Here) protected: bool eventFilter(QObject *obj, QEvent *event); and in ( MainWindow.cc ): MainWindow: