Skip to content

Commit b4bd596

Browse files
committed
Fonts: word-wrapping code handle ideographic comma & full stop (U+3001, U+3002). (#8540)
1 parent fcab22f commit b4bd596

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

docs/CHANGELOG.txt

+1
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ Other changes:
5656
CTRL+Tab windowing + pressing a keyboard key. (#8525)
5757
- Error Handling: added better error report and recovery for extraneous
5858
EndPopup() call. (#1651, #8499)
59+
- Fonts: word-wrapping code handle ideographic comma & full stop (U+3001, U+3002). (#8540)
5960
- Fonts: fixed CalcWordWrapPositionA() fallback when width is too small to wrap:
6061
would use a +1 offset instead of advancing to the next UTF-8 codepoint. (#8540)
6162
- Style, InputText: added ImGuiCol_InputTextCursor to configure color of

imgui_draw.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -4009,7 +4009,7 @@ const char* ImFont::CalcWordWrapPositionA(float scale, const char* text, const c
40094009
}
40104010

40114011
// Allow wrapping after punctuation.
4012-
inside_word = (c != '.' && c != ',' && c != ';' && c != '!' && c != '?' && c != '\"');
4012+
inside_word = (c != '.' && c != ',' && c != ';' && c != '!' && c != '?' && c != '\"' && c != 0x3001 && c != 0x3002);
40134013
}
40144014

40154015
// We ignore blank width at the end of the line (they can be skipped)

0 commit comments

Comments
 (0)