Commit Graph

10 Commits

Author SHA1 Message Date
ocornut
96ab68eee0 Examples: refactor all examples with a MainLoopStep() function, to facilitate use with Emscripten. (#2492, #3699)
Aligned all examples.
2023-02-02 17:30:48 +01:00
ocornut
5a3f82e2f4 Examples: SDL+SDL_Renderer: Added call to SDL_RenderSetScale() to display is correct on a Retina display (albeit lower-res as our other unmodified examples). (#6121, #6065, #5931). 2023-01-31 15:49:54 +01:00
ocornut
73efcec564 Examples: disable GL related warnings on Mac + amend to ignore list. 2022-09-27 22:25:45 +02:00
ocornut
5c8041b4d7 Update gif in README + font names in examples 2022-09-19 17:45:05 +02:00
tocic
2b1d8e3eaf Fix more typos in sources and docs (#5681) 2022-09-14 20:36:45 +02:00
ocornut
92d0924b82 Fixed build with IMGUI_DISABLE_OBSOLETE_KEYIO + made all examples comments refer to StyleColorsLight(). 2022-07-06 20:58:20 +02:00
ocornut
1e18da5c38 Backends, Examples: Add comments about using WndProc handler and WantCaptureXXX flags. (#5061)
+ update README.
2022-02-28 20:51:50 +01:00
Clownacy
c6cab1f352 Backends: SDL: Added SDL_Renderer* parameter to ImGui_ImplSDL2_InitForSDLRenderer(). Use SDL_GetRendererOutputSize() instead of SDL_GL_GetDrawableSize() when bound to a SDL_Renderer. (#4927)
This is (kind of) an OpenGL-only function, which should be avoided when SDL2 isn't using OpenGL.
The only alternative that is recommended is SDL_GetRendererOutputSize, which limits this fix to the SDL_Renderer backend. Still, I think it's better than nothing.
I say that SDL_GL_GetDrawableSize is "kind of" OpenGL-only because it does technically work even when SDL2 isn't using OpenGL.
It's just that it becomes a shim to SDL_GetWindowSize, which is not suitable for high-DPI usage because it reflects the size of the window in screen coordinates, not actual pixels, so it really should be avoided when not using OpenGL.
2022-02-04 16:51:29 +01:00
ocornut
fba756176d Backends: SDL_Renderer: Amend 1d2d246, various tweaks, fixes, sync to latest. (#3926) 2021-09-21 19:29:48 +02:00
Sylvain
62b17f928e Backends: SDL_Renderer: Added renderer backend for SDL 2.0.17+ (#3926)
(Squashed 20 commits)
2021-09-21 19:29:48 +02:00