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

Minimise behaviour #783

Open
alexheretic opened this issue Jan 27, 2019 · 4 comments
Open

Minimise behaviour #783

alexheretic opened this issue Jan 27, 2019 · 4 comments
Labels
B - bug Dang, that shouldn't have happened DS - windows P - high Vital to have S - platform parity Unintended platform differences

Comments

@alexheretic
Copy link
Contributor

I noticed recently that minimising in Windows causes a WindowEvent::Resized(size=0) event, this doesn't seem to happen in X11.

On windows this becomes a way to tell that the window has been minimised. Is there a way I can tell this on X11, or in general?

@elinorbgr
Copy link
Contributor

I can't speak for other platforms, but on wayland it is not possible for a window to know whether is it currently displayed or not.

Depending on the compositor it might be inferred if it appears that the set of current ouputs of the window is empty (so the window is not displayed on any output), but I expect this to be unreliable at best.

@alexheretic
Copy link
Contributor Author

alexheretic commented Jan 30, 2019

Good to know about wayland.

As the windows behaviour surprised me, maybe we should note in the WindowEvent::Resized docs that some, but not all, platforms will generate zero resized events when the window is minimised.

I couldn't find any info on minimising behaviour in the docs, hence this issue.

@Osspial
Copy link
Contributor

Osspial commented Jan 30, 2019

I'm not comfortable with this being a documented feature, seeing as it's a hacky way to get the data and we don't know if it even works on non-Windows platforms. Honestly, I'd prefer to suppress the resize event on Windows to prevent people from relying on it, then see about introducing minimized events once the platform support story becomes more clear. The behavior on X11 and MacOS needs to be investigated before any action on this would get taken, though.

@chrisduerr
Copy link
Contributor

This is actually something Alacritty has run into (see alacritty/alacritty#3081) and I can confirm that this is only the case on Windows.

@maroider maroider added DS - windows C - needs discussion Direction must be ironed out C - needs investigation Issue must be confirmed and researched S - platform parity Unintended platform differences labels Jul 12, 2021
@madsmtm madsmtm added B - bug Dang, that shouldn't have happened and removed C - needs investigation Issue must be confirmed and researched C - needs discussion Direction must be ironed out labels Sep 3, 2024
@madsmtm madsmtm added the P - high Vital to have label Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B - bug Dang, that shouldn't have happened DS - windows P - high Vital to have S - platform parity Unintended platform differences
Development

No branches or pull requests

6 participants