Skip to content

Commit

Permalink
Merge pull request #77089 from katemonster33/imtui-inputtext-fix
Browse files Browse the repository at this point in the history
Fixed issue where extra cursor was drawn in ImGui InputText field on TUI builds erroneously
  • Loading branch information
akrieger authored Oct 16, 2024
2 parents aa27c22 + 699b909 commit f44d4a3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/third-party/imgui/imgui_widgets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5014,7 +5014,7 @@ bool ImGui::InputTextEx(const char* label, const char* hint, char* buf, int buf_
{
ImU32 col = GetColorU32(is_displaying_hint ? ImGuiCol_TextDisabled : ImGuiCol_Text);

if(GImGui->IO.PreEditText && !is_multiline)
if (GImGui->IO.PreEditText[0] != '\0' && !is_multiline)
{
const char *preEditTextEnd = GImGui->IO.PreEditText + strlen(GImGui->IO.PreEditText);
ImWchar wcharBuf[255] = { 0 };
Expand Down

0 comments on commit f44d4a3

Please sign in to comment.