CARVIEW |
Navigation Menu
-
-
Notifications
You must be signed in to change notification settings - Fork 11k
Description
2025/06/25: RELEASED 1.92.0. PLEASE STOP POSTING HERE. OPEN A NEW ISSUE INSTEAD!
See docs/BACKENDS.md for instruction to add support for ImGuiBackendFlags_RendererHasTextures
in your custom backend.
2025/06/11: merged to master, branch now deleted.
2025/06/06: pushed enough changes that I am hopeful this could be merged this month. Feedback welcome.
2025/03/19: pushed a "big" change reverting the renaming ImTextureID to ImTextureUserID from the March 5 version. This is simpler for end-user, both in terms of breaking changes and in term of understanding the design. The structure previously called ImTextureID in the March 5 version is now called ImTextureRef.
2025/03/05: Pushed an experimental features/dynamic_fonts branch.
I am looking for feedback / early adopters to try this as we will inevitably find bugs or use cases that are not well supported.
The API are not 100% stabilized but it is expected they stay relatively close.
As of today, I only recommend experienced users to try this. Things should be simplified and clarified over the upcoming month.
WHEN YOU SUBMIT FEEDBACK PLEASE TRY TO INCLUDE RELEVANT CONTEXT. Things may look simple in the surface but there are lots of parameters under the hood.
Warning: Your first impression may be very dry: the examples application are using the default bitmap fonts and are still not DPI aware. (but it is now trivial to scale the font dynamically).
You may tinker with changing FontSize or FontScale in Style Editor. It's going to make more sense in an established application. If you are using multiple fonts, large fonts, icon fonts, non-English languages, this will likely make things easier.
TL;DR; Add a font once, use it as any size.
2025-01-27.font.resize.mp4
If you want to help testing this:
- Read this :)
- Branch your project and update to this
features/dynamic_fonts
branch of imgui. - Make changes (in required/desirable) in your branch.
- If you find any issue you can report/discuss and return to your main branch. Your feedback will help improve the code but also comments/docs/examples.
- If you start using this, please try to update and feedback regularly as we work on finalizing this.
I am interested in different situations:
- Updating to latest code and using an old standard backend. Do you see any issue/breakage?
- Updating to latest code and using the latest standard backend.
- Updating to latest code and using a custom backend. Do you see any issue/breakage? How's your experience figuring out how to update to support
ImGuiBackendFlags_RendererHasTextures
? - Users for
AddCustomRectRegular()
/AddCustomRectFontGlyph()
api: I am creating a dedicated topic Request for feedback: custom rect / custom glyphs / custom loaders withdynamic_fonts
branch.Β #8466 for feedback on those.
The API we are replacing to interface with renderer backends has been here since January 2015 (!), so is more 10 years old. I want to ensure that the new API will also last long.
THE PLAN
My hope is that I can finish and merge this to master in 1~2 months but it will depends on amount of feedback/bugs, and the remaining work on more "General Scaling".
- I am pushing a public branch today. It is temporarily based over
docking
. If you need to maintain changes on your side (custom engine etc.) you can use#ifdef IMGUI_HAS_TEXTURES
. - Now gathering a first wave of feedback and issues from early enthusiasts.
I am creating two topics:- Topic Request for feedback: dynamic fonts & texture updates (v1.92)Β #8465 (this one) for any general question and issue on this feature.
- Topic Request for feedback: custom rect / custom glyphs / custom loaders with
dynamic_fonts
branch.Β #8466 solely related to support for CustomRect viaAddCustomRect()
API (previouslyAddCustomRectRegular()
/AddCustomRectFontGlyph()
).
Your feedback, any sorts of feedback will help fixing bugs, improving documentation, comments and examples. Don't hesitate to share any sorts of feedback, or any report of what confused you, if even for a minute.
- The commit history will be reworked/sculpted, rebased and force-pushed for a little while, as I am treating this as short-term feature branch. So you will likely need to checkout when you update (regular merging will be harder). At some point when I am convinced enough that the commits are a good, I will stop sculpting history and start only adding to it.
- When this is deemed mature enough, it will be rebased on master and pushed as 1.92. We will open new topics if the current topics have had too many posts and many already solved issues.
- My expectation is that before 1.92 I will have also finished and added more features related to "general scaling" (current code only has "font scaling").
USEFUL REFERENCES COMMITS/DIFF
Public API
- Browse for main changes inside
imgui.h
in the diff between before and after - Added about ~300 lines added to imgui.h, including comments and obsolete stuff.
Backends:
(line count including comments)
- Allegro5: ee8941e (+35 lines)
- DirectX9: 75efba7 (+48 lines)
- DirectX10: 2d2b1bc (+40 lines)
- DirectX11: 372fd27 (+40 lines)
- DirectX12: eefe5d5 (+87 lines)
- Metal: 26c017d (+55 lines)
- OpenGL2: 0430c55 (+25 lines)
- OpenGL3: dbb91a5 (+47 lines)
- SDL_Renderer2: 9fa65cd (+20 lines)
- SDL_Renderer3: e538883 (+19 lines)
- SDL_GPU: 16fe666 (+41 lines)
- Vulkan: abe294b (+33 lines)
- WGPU: 571dae9 (+30 lines)
Third Party Extensions
- ImPlot fixes: epezent/implot@193b9d8
cimgui expose image functions withImTextureUserID
type to simplify function calls: 1.92: Auto convert ImTextureID from ImTextureUserID ?Β cimgui/cimgui#287