diff --git a/extern/imgui_patched/imgui.h b/extern/imgui_patched/imgui.h index 0d889e960..c4dba430c 100644 --- a/extern/imgui_patched/imgui.h +++ b/extern/imgui_patched/imgui.h @@ -621,7 +621,7 @@ namespace ImGui IMGUI_API void TextColoredV(const ImVec4& col, const char* fmt, va_list args) IM_FMTLIST(2); IMGUI_API void TextDisabled(const char* fmt, ...) IM_FMTARGS(1); // shortcut for PushStyleColor(ImGuiCol_Text, style.Colors[ImGuiCol_TextDisabled]); Text(fmt, ...); PopStyleColor(); IMGUI_API void TextDisabledV(const char* fmt, va_list args) IM_FMTLIST(1); - IMGUI_API void TextWrapped(const char* fmt, ...) IM_FMTARGS(1); // shortcut for PushTextWrapPos(0.0f); Text(fmt, ...); PopTextWrapPos();. Note that this won't work on an auto-resizing window if there's no other widgets to extend the window width, yoy may need to set a size using SetNextWindowSize(). + IMGUI_API void TextWrapped(const char* fmt, ...) IM_FMTARGS(1); // shortcut for PushTextWrapPos(0.0f); Text(fmt, ...); PopTextWrapPos();. Note that this won't work on an auto-resizing window if there's no other widgets to extend the window width, you may need to set a size using SetNextWindowSize(). IMGUI_API void TextWrappedV(const char* fmt, va_list args) IM_FMTLIST(1); IMGUI_API void LabelText(const char* label, const char* fmt, ...) IM_FMTARGS(2); // display text+label aligned the same way as value+label widgets IMGUI_API void LabelTextV(const char* label, const char* fmt, va_list args) IM_FMTLIST(2); diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index 9c794899b..071013505 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -6253,7 +6253,9 @@ bool FurnaceGUI::loop() { centerNextWindow(_("Warning"),canvasW,canvasH); if (ImGui::BeginPopupModal(_("Warning"),NULL,ImGuiWindowFlags_AlwaysAutoResize)) { - ImGui::Text("%s",warnString.c_str()); + ImGui::PushTextWrapPos(canvasW); + ImGui::TextUnformatted(warnString.c_str()); + ImGui::PopTextWrapPos(); switch (warnAction) { case GUI_WARN_QUIT: if (ImGui::Button(_("Yes"))) {