Notes from "New OSD in Plasma 2"
Martin Graesslin
mgraesslin at kde.org
Sat Jan 18 11:25:44 UTC 2014
On Monday 13 January 2014 18:46:28 Martin Klapetek wrote:
> Hey all,
>
> following are the notes from the "New OSD in Plasma 2" discussion we had
> here at the Plasma sprint.
>
> The basic idea is that the shell should provide a way for certain apps to
> display a short passive transient notification. That includes things like
> when user changes brightness, volume, changes the keyboard layout, virtual
> desktop or activity and possibly few others.
>
> This would be handled over DBus with custom QML files doing the rendering.
> The flow is as follows: user changes volume - kmix sends a dbus signal -
> plasma has a slot handling that signal - plasma loads the QML file for
> rendering and puts it on screen with special window class - kwin gives it
> extra love cause of the win class.
I had some thought on the "KWin gives it extra love" and how we can identify
the window. The preferred way on my side would be a window type and there is
one existing type which we might reuse: _NET_WM_WINDOW_TYPE_NOTIFICATION [1].
We have complete support for it in KWin and KWindowsystem as NET::Notification
in NET::WindowTypes enum. KWin recognizes the notification and does nothing
with it [2]. To be more precise KWin does not support the window type for
managed windows, only for override redirect windows. That's easy to change,
though.
Adding support for it in the PlasmaCore.Dialog should be simple. It already
has a WindowType enum which just needs another value for Notification.
In KDE software it is used in Krita and Amarok for a notification (in case of
Amarok it's the OSD). Other uses I couldn't find on my system. I failed with
lxr, maybe someone else is more apt at using that tool ;-)
The special love KWin could give the OSD is to put it into an own layer. The
recommendation for stacking orders does not contain notifications [3]. The
question is where to put it. In my opinion it should be above keep above and
dock windows, but I'm unsure whether it should be above active fullscreen
windows or below. Personally I'm always annoyed by the screen brightness
notification on top of a video. Given that I suggest that we introduce a new
layer between keep above and active fullscreen windows.
Comments?
Cheers
Martin
[1] http://standards.freedesktop.org/wm-spec/wm-spec-1.4.html#id2560306
[2] Exception: the glide effect excludes notifications from animation
[3] http://standards.freedesktop.org/wm-spec/wm-spec-1.4.html#STACKINGORDER
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20140118/4a7787f8/attachment.sig>
More information about the Plasma-devel
mailing list