mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-07-31 03:01:59 +08:00
Fixed a crash, when press "Esc" key in TextEdit control
Fix for #13458 - Crash using cut tool. (SPE-2545)
This commit is contained in:
parent
7ca4faf009
commit
da79ad4937
@ -3293,7 +3293,7 @@ const ImFontGlyph* ImFont::FindGlyph(ImWchar c) const
|
||||
}
|
||||
const ImWchar i = IndexLookup.Data[c];
|
||||
if (i == (ImWchar)-1) {
|
||||
imgui_rendered_fallback_glyph(c);
|
||||
imgui_rendered_fallback_glyph(c);
|
||||
return FallbackGlyph;
|
||||
}
|
||||
return &Glyphs.Data[i];
|
||||
|
@ -57,6 +57,9 @@ bool s_font_cjk;
|
||||
// a fallback glyph for c.
|
||||
void imgui_rendered_fallback_glyph(ImWchar c)
|
||||
{
|
||||
if (c == 0)
|
||||
return;
|
||||
|
||||
if (ImGui::GetIO().Fonts->Fonts[0] == ImGui::GetFont()) {
|
||||
// Only do this when we are using the default ImGui font. Otherwise this would conflict with
|
||||
// EmbossStyleManager's font handling and we would load glyphs needlessly.
|
||||
|
Loading…
x
Reference in New Issue
Block a user