ocornut
4ef1145241
Fonts: fixed dynamically changing font loader from losing Fallback and Ellipsis glyphs. ( #8763 )
...
Only the call to ImFontAtlasBuildSetupFontLoader() is the notable change. The change in ImFontAtlasFontInitOutput() is merely to use an existing helper function.
2025-07-07 16:54:08 +02:00
ocornut
92e2df5978
Merge branch 'master' into docking
2025-06-30 21:18:46 +02:00
ocornut
fd75bdccb0
Fonts: for large size fonts, layout/size calculation only load glyphs metrics. Actual glyphs are renderer+packed when used by drawing functions. ( #8758 , #8465 )
...
(Breaking) breaks signature of ImFontLoader::FontBakedLoadGlyph, sorry.
2025-06-30 21:16:20 +02:00
ocornut
b7e5d76c79
Fonts: added ImFontAtlas::SetFontLoader() to dynamically change font loader at runtime without using internal API. ( #8752 , #8465 )
2025-06-30 20:01:02 +02:00
ocornut
3ec62dfeff
Merge branch 'master' into docking
...
# Conflicts:
# backends/imgui_impl_osx.h
# backends/imgui_impl_osx.mm
# backends/imgui_impl_sdl3.cpp
# backends/imgui_impl_vulkan.cpp
# imgui.h
2025-06-27 16:59:03 +02:00
ocornut
f18aea5246
Version 1.92.1 WIP
2025-06-27 13:30:45 +02:00
ocornut
adfa5364cd
Merge branch 'master' into docking
...
# Conflicts:
# backends/imgui_impl_sdlgpu3.cpp
# imgui.cpp
2025-06-25 18:27:19 +02:00
ocornut
673eb7de96
Version 1.92.0
2025-06-25 18:19:56 +02:00
ocornut
e4bba0b53c
Merge branch 'master' into docking
2025-06-24 19:10:26 +02:00
ocornut
97e0d59619
(Breaking) Fonts: removed PushFontSize(), PopFontSize().
2025-06-24 19:09:51 +02:00
ocornut
776897d3c9
Fonts: fixed PVS Studio false positive "expression 'cmd_count != draw_list->CmdBuffer.Size' is always false." ( #8720 , #8465 )
...
Amend 608dd96
2025-06-24 15:24:09 +02:00
ocornut
7cd567202e
Merge branch 'master' into docking
2025-06-24 15:17:29 +02:00
ocornut
608dd96de6
Fonts: fixed RenderText() asserting when crossing VtxOffset change boundaries. ( #8720 , #8465 )
2025-06-24 12:21:07 +02:00
ocornut
613a6a964c
Fonts: AddFontDefault() adds to GlyphOffset.y instead of overriding it.
2025-06-24 10:27:24 +02:00
ocornut
b580c11303
Merge branch 'master' into docking
...
# Conflicts:
# backends/imgui_impl_dx12.cpp
# backends/imgui_impl_glfw.cpp
# backends/imgui_impl_sdl2.cpp
2025-06-20 15:19:36 +02:00
ocornut
2f9c518ca8
Textures: ImTextureData::GetPixels() returns void* for clarity.
2025-06-20 15:17:13 +02:00
ocornut
344d5ff4b7
Merge branch 'master' into docking
2025-06-17 20:15:12 +02:00
ocornut
fe048efeab
DrawList, Fonts: fixed PushFont()/AddImage() not restoring correct atlas texture id when using multiple atlas ( #8694 )
...
This also needs 24f7328
.
2025-06-17 12:06:14 +02:00
ocornut
24f7328e5f
DrawList, Fonts: fixed ImFontAtlasTextureRepack() overwriting draw list shared data UV's etc. even when not bound. ( #8694 , #8465 )
...
ImFontAtlasUpdateDrawListsSharedData() call from ImFontAtlasTextureRepack() would trigger this.
For simplicity we also track current atlas in ImDrawListSharedData, but we could probably use Font->ContainerAtlas.
2025-06-17 12:06:05 +02:00
ocornut
4cf85ee543
Merge branch 'master' into docking
...
# Conflicts:
# backends/imgui_impl_osx.mm
# backends/imgui_impl_wgpu.cpp
# backends/imgui_impl_wgpu.h
2025-06-13 17:43:30 +02:00
ocornut
41f4acfb4f
Fonts: add has_textures parameters to ImFontAtlasUpdateNewFrame().
2025-06-12 11:44:11 +02:00
ocornut
7d70c0ff9f
Merge branch 'master' into docking
2025-06-11 20:53:33 +02:00
ocornut
895bff6524
Removed unneeded check in RenderText() loop + disable static analyzer false-positive warnings.
2025-06-11 19:17:34 +02:00
ocornut
6af6cec23f
Merge branch 'master_fonts' into docking
...
# Conflicts:
# backends/imgui_impl_dx10.cpp
# backends/imgui_impl_dx10.h
# backends/imgui_impl_dx11.cpp
# backends/imgui_impl_dx12.cpp
# backends/imgui_impl_dx9.cpp
# backends/imgui_impl_glfw.cpp
# backends/imgui_impl_metal.h
# backends/imgui_impl_metal.mm
# backends/imgui_impl_opengl2.cpp
# backends/imgui_impl_opengl2.h
# backends/imgui_impl_opengl3.cpp
# backends/imgui_impl_opengl3.h
# backends/imgui_impl_sdl2.cpp
# backends/imgui_impl_sdl3.cpp
# backends/imgui_impl_sdlgpu3.cpp
# backends/imgui_impl_sdlgpu3.h
# backends/imgui_impl_vulkan.cpp
# examples/example_glfw_opengl3/main.cpp
# examples/example_sdl2_directx11/main.cpp
# examples/example_sdl2_opengl2/main.cpp
# examples/example_sdl2_opengl3/main.cpp
# examples/example_sdl2_vulkan/main.cpp
# examples/example_sdl3_opengl3/main.cpp
# examples/example_sdl3_sdlgpu3/main.cpp
# examples/example_sdl3_vulkan/main.cpp
# examples/example_win32_directx10/main.cpp
# examples/example_win32_directx11/main.cpp
# examples/example_win32_directx12/main.cpp
# examples/example_win32_directx9/main.cpp
# imgui.cpp
# imgui.h
# imgui_demo.cpp
# imgui_internal.h
2025-06-11 18:07:19 +02:00
ocornut
e1481a731d
Fonts: fixed NewFrame() when atlas builder has been created but fonts not added. Fixed GetCustomRect() after atlas clear.
2025-06-11 16:25:18 +02:00
ocornut
2e67bd4de7
Fonts: rename to ImFontAtlasBuildLegacyPreloadAllGlyphRanges().
2025-06-11 16:25:06 +02:00
ocornut
02f58b3207
Fonts: AddFont() functions now allow size_pixels==0.0f (only required when using certain functions)
...
Fonts: AddFont() funcitons allow size_pixels==0 for merged fonts.
2025-06-11 16:24:48 +02:00
ocornut
2d2b1cee6b
Fonts: internals: renamed g.FontSizeBeforeScaling to g.FontSizeBase for consistency.
...
# Conflicts:
# imgui_internal.h
2025-06-11 16:10:45 +02:00
ocornut
59a11363a5
Fonts: ground work for allowing SizePixels to be optional.
2025-06-11 16:06:24 +02:00
ocornut
402db2ef32
Fonts: fixed passing negative sizes to stb_truetype loader.
2025-06-11 16:06:24 +02:00
ocornut
1e118ab891
Fonts: added ImGuiStyle::FontSizeBase. Ensuring PushFontSize() works before main loop and across NewFrame().
...
# Conflicts:
# imgui.cpp
2025-06-11 16:06:21 +02:00
ocornut
69547bd4bd
Fonts: ImFont::DefaultSize -> ImFont::LegacySize. ImFontFlags_UseDefaultSize -> ImFontFlags_DefaultToLegacySize.
2025-06-11 16:06:00 +02:00
ocornut
e3860aa6ac
(Breaking) Fonts: removing obsolete ImFont::Scale.
2025-06-11 16:05:54 +02:00
ocornut
25f9c318e3
Fonts: added "Input Glyphs Overlap Detection Tool". Added "Clear bakes", "Clear unused" buttons. Move code.
2025-06-11 16:05:54 +02:00
ocornut
5926c877a1
Fonts: detect if ImFontAtlasUpdateNewFrame() is not being called.
2025-06-11 16:05:54 +02:00
ocornut
9f8b4bdaf1
Fonts: fixed edge case calling RenderText() without priming with CalcTextSize().
2025-06-11 16:05:49 +02:00
ocornut
b2343d6247
Fonts: fallback to default default rasterizer density + pick one from existing viewports at the time of calling AddUpdateViewport().
...
# Conflicts:
# imgui.cpp
2025-06-11 16:05:33 +02:00
ocornut
822903e56d
Fonts: fixed ImFontAtlas::RemoveFont() with multiple sources.
...
Thanks cyfewlp!
2025-06-11 16:02:10 +02:00
ocornut
5ee9845559
Fonts: automatically set current rasterizer density to viewport density. Effectively should fix most things on macOS.
...
# Conflicts:
# imgui.cpp
# imgui.h
2025-06-11 16:02:09 +02:00
ocornut
fad5280d4c
Fonts: fixed broken support for legacy backend due to a mismatch with initial pre-build baked id.
2025-06-11 15:57:44 +02:00
ocornut
65e6039979
Fonts: remove unnecessary ImDrawListSharedData::FontAtlas which is actually getting in the way of using multiple atlases.
2025-06-11 15:57:44 +02:00
ocornut
46fa9e8efb
Fonts: Debug display status. Fixed truncated raw texture id. Fixed FormatTextureIDForDebugDisplay(). Comments.
2025-06-11 15:57:35 +02:00
ocornut
f6735c223c
Fonts: remove ImFontHooks in favor of a AddRemapChar() implementation.
2025-06-11 15:57:35 +02:00
ocornut
89e880dfd1
Fonts: adding ImFontHooks for codepoint remapping.
2025-06-11 15:57:35 +02:00
ocornut
8523cbdf58
Fonts: rework ImFontLoader::FontBakedLoadGlyph() interface
2025-06-11 15:57:35 +02:00
ocornut
4dec946ae6
Fonts: don't pretend to half recover from OOM for now + debug log filename on load failure.
2025-06-11 15:57:35 +02:00
ocornut
b32ef3c05d
Fonts: make RasterizerDensity a dynamic field. (temporarily exposed as SetFontRasterizerDensity()).
...
# Conflicts:
# imgui.cpp
# imgui.h
2025-06-11 15:57:35 +02:00
ocornut
5310f5fba3
Fonts: rework toward reducing reliance on ImFontConfig::DstFont since we ought to separate them.
2025-06-11 15:57:23 +02:00
ocornut
2b0d49a905
Fonts: make ImFont::Sources a vector.
...
Later it should become a ImSpan<>
2025-06-11 15:57:23 +02:00
ocornut
e7efe94fd2
Fonts: shallow rework of ImFontAtlasBakedAddFontGlyph() to facilitate upcoming change.
2025-06-11 15:57:23 +02:00