-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
PR: Added validation to window/position config value saved in spyder.ini #3754
Conversation
current_width = screenShape.width() | ||
current_height = screenShape.height() | ||
if current_width < width or current_height < height: | ||
value = self.get_default(section, option) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although this is the right thing to do, this is not the right place. You need to find where this setting is applied (most probably in app/mainwindow.py
) and use this validation there.
# with the current screen. See issue 3748 | ||
width = pos[0] | ||
height = pos[1] | ||
screenShape = QApplication.desktop().geometry() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change this variable's name to screen_shape
.
Other than a minor comment, this looks good to me. Thanks @dalthviz! |
Good job, thanks @dalthviz! |
Fixes #3748