[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-panel-devel
Subject:    Re: [KWin - Dock Question] - How to hide a window from PresentWindows effect?
From:       Martin Graesslin <mgraesslin () kde ! org>
Date:       2016-12-11 19:42:33
Message-ID: 24292480.GspXC5KnAq () martin-desktop
[Download RAW message or body]


On Sunday, December 11, 2016 8:14:26 PM CET Michail Vourlakos wrote:
> On 11/12/2016 11:23 πμ, Martin Graesslin wrote:
> > On Sunday, December 11, 2016 10:11:14 AM CET Michail Vourlakos wrote:
> >> On 09/12/2016 06:30 μμ, Martin Graesslin wrote:
> >>> https://cgit.kde.org/plasma-framework.git/tree/src/plasmaquick/dialog.cp
> >>> p
> >>> 
> >>> the property in question is outputOnly. But it looks like that's only
> >>> using an input shape which might (?) not help you.
> >> 
> >> I ll' have a look Martin, thanks a lot again...
> >> 
> >>>> If I set :
> >>>> 
> >>>> KWindowSystem::setType(m_dockWindow->winId(), NET::Dock);
> >>>> 
> >>>> my dock is always on top and I can never lower it below normal
> >>>> windows..
> >>> 
> >>> Well yes, that's the idea of a Dock. Of course it's on top of all
> >>> windows. If you don't want that, don't use a dock.
> >>> 
> >>> On X11 KWin supports windows can cover through having a dock set to keep
> >>> below. But that won't work on Wayland and thus I heavily recommend
> >>> against it.
> >> 
> >> I want a Dock that lowers itself (becomes "Keep Below") based on
> >> criteria for example
> >> only when the Active window or a Maximimzed one is covering the dock.
> > 
> > This needs support from the window manager. You cannot do that from the
> > window side, I'm sorry. The stacking order supported by window managers
> > is explained in
> > https://specifications.freedesktop.org/wm-spec/wm-spec-latest.html#STACKI
> > NGORDER
> I added  a state in my code which can be used in wayland in which the
> various visibility states
> are not lowering the dock but instead they create an intelligent
> slide-out of the contents and
> then masking the window in order to give this space to underneath
> windows. So this is something
> like an intelligent auto-hide based on active windows or fullscreen windows.

Sounds good. On Wayland it should be way easier for us to support this case. 
At least we support changing types, etc. Which is not allowed on X11.

> I thought that libtaskmanager is accessing KWayland in order to track the
> active window and the windows geometries,

Yes, you can use either libtaskmanager or KWayland directly.

> isnt this possible to be used also from my code? the dock window is
> going to be always a dock type
> this way...
> 
> 
> 
> KWin is great but for my dock case has some limitations which are
> breaking a bit the experience:
> 1. plasma's auto-hide mode doesnt work good with my dock because when it
> is auto hidden it doesnt update its contents.

That's either a Qt or a OpenGL limitation. At least on X11 the window is still 
there, and still visible, just not rendered by KWin.

It's quite likely that Qt doesn't really understand what's going on and 
doesn't render because it thinks it's not visible.

> It is out of screen

it's not out of screen. It's just not rendered.

> thus the various animations for adding/removing
> tasks etc are playing when the dock is shown
> again.
> 2. pop ups in window type Dock are not calculated correctly in my dock
> case. KWin takes into account that because
> a window is a Dock all its space is used and shown always and thus show
> the various pop-ups from
> the plasmoids far away from the element that triggered them. My dock
> uses masking for its window and thus
> an element that triggers a pop-up can be far away from the edge of the
> window

That's not KWin either. That's Plasma. Plasma positions it's windows itself, 
KWin honors the position hints Plasma uses. If a Plasma window is misplaced, 
it's Plasma's fault. (You see I love blaming other projects :-P ) On Wayland 
we even go a step further and don't do any sanity checking on the positions 
Plasma provides. Normally windows on Wayland are always placed by the window 
manager, except for Plasma.

Cheers
Martin
["signature.asc" (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic