New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Window Title glitch in some programs and during rename #263

Closed
g4jc opened this Issue Dec 8, 2015 · 5 comments

Comments

Projects
None yet
2 participants
@g4jc

g4jc commented Dec 8, 2015

Hello!
I ran into an unusual bug while using JWM, which is reproducible. This bug does not occur in other Window managers, such as OpenBox.

The best program to test this with is e-Sword in wine, since the application spawns new Windows and attempts to change the window title. Once this occurs, the Window Title is completely gone, and in the case of e-Sword (older v8 used in this test), even the icon is gone. Therefore, once the e-Sword window is minimized, it cannot be recovered, maximized, or controlled without killing the process and starting it again.

Here's a log of what's going on:

~$ wine e-sword.exe
~$ wmctrl -lp
0x01600002 0 1580 pc e-Sword
0x01600004 0 1580 pc e-Sword - the Sword of the LORD with an electronic edge
~$ echo "Note: At this point there are no windows showing in the JWM tray, not even an icon! Attempting to rename..."
~$ xdotool search --name "e-Sword" set_window --name "AnythingThatWorks"
~$ xdotool search --name "e-Sword - the Sword of the LORD with an electronic edge" set_window --name "AnythingThatWorks"
~$ wmctrl -lp
0x01600002 0 1580 pc AnythingThatWorks
0x01600004 0 1580 pc AnythingThatWorks
~$ echo "Still nothing in the JWM tray, useless effort, let's try something else"
~$ dosbox
~$ echo "This window displays 'DOSBox' as it's title and seems to work"
~$ xdotool search --name "DOSBox" set_window --name "MyDosGame"
~$ echo "DOSBox Title just disappeared! Restarting JWM has no effect. At least there is still an icon clickable in JWM tray but our title never set properly in JWM."

@joewing

This comment has been minimized.

Show comment
Hide comment
@joewing

joewing Dec 9, 2015

Owner

I don't have wine or related programs, so this is difficult for me to test directly.
It sounds like the window is setting _NET_WM_STATE_SKIP_TASKBAR, in which case JWM will not show the window in the task bar (xprop should be able to confirm). If so, wmctrl should be able to remove that setting.

Owner

joewing commented Dec 9, 2015

I don't have wine or related programs, so this is difficult for me to test directly.
It sounds like the window is setting _NET_WM_STATE_SKIP_TASKBAR, in which case JWM will not show the window in the task bar (xprop should be able to confirm). If so, wmctrl should be able to remove that setting.

@g4jc

This comment has been minimized.

Show comment
Hide comment
@g4jc

g4jc Dec 9, 2015

There are two windows spawned, the first window (0x01c00001) is a splash screen - which is supposed to skip the taskbar before disappearing. The second window is the actual program. Here's the information I was able to find. I tried using xprop -remove _NET_WM_STATE_SKIP_TASKBAR, but it didn't seem to work for the main window (0x01c00003).

~$ wmctrl -lxp
0x01c00001 0 1052 e-sword.exe.Wine pc e-Sword
0x01c00003 0 1052 e-sword.exe.Wine pc e-Sword - the Sword of the LORD with an electronic edge
~$ xprop -id 0x01c00001
_NET_WM_WINDOW_OPACITY(CARDINAL) = 2147483648
_NET_WM_ALLOWED_ACTIONS(ATOM) = _NET_WM_ACTION_SHADE, _NET_WM_ACTION_CLOSE, _NET_WM_ACTION_MOVE, _NET_WM_ACTION_CHANGE_DESKTOP, _NET_WM_ACTION_STICK, _NET_WM_ACTION_BELOW, _NET_WM_ACTION_ABOVE
_NET_FRAME_EXTENTS(CARDINAL) = 0, 0, 0, 0
WM_STATE(WM_STATE):
window state: Normal
icon window: 0x0
_NET_WM_DESKTOP(CARDINAL) = 0
_NET_WM_STATE(ATOM) = _NET_WM_STATE_SKIP_TASKBAR, _NET_WM_STATE_SKIP_PAGER
_NET_WM_ICON(CARDINAL) = Icon (32 x 32):

          ?????????             
        ?????????????           
       ?????      ?????         
      ????          ????        
     ???             ????       
    ???     ?????     ???       
   ????   ?????????    ???      
   ???   ???????????   ???? ??  
  ????  ?????????????   ??????? 
  ??? ???????????????   ????????
  ????????????????????????????? 
  ?????             ??????????  
  ???               ????????    
  ???   ????????????????????    
  ???????????????????  ?????    
  ???????????????? ?   ?????    
  ???????????????     ?????     
  ??????????????     ??????     
   ???????????     ???????      
   ?????????       ???????      
    ???????         ?????       
     ?????      ?  ??????       
      ??      ?????????         
    ???      ?????????          
   ???     ??????????           
   ?       ????????             
  ?                             




Icon (16 x 16):

     ?????      
   ???   ??     
  ??      ??    
  ?? ????? ??   
 ?? ????????????
 ?? ??????????? 
 ?? ??????????  
 ????????? ???  
 ???????  ???   
  ????   ????   
  ???    ???    
      ?????     
      ????      

_NET_WM_NAME(UTF8_STRING) = "e-Sword"
WM_ICON_NAME(STRING) = "e-Sword"
WM_NAME(STRING) = "e-Sword"
WM_HINTS(WM_HINTS):
Client accepts input or input focus: False
Initial state is Normal State.
bitmap id # to use for icon: 0x1a0001a
bitmap id # of mask for icon: 0x1a0001c
window id # of group leader: 0x1c00001
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_NORMAL
_MOTIF_WM_HINTS(_MOTIF_WM_HINTS) = 0x3, 0x34, 0x0, 0x0, 0x0
WM_NORMAL_HINTS(WM_SIZE_HINTS):
program specified location: 960, 540
program specified minimum size: 1 by 1
program specified maximum size: 1 by 1
window gravity: Static
_NET_WM_USER_TIME_WINDOW(WINDOW): window id # 0x1a0000b
XdndAware(ATOM) = BITMAP
_NET_WM_PID(CARDINAL) = 1052
WM_LOCALE_NAME(STRING) = "en_US.UTF-8"
WM_CLIENT_MACHINE(STRING) = "pc"
WM_CLASS(STRING) = "e-sword.exe", "Wine"
WM_PROTOCOLS(ATOM): protocols WM_DELETE_WINDOW, _NET_WM_PING, WM_TAKE_FOCUS
~$ xprop -id 0x01c00003
_NET_WM_ALLOWED_ACTIONS(ATOM) = _NET_WM_ACTION_SHADE, _NET_WM_ACTION_MINIMIZE, _NET_WM_ACTION_MAXIMIZE_HORZ, _NET_WM_ACTION_MAXIMIZE_VERT, _NET_WM_ACTION_FULLSCREEN, _NET_WM_ACTION_CLOSE, _NET_WM_ACTION_RESIZE, _NET_WM_ACTION_MOVE, _NET_WM_ACTION_CHANGE_DESKTOP, _NET_WM_ACTION_STICK, _NET_WM_ACTION_BELOW, _NET_WM_ACTION_ABOVE
_NET_FRAME_EXTENTS(CARDINAL) = 5, 5, 21, 5
WM_STATE(WM_STATE):
window state: Normal
icon window: 0x0
_NET_WM_DESKTOP(CARDINAL) = 0
_NET_WM_STATE(ATOM) =
_NET_WM_ICON(CARDINAL) = Icon (32 x 32):

          ?????????             
        ?????????????           
       ?????      ?????         
      ????          ????        
     ???             ????       
    ???     ?????     ???       
   ????   ?????????    ???      
   ???   ???????????   ???? ??  
  ????  ?????????????   ??????? 
  ???   ?????????????   ????????
  ???   ??????????????????????? 
  ???               ??????????  
  ???               ????????    
  ???   ????????????????????    
  ???????????????????  ?????    
  ????????????????     ?????    
  ???????????????     ?????     
  ??????????????     ??????     
   ???????????     ???????      
   ?????????       ???????      
    ???????         ?????       
     ?????      ?  ??????       
      ??      ?????????         
    ???      ?????????          
   ???     ??????????           
   ?       ????????             
  ?                             

_NET_WM_NAME(UTF8_STRING) = "e-Sword - the Sword of the LORD with an electronic edge"
WM_ICON_NAME(STRING) = "e-Sword - the Sword of the LORD with an electronic edge"
WM_NAME(STRING) = "e-Sword - the Sword of the LORD with an electronic edge"
WM_HINTS(WM_HINTS):
Client accepts input or input focus: False
Initial state is Normal State.
bitmap id # to use for icon: 0x1a00440
bitmap id # of mask for icon: 0x1a00442
window id # of group leader: 0x1c00001
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_NORMAL
WM_TRANSIENT_FOR(WINDOW): window id # 0x1c00001
_MOTIF_WM_HINTS(_MOTIF_WM_HINTS) = 0x3, 0x3e, 0x7e, 0x0, 0x0
WM_NORMAL_HINTS(WM_SIZE_HINTS):
program specified location: 5, 23
window gravity: Static
_NET_WM_USER_TIME_WINDOW(WINDOW): window id # 0x1a0000b
XdndAware(ATOM) = BITMAP
_NET_WM_PID(CARDINAL) = 1052
WM_LOCALE_NAME(STRING) = "en_US.UTF-8"
WM_CLIENT_MACHINE(STRING) = "pc"
WM_CLASS(STRING) = "e-sword.exe", "Wine"
WM_PROTOCOLS(ATOM): protocols WM_DELETE_WINDOW, _NET_WM_PING, WM_TAKE_FOCUS

g4jc commented Dec 9, 2015

There are two windows spawned, the first window (0x01c00001) is a splash screen - which is supposed to skip the taskbar before disappearing. The second window is the actual program. Here's the information I was able to find. I tried using xprop -remove _NET_WM_STATE_SKIP_TASKBAR, but it didn't seem to work for the main window (0x01c00003).

~$ wmctrl -lxp
0x01c00001 0 1052 e-sword.exe.Wine pc e-Sword
0x01c00003 0 1052 e-sword.exe.Wine pc e-Sword - the Sword of the LORD with an electronic edge
~$ xprop -id 0x01c00001
_NET_WM_WINDOW_OPACITY(CARDINAL) = 2147483648
_NET_WM_ALLOWED_ACTIONS(ATOM) = _NET_WM_ACTION_SHADE, _NET_WM_ACTION_CLOSE, _NET_WM_ACTION_MOVE, _NET_WM_ACTION_CHANGE_DESKTOP, _NET_WM_ACTION_STICK, _NET_WM_ACTION_BELOW, _NET_WM_ACTION_ABOVE
_NET_FRAME_EXTENTS(CARDINAL) = 0, 0, 0, 0
WM_STATE(WM_STATE):
window state: Normal
icon window: 0x0
_NET_WM_DESKTOP(CARDINAL) = 0
_NET_WM_STATE(ATOM) = _NET_WM_STATE_SKIP_TASKBAR, _NET_WM_STATE_SKIP_PAGER
_NET_WM_ICON(CARDINAL) = Icon (32 x 32):

          ?????????             
        ?????????????           
       ?????      ?????         
      ????          ????        
     ???             ????       
    ???     ?????     ???       
   ????   ?????????    ???      
   ???   ???????????   ???? ??  
  ????  ?????????????   ??????? 
  ??? ???????????????   ????????
  ????????????????????????????? 
  ?????             ??????????  
  ???               ????????    
  ???   ????????????????????    
  ???????????????????  ?????    
  ???????????????? ?   ?????    
  ???????????????     ?????     
  ??????????????     ??????     
   ???????????     ???????      
   ?????????       ???????      
    ???????         ?????       
     ?????      ?  ??????       
      ??      ?????????         
    ???      ?????????          
   ???     ??????????           
   ?       ????????             
  ?                             




Icon (16 x 16):

     ?????      
   ???   ??     
  ??      ??    
  ?? ????? ??   
 ?? ????????????
 ?? ??????????? 
 ?? ??????????  
 ????????? ???  
 ???????  ???   
  ????   ????   
  ???    ???    
      ?????     
      ????      

_NET_WM_NAME(UTF8_STRING) = "e-Sword"
WM_ICON_NAME(STRING) = "e-Sword"
WM_NAME(STRING) = "e-Sword"
WM_HINTS(WM_HINTS):
Client accepts input or input focus: False
Initial state is Normal State.
bitmap id # to use for icon: 0x1a0001a
bitmap id # of mask for icon: 0x1a0001c
window id # of group leader: 0x1c00001
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_NORMAL
_MOTIF_WM_HINTS(_MOTIF_WM_HINTS) = 0x3, 0x34, 0x0, 0x0, 0x0
WM_NORMAL_HINTS(WM_SIZE_HINTS):
program specified location: 960, 540
program specified minimum size: 1 by 1
program specified maximum size: 1 by 1
window gravity: Static
_NET_WM_USER_TIME_WINDOW(WINDOW): window id # 0x1a0000b
XdndAware(ATOM) = BITMAP
_NET_WM_PID(CARDINAL) = 1052
WM_LOCALE_NAME(STRING) = "en_US.UTF-8"
WM_CLIENT_MACHINE(STRING) = "pc"
WM_CLASS(STRING) = "e-sword.exe", "Wine"
WM_PROTOCOLS(ATOM): protocols WM_DELETE_WINDOW, _NET_WM_PING, WM_TAKE_FOCUS
~$ xprop -id 0x01c00003
_NET_WM_ALLOWED_ACTIONS(ATOM) = _NET_WM_ACTION_SHADE, _NET_WM_ACTION_MINIMIZE, _NET_WM_ACTION_MAXIMIZE_HORZ, _NET_WM_ACTION_MAXIMIZE_VERT, _NET_WM_ACTION_FULLSCREEN, _NET_WM_ACTION_CLOSE, _NET_WM_ACTION_RESIZE, _NET_WM_ACTION_MOVE, _NET_WM_ACTION_CHANGE_DESKTOP, _NET_WM_ACTION_STICK, _NET_WM_ACTION_BELOW, _NET_WM_ACTION_ABOVE
_NET_FRAME_EXTENTS(CARDINAL) = 5, 5, 21, 5
WM_STATE(WM_STATE):
window state: Normal
icon window: 0x0
_NET_WM_DESKTOP(CARDINAL) = 0
_NET_WM_STATE(ATOM) =
_NET_WM_ICON(CARDINAL) = Icon (32 x 32):

          ?????????             
        ?????????????           
       ?????      ?????         
      ????          ????        
     ???             ????       
    ???     ?????     ???       
   ????   ?????????    ???      
   ???   ???????????   ???? ??  
  ????  ?????????????   ??????? 
  ???   ?????????????   ????????
  ???   ??????????????????????? 
  ???               ??????????  
  ???               ????????    
  ???   ????????????????????    
  ???????????????????  ?????    
  ????????????????     ?????    
  ???????????????     ?????     
  ??????????????     ??????     
   ???????????     ???????      
   ?????????       ???????      
    ???????         ?????       
     ?????      ?  ??????       
      ??      ?????????         
    ???      ?????????          
   ???     ??????????           
   ?       ????????             
  ?                             

_NET_WM_NAME(UTF8_STRING) = "e-Sword - the Sword of the LORD with an electronic edge"
WM_ICON_NAME(STRING) = "e-Sword - the Sword of the LORD with an electronic edge"
WM_NAME(STRING) = "e-Sword - the Sword of the LORD with an electronic edge"
WM_HINTS(WM_HINTS):
Client accepts input or input focus: False
Initial state is Normal State.
bitmap id # to use for icon: 0x1a00440
bitmap id # of mask for icon: 0x1a00442
window id # of group leader: 0x1c00001
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_NORMAL
WM_TRANSIENT_FOR(WINDOW): window id # 0x1c00001
_MOTIF_WM_HINTS(_MOTIF_WM_HINTS) = 0x3, 0x3e, 0x7e, 0x0, 0x0
WM_NORMAL_HINTS(WM_SIZE_HINTS):
program specified location: 5, 23
window gravity: Static
_NET_WM_USER_TIME_WINDOW(WINDOW): window id # 0x1a0000b
XdndAware(ATOM) = BITMAP
_NET_WM_PID(CARDINAL) = 1052
WM_LOCALE_NAME(STRING) = "en_US.UTF-8"
WM_CLIENT_MACHINE(STRING) = "pc"
WM_CLASS(STRING) = "e-sword.exe", "Wine"
WM_PROTOCOLS(ATOM): protocols WM_DELETE_WINDOW, _NET_WM_PING, WM_TAKE_FOCUS

@joewing

This comment has been minimized.

Show comment
Hide comment
@joewing

joewing Dec 10, 2015

Owner

From the output of xprop, the main window is transient for the splash screen (WM_TRANSIENT_FOR(WINDOW): window id # 0x1c00001), which seems strange.
The splash window itself is a 1x1 window without a border that skips the pager and task bar.

The problem is that, because the window is transient for the splash window, it won't appear in the task bar (JWM doesn't shown transients in the task bar). Of course, the main window (from JWM's perspective) also skips the task bar.

I think this is a problem with wine more than anything. I could add a group option to explicitly show a window in the task bar/pager (to go along with the existing nolist and nopager options).

Owner

joewing commented Dec 10, 2015

From the output of xprop, the main window is transient for the splash screen (WM_TRANSIENT_FOR(WINDOW): window id # 0x1c00001), which seems strange.
The splash window itself is a 1x1 window without a border that skips the pager and task bar.

The problem is that, because the window is transient for the splash window, it won't appear in the task bar (JWM doesn't shown transients in the task bar). Of course, the main window (from JWM's perspective) also skips the task bar.

I think this is a problem with wine more than anything. I could add a group option to explicitly show a window in the task bar/pager (to go along with the existing nolist and nopager options).

@g4jc

This comment has been minimized.

Show comment
Hide comment
@g4jc

g4jc Jan 2, 2016

The new group option sounds like a good idea to override wine applications that don't work properly.
Other WMs such as Xfce4/LXQt show the program's icon in the bottom left of the screen when it is shrunk, while not showing the window title.

g4jc commented Jan 2, 2016

The new group option sounds like a good idea to override wine applications that don't work properly.
Other WMs such as Xfce4/LXQt show the program's icon in the bottom left of the screen when it is shrunk, while not showing the window title.

@joewing joewing added this to the Version 2.3.5 milestone Jan 6, 2016

@joewing joewing added the enhancement label Jan 6, 2016

@joewing

This comment has been minimized.

Show comment
Hide comment
@joewing

joewing Jan 6, 2016

Owner

New group options are available as of snapshot 1362. ilist causes JWM to ignore the program-specified task list setting and ipager causes JWM to ignore the program-specified pager setting. I think this is probably the best way to deal with the issue without having JWM completely ignore what a program specifies. For example, some programs place an icon in the notification area (JWM dock) and, therefore, don't want an entry in the task list when minimized.

Owner

joewing commented Jan 6, 2016

New group options are available as of snapshot 1362. ilist causes JWM to ignore the program-specified task list setting and ipager causes JWM to ignore the program-specified pager setting. I think this is probably the best way to deal with the issue without having JWM completely ignore what a program specifies. For example, some programs place an icon in the notification area (JWM dock) and, therefore, don't want an entry in the task list when minimized.

@joewing joewing closed this Mar 5, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment