diff --git a/docs/CHANGELOG.txt b/docs/CHANGELOG.txt index f575242f..d1e0b820 100644 --- a/docs/CHANGELOG.txt +++ b/docs/CHANGELOG.txt @@ -43,6 +43,8 @@ Breaking Changes: Other Changes: - Window: Fixed InnerClipRect right-most coordinates using wrong padding setting (introduced in 1.71). +- Word-wrapping: Fixed overzealous word-wrapping when glyph edge lands exactly on the limit. Because + of this, auto-fitting exactly unwrapped text would make it wrap. (fixes initial 1.15 commit, 78645a7d). - ImDrawList: Fixed CloneOutput() helper crashing. (#1860) [@gviot] - ImDrawListSlitter, ImDrawList::ChannelsSplit(), : Fixed an issue with merging draw commands between channel 0 and 1. (#2624) diff --git a/imgui_draw.cpp b/imgui_draw.cpp index 288d95ae..e54a5fdc 100644 --- a/imgui_draw.cpp +++ b/imgui_draw.cpp @@ -2692,7 +2692,7 @@ const char* ImFont::CalcWordWrapPositionA(float scale, const char* text, const c } // We ignore blank width at the end of the line (they can be skipped) - if (line_width + word_width >= wrap_width) + if (line_width + word_width > wrap_width) { // Words that cannot possibly fit within an entire line will be cut anywhere. if (word_width < wrap_width)