We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 2531 - maximizing and restoring windows don't respect the maximum and minimum sizes
Summary: maximizing and restoring windows don't respect the maximum and minimum sizes
Status: RESOLVED DUPLICATE of bug 3567
Alias: None
Product: SDL
Classification: Unclassified
Component: video (show other bugs)
Version: 2.0.3
Hardware: x86_64 Windows 7
: P2 normal
Assignee: Sam Lantinga
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-09 23:29 UTC by Adam M.
Modified: 2017-08-14 13:52 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Adam M. 2014-05-09 23:29:25 UTC
When setting a maximum size with SDL_SetWindowMaximumSize, the window cannot be programmatically enlarged beyond the size with SDL_SetWindowSize, nor can the user make it larger than that by resizing or maximizing the window. (It is possible to have a maximized window that does not take up the full screen.) However, SDL_MaximizeWindow ignores the limit. This is inconsistent. If it's okay to programmatically make windows larger than the maximum, then SDL_SetWindowSize should not be restricted. If it's not okay, then SDL_MaximizeWindow should be restricted.

Similarly, restoring a window with SDL_RestoreWindow does not respect the minimum size set with SDL_SetWindowMinimumSize.
Comment 1 Sam Lantinga 2017-08-14 13:52:59 UTC
I agree this is confusing and I'm not sure what the right application behavior is. I typically don't see windows on the OS that are both size limited and allow maximizing. I think the proper behavior is to limit the window size when maximizing (and restoring) but I'm not sure if every platform will let you do that.

This is a duplicate of the more recent bug 3567

*** This bug has been marked as a duplicate of bug 3567 ***