You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When making a flutter app for Linux, the initial size can be set by altering the parameters of gtk_window_set_default_size() in my_application.cc: gtk_window_set_default_size(window, 450, 750);
Then trying to set maximum and minimum sizes using the window_size plugin in dart code using the same dimensions:
final fixedSize = Size(450, 750);
setWindowMinSize(fixedSize);
setWindowMaxSize(fixedSize);
However when setting this maximum and minimum the window is resized to below the size set initially in the native code using GTK, despite using the same dimensions. Wouldn't the expected behaviour be for the app not to change size at all?
The text was updated successfully, but these errors were encountered:
These are pretty straightforward passthroughs to GTK window methods; perhaps there's a subtle behavioral difference between size and geometry APIs.
Out of curiosity, if you are changing the runner code already, why aren't you just setting gtk_window_set_resizable to false, which seems to be what you want here?
I did in fact end up changing gtk_window_set_resizable once I'd looked at GTK documentation some more and that seems to work fine. The only reason I started medalling in the runner code anyway was because of the window size not being set correctly through the functions I detailed though. I thought I'd bring this up as it certainly was a bit odd, and upon trying to retrieve the window size in dart code after being set this way the values have in fact decreased significantly from what was passed into the functions.
When making a flutter app for Linux, the initial size can be set by altering the parameters of gtk_window_set_default_size() in my_application.cc:
gtk_window_set_default_size(window, 450, 750);
Then trying to set maximum and minimum sizes using the window_size plugin in dart code using the same dimensions:
However when setting this maximum and minimum the window is resized to below the size set initially in the native code using GTK, despite using the same dimensions. Wouldn't the expected behaviour be for the app not to change size at all?
The text was updated successfully, but these errors were encountered: