SDL_MinimizeWindow(3)
β¨ SDL_MinimizeWindow(3) β¨
okay bestie, welcome to the SDL3 FUNCTIONS section of the manual, and today's main character is SDL_MinimizeWindow π
she's literally just here to shrink your window down to its lil iconic self π
πΈ NAME πΈ
SDL_MinimizeWindow β request that the window be minimized to an iconic representation.
like. that's it. that's her job. β¨
π¦ SYNOPSIS π¦
#include <SDL3/SDL_video.h>
bool SDL_MinimizeWindow(SDL_Window *window);
π DESCRIPTION π
so here's the tea, bestie π: if the window is in a fullscreen state, this request has no direct effect. none. zero. it's giving "asked nicely, got ignored." BUT β and this is the fun part β it may alter the state the window is returned to when leaving fullscreen. so it's not doing nothing, it's just doing something sneaky and future-you-flavored. π
also, on some windowing systems this request is asynchronous, which means the new window state may not have been applied immediately upon the return of this function. yeah. she said "k, done" and then kept working behind your back π if you genuinely need an immediate change, call SDL_SyncWindow() to block until the changes have taken effect. periodt.
and when the window state changes, an SDL_EVENT_WINDOW_MINIMIZED event will be emitted π₯ note: since this is just a request, the windowing system can straight up deny the state change. not every request gets a yes, and that's the vibe check for you π
π FUNCTION PARAMETERS π
windowβ the window to minimize. that's the one, bestie, that's the target π«Ά
π RETURN VALUE π
returns true on success or false on failure π and if it fails, call SDL_GetError() for more information β she'll tell you what went wrong, no cap.
π THREAD SAFETY π
this function should only be called on the main thread. no side quests, no background threads sneaking in. main character energy only. β
β AVAILABILITY β
this function is available since SDL 3.2.0. if your SDL is older than that, sorry babe, she doesn't exist yet π
π SEE ALSO π
the whole window-state squad, fr fr π§
Simple Directmedia Layer Β· SDL 3.4.18 Β· SDL_MinimizeWindow(3)
and that's the whole page bestie, ty for reading, go minimize something responsibly πβ¨π
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms