From a129621292a98454d8d636c2daca063f0fb3e3f3 Mon Sep 17 00:00:00 2001 From: "M. Frink ~ Lemur" Date: Thu, 29 Oct 2020 12:21:06 -0500 Subject: [PATCH] Doc: mention IMGUI_USE_WCHAR32 in fonts documentation (#3562) --- docs/FONTS.md | 1 + imconfig.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/FONTS.md b/docs/FONTS.md index 87e6ee04..96573402 100644 --- a/docs/FONTS.md +++ b/docs/FONTS.md @@ -157,6 +157,7 @@ Some solutions: 3. Set `io.Fonts.TexDesiredWidth` to specify a texture width to minimize texture height (see comment in `ImFontAtlas::Build()` function). 4. Set `io.Fonts.Flags |= ImFontAtlasFlags_NoPowerOfTwoHeight;` to disable rounding the texture height to the next power of two. 5. Read about oversampling [here](https://github.com/nothings/stb/blob/master/tests/oversample). +6. To support the extended range of unicode beyond 0xFFFF (e.g. emoticons, dingbats, symbols, shapes, ancient languages, etc...) add `#define IMGUI_USE_WCHAR32`in your `imconfig.h` ##### [Return to Index](#index) diff --git a/imconfig.h b/imconfig.h index 280d1436..015540f3 100644 --- a/imconfig.h +++ b/imconfig.h @@ -49,7 +49,7 @@ //---- Pack colors to BGRA8 instead of RGBA8 (to avoid converting from one to another) //#define IMGUI_USE_BGRA_PACKED_COLOR -//---- Use 32-bit for ImWchar (default is 16-bit) to support full unicode code points. +//---- Use 32-bit for ImWchar (default is 16-bit) to support unicode planes 1-16. (e.g. point beyond 0xFFFF like emoticons, dingbats, symbols, shapes, ancient languages, etc...) //#define IMGUI_USE_WCHAR32 //---- Avoid multiple STB libraries implementations, or redefine path/filenames to prioritize another version