-
Notifications
You must be signed in to change notification settings - Fork 598
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
Clients with fullscreen hint does not open in fullscreen #3834
Comments
Hello @akinokonomi, Do you have some configurations/rules that could be interfering? Can you try again with the default I have just downloaded a random youtube video and tried your command |
Hi!
Nope. I've mentioned it, but I've already tested it with the default config (default rules). It's still the same. I've also tested it as cleanly as possible, with all env variables unset, etc.
Thank you very much for testing it yourself. I see. Maybe it's due to changes in dependencies? Here is part from the build log log
Or perhaps it's something else entirely. |
the build log a bit weird, but i don't think it's related. however more weird looks that you building awesome with lua 5.4 but running with luajit - but again it doesn't seems related to this particular issue. see here for tested example of working luajit build commands: https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=awesome-luajit-git so, aside from testing with default awesome config, please also try running mpv itself with default config and without any extra user-scripts |
@actionless, Sorry for the confusion. It's because I specifically rebuilt it with lua 5.4. I already mentioned, but though
Yeah, I did that, nothing changed. Again, mpv is just an example, it happens with some other applications too. Though there are also many applications where fullscreen works fine, like |
it starts floating even if you're on tiling layout? do you have 1 or more displays? |
there is some weird bug sometimes similar to your problem - when starting an app for the first time - sometimes it have such behavior and hitting mod+m twice usually fixing it once for ever - i dunno about the details since it happens very ocasionally and hard to reproduce, but mb it's your case actually |
Yeah, that's right. (Sorry, I forgot to explain that.)
One.
Sounds very similar, but hitting mod+f twice fixes it until I start it again.
In my case, it happens every single time I start the application. |
I wrote this first study case: diff --git a/tests/_client.lua b/tests/_client.lua
index 3eb015f31..d29bfc8ff 100644
--- a/tests/_client.lua
+++ b/tests/_client.lua
@@ -13,7 +13,7 @@ local test_client_source = [[
pcall(require, 'luarocks.loader')
local lgi = require 'lgi'
local GLib = lgi.require('GLib')
-local Gdk = lgi.require('Gdk')
+local Gdk = lgi.require('Gdk', '3.0')
local Gtk = lgi.require('Gtk', '3.0')
local Gio = lgi.require('Gio')
Gtk.init()
@@ -65,6 +65,9 @@ local function open_window(class, title, options)
tonumber(options.resize_after_width), tonumber(options.resize_after_height)
)
end
+ if options.fullscreen then
+ window:fullscreen()
+ end
end
local function parse_options(options)
@@ -218,6 +221,10 @@ local function new(_, class, title, sn_rules, callback, resize_increment, args)
options = options .. "gravity=" .. args.gravity .. ","
end
+ if args.fullscreen then
+ options = options .. "fullscreen,"
+ end
+
local data = class .. "\n" .. title .. "\n" .. options .. "\n"
local success, msg = pipe:write_all(data)
assert(success, tostring(msg))
diff --git a/tests/test-mpv-fullscreen.lua b/tests/test-mpv-fullscreen.lua
new file mode 100644
index 000000000..7366566fe
--- /dev/null
+++ b/tests/test-mpv-fullscreen.lua
@@ -0,0 +1,40 @@
+local runner = require "_runner"
+-- local test_client = require "_client"
+local spawn = require "awful.spawn"
+
+local c = nil
+
+runner.run_steps {
+ -- Spawns the a client
+ function(count)
+ if count == 1 then
+ -- test_client(nil, nil, nil, nil, nil, {
+ -- fullscreen = true,
+ -- })
+ spawn("mpv --fullscreen --player-operation-mode=pseudo-gui --pause '/home/aireone/downloads/Zig in 100 Seconds [kxT8-C1vmd4].webm'")
+ end
+ c = client.get()[1]
+ return c
+ end,
+ -- Test the client is fullscreen
+ function()
+ print(c.x, c.y, c.width, c.height, c.fullscreen, c.floating, c.maximized, c.maximized_horizontal, c.maximized_vertical)
+ assert(c.fullscreen)
+ local s = screen.primary.geometry
+ print(s.x, s.y, s.width, s.height)
+ assert(
+ c.x == s.x
+ and c.y == s.y
+ and c.width == s.width
+ and c.height == s.height
+ )
+ return true
+ end,
+ -- Clean up
+ function()
+ c:kill()
+ return true
+ end,
+}
+
+-- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80 Working with a GTK window was actually a solid success. So I tried my luck by invoking mpv and got the following fail:
MPV starts as both fullscreen and floating. It is placed with a Y margin of 18, probably to be after the wibar. Which is not normal for a fullscreen client. (Strangely, this behavior doesn't happen when I start a session from the default The next step for me will be to find out what MPV does to fullscreen the client. And why Awesome seems to not pick it up correctly. [1] : Just before sending the message, I altered the test a bit to spawn a client first, then the MPV --fullscreen. The MPV client always have the correct place/sizes/blabla. So it seems the fullscreen behavior depends on whether there is already a client or not. |
it seems this issue reproduces only on certain hardware - i have 2 systems with intel+nvidia where i can't reproduce it, and can reproduce it on pure amd setup - or the difference might be even in cpu speed or certain optimizations @akinokonomi which cpu, gpu and gpu driver do you have? |
I have intel and nvidia. As for software, I've been having this issue for some time, so it can't be a problem with this specific version, but it's latest nvidia 535.98. Just in case, I tried starting awesome with and without FWIW there is no such problem with openbox + lxpanel. |
what do you mean by that, it works alright with --no-argb? |
No, I mean it does not change anything. I've just rebuilt on latest commit 28381d2 (and luajit 2.1.1692616192) vs 0e5fc45, and for some reason it behaves differently now. TLDR It's still broken, but even more than before. When opening Now, there are few things that are a bit different: When starting Before, on 0e5fc45, with that option, it opened stretched on whole screen, except for panel, looking like "maximized" on tiling and floating layouts alike. Now Starting it on floating layout, I did not notice any difference from before, it starts marked as floating, looking like maximized (not covering the panel). On 0e5fc45, it'd start looking like maximized on tiling layout too. Hope I explained it well. I did not test it with the default awesome config, though. EDIT: but mpv tested with the default config. |
what exact cpu do you have? i have a theory that if it's too fast, some certain code in ewmh/client state handling getting a race condition |
also, getting back to the topic of unexpected optimizations - have you tried with lua instead of luajit? |
@actionless Ohhh, I'm very sorry, it was a typo, I meant it does not seem to be relevant. |
Just checked, it's Intel Core i3-6100 min/max: 800/3700 MHz
I tried with Lua before, but not with latest awesome commit. |
i've already checked earlier today - luajit or lua doesn't make a difference
probably cpu clock speed is not the case neither (i can't reproduce the problem on machine with 3500mhz speed, but can on machine with 4600, still could be marginal enough for some particular race to happen, but let's skip this possibility for now) and which driver do you use, nvidia or nouveau? |
It's proprietary nvidia 535.98 |
apparently that's not the case neither - on machines on which i can't reproduce the problem - i also have proprietary nvidia, and on machine on which it happens for me - i have opensource |
…ients if it was requested by awesome's own fullscreen and maximize handlers (fixes: awesomeWM#3844, awesomeWM#3834)
and could you reproduce the problem inside a VM? i thought before your problem related to that aforementioned fullscreen issue, but since not - it must be smth really corner case related to your specific configuration, and test on VM would be a good way to investigate what makes your setup special the fastest way to get inside vm would be to get live-cd with majaro and install awesome-git from aur |
I thought about doing that from the beginning, yeah, but it's just too bothersome. I'm sorry. Maybe at some later point. The workaround I mentioned #3834 (comment) is more than enough for me. But thank you for spending so much time trying to figure it out. I appreciate your help! |
Output of
awesome --version
:Also tested with Lua 5.4.6
Default config
How to reproduce the issue:
The following command starts client in floating mode, instead of fullscreen:
(I also experience this with some Wine applications)
> mpv --fullscreen --player-operation-mode=pseudo-gui --pause
Though xprop output shows fullscreen state:
> xprop _NET_WM_STATE _NET_WM_STATE(ATOM) = _NET_WM_STATE_FULLSCREEN
Even with following awesome rule, mpv does not open in fullscreen as long as I start it with
--fullscreen
argument:I found similar report #2173, but in my case application is not stuck anywhere, it also has proper borders, etc., it just starts floating.
I guess there are other, though. Sorry if it's a duplicate.
Actual result:
Client starts floating.
Expected result:
Client open in fullscreen.
As a workaround, following rule fixed the problem for me:
The text was updated successfully, but these errors were encountered: