awesome

Welcome to awesome bug tracking system.
Tasklist

FS#746 - Restore ontop property after returning from fullscreen

Attached to Project: awesome
Opened by David Engster (dengste) - Saturday, 13 March 2010, 17:27 GMT
Task Type Feature Request
Category Core
Status Unconfirmed
Assigned To No-one
Operating System Linux
Severity Low
Priority Normal
Reported Version git/master
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 0
Private No

Details

The current behavior is that when a client goes fullscreen and returns from that, its ontop property won't get restored. You can try this out the following way:

* I use the default rc.lua from current git HEAD (9f056716b9)
* Play a video using mplayer (window should be floating according to rule in rc.lua).
* Hit Mod4+t to make the window 'ontop'.
* Hit Mof4+f or just 'f' to make the window fullscreen. Then press Mod4+f or f again to return from fullscreen.
* Observer that mplayer window will not be ontop now.

I think it would be useful if the ontop property would be restored when returning from the fullscreen.
This task depends upon

Comment by Uli Schlachter (psychon) - Wednesday, 31 March 2010, 06:43 GMT
I can reproduce, the following is from awesome-client run in a terminal window:

awful.client.floating.toggle()
client.focus.ontop = true
client.focus.fullscreen = true
client.focus.fullscreen = false
return client.focus.ontop
boolean false
Comment by Uli Schlachter (psychon) - Wednesday, 31 March 2010, 06:46 GMT
Ohhhhh....

Looking at the source code in objects/client.c:

client_set_fullscreen(lua_State *L, int cidx, bool s)
{
[..]
/* become fullscreen! */
if(s)
{
/* remove any max state */
client_set_maximized_horizontal(L, cidx, false);
client_set_maximized_vertical(L, cidx, false);
/* You can only be part of one of the special layers. */
client_set_below(L, cidx, false);
client_set_above(L, cidx, false);
client_set_ontop(L, cidx, false);
[..]
client_set_ontop(lua_State *L, int cidx, bool s)
{
[..]
/* You can only be part of one of the special layers. */
if(s)
{
client_set_above(L, cidx, false);
client_set_below(L, cidx, false);
client_set_fullscreen(L, cidx, false);
[..]

Why can't a client not be fullscreen and ontop at the same time?
No idea what we can do about this. :/
Ideas?
Comment by David Engster (dengste) - Wednesday, 31 March 2010, 09:06 GMT
If a client cannot be fullscreen and ontop at the same time, the code should store the ontop property before going fullscreen, and restore it when returning to normal size.

Loading...