SDL_GetWindowProgressValue(3)
β¨ SDL_GetWindowProgressValue β¨
okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual π this one is SDL_GetWindowProgressValue and it's literally the little sister of the function that sets the progress bar β this one just reads it back out. π
πΈ NAME πΈ
SDL_GetWindowProgressValue β get the value of the progress bar for the given window's taskbar icon. π
yes bestie, that lil progress bar that lives on your taskbar/dock icon? this is how you peek at what number it's currently sitting at. no cap. π¦
π SYNOPSIS π
#include <SDL3/SDL_video.h>
float SDL_GetWindowProgressValue(SDL_Window *window);
π«Ά FUNCTION PARAMETERS π«Ά
windowβ the window to get the current progress value from. like, which window's taskbar icon are we snooping on bestie π
π RETURN VALUE π
Returns the progress value in the range of [0.0f - 1.0f], or -1.0f on failure; call SDL_GetError() for more information.
so like. if it worked, you get a float somewhere between 0.0f and 1.0f β zero means empty, one means full, everything in between is the vibe check in progress πβ¨. and if it flopped? you get -1.0f and you gotta go ask SDL_GetError() what happened, because she always knows. π
π§ THREAD SAFETY π§
This function should only be called on the main thread.
fr fr, main thread only. do not be out here calling this from some random worker thread and then acting surprised. π
π AVAILABILITY π
This function is available since SDL 3.4.0. β
and that's the whole thing, bestie β short, sweet, iconic, periodt. π
Simple Directmedia Layer made this, it's SDL 3.4.18 energy, and it's the SDL_GetWindowProgressValue(3) page β love that for us π«ΆπΈπ
π¦ 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