Skip to content
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

ewmhFullscreen doesn't restore floating windows #865

Open
3 tasks done
geekosaur opened this issue Jan 18, 2024 · 4 comments
Open
3 tasks done

ewmhFullscreen doesn't restore floating windows #865

geekosaur opened this issue Jan 18, 2024 · 4 comments

Comments

@geekosaur
Copy link
Contributor

If a floating window is made fullscreen and then toggled back, it is sunk instead of floated. The code at https://github.com/xmonad/xmonad-contrib/blob/afd6824ce00063bb8e9b7a1c5daf0737c2f61616/XMonad/Hooks/EwmhDesktops.hs#L442C5-L444 unconditionally sinks the window when _NET_WM_STATE_FULLSCREEN is removed.

This will require saving the old window position for floats; the current code assumes sinking the window will handle positioning.

Checklist

  • I've read CONTRIBUTING.md

  • I tested my configuration

    • With xmonad version 0.17.2
    • With xmonad-contrib version 0.17.1
geekosaur added a commit to geekosaur/xmonad-contrib that referenced this issue Jan 18, 2024
`EwmhFullscreen` unconditionally sinks windows in response to a
`_NET_WM_STATE` root window message removing `_NET_WM_STATE_FULLSCREEN`.
Unfortunately, at least some versions of either the Gtk or GNOME
libraries send this on startup while restoring a window's last
known state, which means a `manageHook` `doFloat` will be undone.

This change ignores the remove if the window is not fullscreen.

A followup issue, xmonad#865, has been added for the follow-on problem
that the floating state of a window is not restored on removal of
the fullscreen state.

Fixes: xmonad#820
@geekosaur
Copy link
Contributor Author

This could reasonably be parked until it matters to someone. Also, it's better not to try to address it until #866 goes in, since otherwise there will be a merge conflict.

@liskin
Copy link
Member

liskin commented Jan 19, 2024

I believe #768 solved this already.

@geekosaur
Copy link
Contributor Author

"This commit only adds the hooks. Neither of the motivations are dealt with yet, so the docs are a bit terse still."

@liskin
Copy link
Member

liskin commented Jan 19, 2024

Well that's the first commit. The following one adds the thing.

geekosaur added a commit to geekosaur/xmonad-contrib that referenced this issue Jan 19, 2024
`EwmhFullscreen` unconditionally sinks windows in response to a
`_NET_WM_STATE` root window message removing `_NET_WM_STATE_FULLSCREEN`.
Unfortunately, at least some versions of either the Gtk or GNOME
libraries send this on startup while restoring a window's last
known state, which means a `manageHook` `doFloat` will be undone.

This change ignores the remove if the window is not fullscreen.

A followup issue, xmonad#865, has been added for the follow-on problem
that the floating state of a window is not restored on removal of
the fullscreen state.

Fixes: xmonad#820
geekosaur added a commit that referenced this issue Jan 21, 2024
`EwmhFullscreen` unconditionally sinks windows in response to a
`_NET_WM_STATE` root window message removing `_NET_WM_STATE_FULLSCREEN`.
Unfortunately, at least some versions of either the Gtk or GNOME
libraries send this on startup while restoring a window's last
known state, which means a `manageHook` `doFloat` will be undone.

This change ignores the remove if the window is not fullscreen.

A followup issue, #865, has been added for the follow-on problem
that the floating state of a window is not restored on removal of
the fullscreen state.

Fixes: #820
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants