diff --git a/client.cpp b/client.cpp index 390231229b..b21a737bbb 100644 --- a/client.cpp +++ b/client.cpp @@ -448,7 +448,7 @@ void Client::layoutDecorationRects(QRect &left, QRect &top, QRect &right, QRect NETStrut strut = info->frameOverlap(); // Ignore the overlap strut when compositing is disabled - if (!compositing()) + if (!compositing() || !Workspace::self()->decorationSupportsFrameOverlap()) strut.left = strut.top = strut.right = strut.bottom = 0; else if (strut.left == -1 && strut.top == -1 && strut.right == -1 && strut.bottom == -1) { @@ -601,7 +601,8 @@ QRect Client::transparentRect() const return QRect(); NETStrut strut = info->frameOverlap(); - if (!compositing()) // Ignore the strut when compositing is disabled + // Ignore the strut when compositing is disabled or the decoration doesn't support it + if (!compositing() || !Workspace::self()->decorationSupportsFrameOverlap()) strut.left = strut.top = strut.right = strut.bottom = 0; else if (strut.left == -1 && strut.top == -1 && strut.right == -1 && strut.bottom == -1) return QRect(); diff --git a/workspace.h b/workspace.h index 759833ff60..b1281f2b27 100644 --- a/workspace.h +++ b/workspace.h @@ -383,6 +383,7 @@ class Workspace : public QObject, public KDecorationDefines bool hasDecorationShadows() const; bool decorationHasAlpha() const; bool decorationSupportsClientGrouping() const; // Returns true if the decoration supports tabs. + bool decorationSupportsFrameOverlap() const; // D-Bus interface void cascadeDesktop(); @@ -1257,6 +1258,11 @@ inline bool Workspace::decorationSupportsClientGrouping() const return mgr->factory()->supports( AbilityClientGrouping ); } +inline bool Workspace::decorationSupportsFrameOverlap() const + { + return mgr->factory()->supports( AbilityExtendIntoClientArea ); + } + inline void Workspace::addClientGroup( ClientGroup* group ) { clientGroups.append( group );