From 66fbbdf46ab4fe15e4a644b129043cc933bb36e4 Mon Sep 17 00:00:00 2001 From: SDL Wiki Bot Date: Thu, 23 May 2024 17:09:44 +0000 Subject: [PATCH] Sync SDL3 wiki -> header --- include/SDL3/SDL_video.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/SDL3/SDL_video.h b/include/SDL3/SDL_video.h index d3327ac16..9efc10c85 100644 --- a/include/SDL3/SDL_video.h +++ b/include/SDL3/SDL_video.h @@ -991,6 +991,16 @@ extern SDL_DECLSPEC SDL_Window *SDLCALL SDL_CreatePopupWindow(SDL_Window *parent * Windows with the "tooltip" and "menu" properties are popup windows and have * the behaviors and guidelines outlined in SDL_CreatePopupWindow(). * + * If this window is being created to be used with an SDL_Renderer, you should + * not add a graphics API specific property + * (`SDL_PROP_WINDOW_CREATE_OPENGL_BOOLEAN`, etc), as SDL will handle that + * internally when it chooses a renderer. However, SDL might need to recreate + * your window at that point, which may cause the window to appear briefly, + * and then flicker as it is recreated. The correct approach to this is to + * create the window with the `SDL_PROP_WINDOW_CREATE_HIDDEN_BOOLEAN` property + * set to true, then create the renderer, then show the window with + * SDL_ShowWindow(). + * * \param props the properties to use * \returns the window that was created or NULL on failure; call * SDL_GetError() for more information.