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

Window forgets unmaximized resolution after move #16

Open
tobip opened this issue Jan 25, 2020 · 3 comments
Open

Window forgets unmaximized resolution after move #16

tobip opened this issue Jan 25, 2020 · 3 comments

Comments

@tobip
Copy link

tobip commented Jan 25, 2020

After moving a maximized window from one screen to another, it "forgot" its unmaximized width and height settings.

Maybe there is a possibility to remember the unmaximized state?

At the moment, after moving a maximized window, and then unmaximizing it, the state gets changed from maximized to unmaximized, but the width and height stay almost the same.

@AlexisBRENON
Copy link
Owner

Yeah, I noticed this also.

Needs some investigations. Stay tuned.

@tobip
Copy link
Author

tobip commented Jan 25, 2020

Alright.

Well I don't know how the script works, so this is just what I have in my mind:
Maybe it's possible to unmaximize the window, then move it to the other screen, and then maximize it, immediately after each other.

@AlexisBRENON
Copy link
Owner

For what I remember, this used to be working in the past (because it was one of my expected feature).

The code works exactly like this:

  • unmaximize the window (because it's mandatory before moving it)
  • compute the relative size of the window with respect to the screen
  • move it to the new screen
  • resize it to match the same ratio (this allow to nicely handle screens of different sizes)
  • maximize it if it was maximized before.

However, the resize step does not seem to work anymore... I opened an issue BurntSushi/xpybutil#15 to get some help.

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