sanchay160887 / vacuum-im

Automatically exported from code.google.com/p/vacuum-im
GNU General Public License v3.0
0 stars 0 forks source link

Set WM_ROLE for the Main Window #553

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,
i am using xmonad with the IM Layout 
(http://xmonad.org/xmonad-docs/xmonad-contrib/XMonad-Layout-IM.html) and I 
would like to identify the main window properly.

Could you set the WM_ROLE of the Main Window? I added a patch, which should do 
that.

Thanks

Original issue reported on code.google.com by Peg...@gmail.com on 11 Jan 2012 at 4:56

Attachments:

GoogleCodeExporter commented 9 years ago
I use this configuration in KDE and its work fine.

http://img.susepaste.org/view/raw/14413819

Original comment by egd.f...@gmail.com on 11 Jan 2012 at 6:01

GoogleCodeExporter commented 9 years ago
Hm this is strange. 
xprop says, that the window class is "vacuum", "Vacuum" and not "vacuum-im" and 
there is no window role.

Output of xprop (of the main Window):
WM_STATE(WM_STATE):
        window state: Normal
        icon window: 0x0
_NET_WM_USER_TIME(CARDINAL) = 59023605
_NET_WM_SYNC_REQUEST_COUNTER(CARDINAL) = 18874383
_NET_WM_ICON(CARDINAL) =    Icon (16 x 16):

[ICONS]

XdndAware(ATOM) = BITMAP
_MOTIF_DRAG_RECEIVER_INFO(_MOTIF_DRAG_RECEIVER_INFO) = 0x6c, 0x0, 0x5, 0x0, 
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x10, 0x0, 0x0, 0x0
_NET_WM_NAME(UTF8_STRING) = "Vacuum-IM - Default"
WM_CLIENT_LEADER(WINDOW): window id # 0x1200005
_NET_WM_PID(CARDINAL) = 23263
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_NORMAL
_MOTIF_WM_HINTS(_MOTIF_WM_HINTS) = 0x3, 0x26, 0x1e, 0x0, 0x0
WM_PROTOCOLS(ATOM): protocols  WM_DELETE_WINDOW, WM_TAKE_FOCUS, _NET_WM_PING, 
_NET_WM_SYNC_REQUEST
WM_NAME(STRING) = "Vacuum-IM - Default"
WM_LOCALE_NAME(STRING) = "de_DE.UTF-8"
WM_CLASS(STRING) = "vacuum", "Vacuum"
WM_HINTS(WM_HINTS):
        Client accepts input or input focus: True
        Initial state is Normal State.
        bitmap id # to use for icon: 0x120000c
        window id # of group leader: 0x1200005
WM_NORMAL_HINTS(WM_SIZE_HINTS):
        user specified location: 1536, 16
        program specified location: 1536, 16
        user specified size: 382 by 1182
        program specified size: 382 by 1182
        program specified minimum size: 89 by 153
        window gravity: NorthWest
WM_CLIENT_MACHINE(STRING) = "DS1"
WM_COMMAND(STRING) = { "vacuum" }

Adding 'setWindowRole("main_window");' to the MainWindow Constructor works fine.

Original comment by Peg...@gmail.com on 11 Jan 2012 at 10:10

GoogleCodeExporter commented 9 years ago
Value for window role should be exactly "main_window" or I can set any other 
value?

Original comment by potapov.s.a on 16 Jan 2012 at 4:03

GoogleCodeExporter commented 9 years ago
I would set it to "main_window", because the window is called "main window",but 
 "roster", "buddy_list" or something else would also work. Just something, that 
describes the "role" of the window.

Original comment by Peg...@gmail.com on 16 Jan 2012 at 4:20

GoogleCodeExporter commented 9 years ago
Issue 557 has been merged into this issue.

Original comment by potapov.s.a on 24 Jan 2012 at 10:12

GoogleCodeExporter commented 9 years ago

Original comment by potapov.s.a on 24 Jan 2012 at 10:12

GoogleCodeExporter commented 9 years ago
fixed in r1711

Original comment by potapov.s.a on 27 Jan 2012 at 4:59