We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 1189 - SDL X11 does not export _NET_WM_PID property on window
Summary: SDL X11 does not export _NET_WM_PID property on window
Status: RESOLVED FIXED
Alias: None
Product: SDL
Classification: Unclassified
Component: video (show other bugs)
Version: HG 2.0
Hardware: x86_64 Linux
: P2 normal
Assignee: Marco Trevisan (Treviño)
QA Contact: Sam Lantinga
URL: https://bugs.launchpad.net/ubuntu/+so...
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-25 00:51 UTC by Jason Smith
Modified: 2012-01-06 23:08 UTC (History)
3 users (show)

See Also:


Attachments
X11: Added support to _NET_WM_PID and WM_CLIENT_MACHINE atoms (SDL-1.3) (2.65 KB, patch)
2011-06-27 10:53 UTC, Marco Trevisan (Treviño)
Details | Diff
X11: Move to XSetWMProperties and add support to _NET_WM_PID (SDL-1.3) (4.64 KB, patch)
2011-06-27 10:58 UTC, Marco Trevisan (Treviño)
Details | Diff
X11: Added support to _NET_WM_PID and WM_CLIENT_MACHINE atoms (SDL-1.2) (1.65 KB, patch)
2011-06-28 13:58 UTC, Marco Trevisan (Treviño)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Smith 2011-04-25 00:51:14 UTC
This property has grown in value in both GNOME Shell and Unity desktop environments. It is also quite useful to applications such as Docky, AWN, Cairo Dock, and others. _NET_WM_PID is simple to set and should have no drawbacks.
Comment 1 Marco Trevisan (Treviño) 2011-06-27 10:53:44 UTC
Created attachment 636 [details]
X11: Added support to _NET_WM_PID and WM_CLIENT_MACHINE atoms (SDL-1.3)

This is a first implementation of _NET_WM_PID support in SDL 1.3.

As stated by freedesktop specs [1], it also needs that the running hostname is set, and this is done via the WM_CLIENT_MACHINE atom.

This actually applies only to SDL 1.3. Patch for 1.2 coming.

[1] http://standards.freedesktop.org/wm-spec/1.3/ar01s05.html#id2523510
Comment 2 Marco Trevisan (Treviño) 2011-06-27 10:58:43 UTC
Created attachment 637 [details]
X11: Move to XSetWMProperties and add support to _NET_WM_PID (SDL-1.3)

This is another implementation of the same patch which is using XSetWMProperties to set the main window properties including size, input and class hints plus WM_LOCALE_NAME.

The _NET_WM_PID atom is also set as before.

Chose the implementation that you prefer (this is working for SDL-1.3 only too).
Comment 3 Marco Trevisan (Treviño) 2011-06-28 13:58:39 UTC
Created attachment 639 [details]
X11: Added support to _NET_WM_PID and WM_CLIENT_MACHINE atoms (SDL-1.2)

Here you are the patch for SDL-1.2, I've just used XChangeProperty with Atoms instead of the convenience functions XSetWMProperties or XSetWMClientMachine because they both would give errors when compiling SDL without special configuration parameters (I can attach them too if requested, BTW).

@Jason: I will send this also the patch to launchpad for being added to the libsdl1.2debian package.
Comment 4 Martin Pitt 2011-07-06 06:46:53 UTC
Reopening. This patch isn't in hg, and there is no indication why the bug was marked "fixed".
Comment 5 Sam Lantinga 2012-01-06 23:08:30 UTC
Thanks Marco, this was on the TODO list!
Your patches are applied to source control.