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

Reset window position from code #4359

Closed
BornToBeRoot opened this issue Oct 23, 2022 · 3 comments · Fixed by #4383
Closed

Reset window position from code #4359

BornToBeRoot opened this issue Oct 23, 2022 · 3 comments · Fixed by #4383
Milestone

Comments

@BornToBeRoot
Copy link

Describe the feature

Hi @punker76,
is it possible to reset the window position (SaveWindowPosition=true) from the code?

I know i can delete the user.config in the %localappdata%, but a simple solution like ResetPosition() would be nice. Then i could implement a command line parameter to reset the window 😄

Additional context

BornToBeRoot/NETworkManager#1623

@batzen
Copy link
Collaborator

batzen commented Dec 27, 2022

@BornToBeRoot Wouldn't it be better to check if the saved position is valid and not restore it if it would be on a non existing screen?

@BornToBeRoot
Copy link
Author

@batzen Yes, that would be better.

I believe this affects several applications that use mahapps and regularly use different screen setups.

@BornToBeRoot
Copy link
Author

Thanks! I will test it ASAP :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

3 participants