Skip to main content
7 events
when toggle format what by license comment
Aug 22, 2020 at 23:52 comment added Quasímodo @A.B Oh, I didn't know you had already checked it, thanks again. If it returned two values and both were the same (i.e., both monitors have the same dimensions), then one could just get one of those values to check if the window is fullscreen, I guess? But indeed, the general case is more complicated and ultimately would depend on what the user wants to do.
Aug 22, 2020 at 19:30 comment added A.B I did check your commands with two screens before leaving the comment. It behaves as I wrote: would return two different values and thus: The active window is not fullscreened. I'm not expecting any easy workaround for this (I don't have any idea about it), I was just stating the fact.
Aug 22, 2020 at 18:18 history edited Quasímodo CC BY-SA 4.0
Alternative: getdisplaygeometry
Aug 22, 2020 at 18:06 comment added Quasímodo @A.B Thank you for your comment. I don't have two screens to test it, but AFAIK the default behavior of Xdotool when there is more than one window matching a search is to consider only the first one. You can verify that by launching various XTerms and then with xdotool search -class XTerm getwindowgeometry you will see the output of the geometry of only one single window.
Aug 22, 2020 at 14:18 comment added A.B nitpicking: what if there's a 2nd screen? Currently this makes the root geometry the geometry of a virtual rectangle able to include both screens. (eg two FHD screens side by side => 3840x1080), but a full screen video will still be on one screen: 1920x1080. Anyway I still upvoted, it solves OP's problem.
Aug 22, 2020 at 13:46 vote accept ceremcem
Aug 22, 2020 at 12:56 history answered Quasímodo CC BY-SA 4.0