You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Not possible to create a font with caller-owned memory #9086
While many latin fonts are just kilobytes, other fonts can get pretty big. CJK fonts are often a few megabytes, Noto Color Emoji is 25MB, and Apple Color Emoji (which doesn't work yet, but might in the future) is 150MB. With those kinds of sizes, it would be ideal to mmap the font to avoid loading the parts that don't get used, but at the very least you don't want multiple copies getting loaded even if you want to e.g. add an emoji font to the fallback path of multiple ImFonts.
ImGui currently has ImFontConfig::FontDataOwnedByAtlas to allow you to select whether ImGui manages the memory of the font so you just set that to false and...
ImGui currently has ImFontConfig::FontDataOwnedByAtlas to allow you to select whether ImGui manages the memory of the font so you just set that to false and..
Argh. I don’t remember/know why I added this code. I will investigate this later but I agree it defeats the purpose.
Activity
ocornut commentedon Nov 21, 2025
Argh. I don’t remember/know why I added this code. I will investigate this later but I agree it defeats the purpose.
ocornut commentedon Nov 24, 2025
Congratulation, you seem to have uncovered the oldest fuckup in Dear ImGui history 🥇
815168c#diff-cee9beb740469eb5192dfe94aaee7320932590adade9d9b1d2ee392ac2e1e88cR9836
Fonts: fixed handling of `ImFontConfig::FontDataOwnedByAtlas = false`…
ocornut commentedon Nov 24, 2025
I cannot find a reason for this and removed the duplication: 98636f4
Thank you for spotting this!
Fonts: amend/comment on FontDataOwnedByAtlas=false fix being a breaki…
Fonts: fixed handling of `ImFontConfig::FontDataOwnedByAtlas = false`…
Fonts: amend/comment on FontDataOwnedByAtlas=false fix being a breaki…