diff --git a/demo/MainWindow.cpp b/demo/MainWindow.cpp index cca3465..43a3a54 100644 --- a/demo/MainWindow.cpp +++ b/demo/MainWindow.cpp @@ -232,8 +232,9 @@ void MainWindowPrivate::createContent() // Test creation of floating dock widgets DockWidget = createFileSystemTreeDockWidget(ViewMenu); auto FloatingWidget = DockManager->addDockWidgetFloating(DockWidget); - FloatingWidget->move(QPoint(0,0)); + FloatingWidget->move(QPoint(0, 0)); FloatingWidget = DockManager->addDockWidgetFloating(createLongTextLabelDockWidget(ViewMenu)); + FloatingWidget->move(QPoint(100, 100)); auto Action = ui.menuView->addAction(QString("Set %1 floating").arg(DockWidget->windowTitle())); DockWidget->connect(Action, SIGNAL(triggered()), SLOT(setFloating())); @@ -326,7 +327,7 @@ CMainWindow::CMainWindow(QWidget *parent) : // uncomment the follwing line if you want to use non opaque undocking and splitter // moevements - //CDockManager::setConfigFlags(CDockManager::DefaultNonOpaqueConfig); + CDockManager::setConfigFlags(CDockManager::DefaultNonOpaqueConfig); // Now create the dock manager and its content d->DockManager = new CDockManager(this); diff --git a/src/FloatingDockContainer.cpp b/src/FloatingDockContainer.cpp index 0c9092d..5872ba7 100644 --- a/src/FloatingDockContainer.cpp +++ b/src/FloatingDockContainer.cpp @@ -509,7 +509,7 @@ void CFloatingDockContainer::startFloating(const QPoint &DragStartMousePos, #ifdef Q_OS_LINUX if (DraggingFloatingWidget == DragState) { - setAttribute(Qt::WA_X11NetWmWindowTypeDock, true); + setAttribute(Qt::WA_X11NetWmWindowTypeDock, true); d->MouseEventHandler = MouseEventHandler; if (d->MouseEventHandler) { diff --git a/src/FloatingOverlay.cpp b/src/FloatingOverlay.cpp index 6195e0d..f21ced2 100644 --- a/src/FloatingOverlay.cpp +++ b/src/FloatingOverlay.cpp @@ -177,6 +177,12 @@ CFloatingOverlay::CFloatingOverlay(QWidget* Content, QWidget* parent) : setAttribute(Qt::WA_TranslucentBackground); } +#ifdef Q_OS_LINUX + auto Flags = windowFlags(); + Flags |= Qt::WindowStaysOnTopHint | Qt::X11BypassWindowManagerHint; + setWindowFlags(Flags); +#endif + setWindowOpacity(0.6); // We install an event filter to detect mouse release events because we // do not receive mouse release event if the floating widget is behind