summaryrefslogtreecommitdiff
path: root/src/Fl_Text_Buffer.cxx
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2026-01-29 13:04:35 +0100
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2026-01-29 13:04:35 +0100
commitbed38ba3f5ba653ab41bd5abb92c923591442c8f (patch)
treedad2450518c851a3e715f5c36b963e7d88024ac2 /src/Fl_Text_Buffer.cxx
parent445d26bb71f458232b80b0bd4217896e2407c5b7 (diff)
Emojis: add support of keycap emoji sequences.
- It is expected that all emojis listed in the Wikipedia "emoji" article as of early 2026 are recognized as single glyphs by FLTK text widgets. - Document functions fl_utf8_{next|previous}_composed_char() relatively to the notion of "emoji sequence". - Remove signed/unsigned comparison compilation warnings.
Diffstat (limited to 'src/Fl_Text_Buffer.cxx')
-rw-r--r--src/Fl_Text_Buffer.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Fl_Text_Buffer.cxx b/src/Fl_Text_Buffer.cxx
index 848cacd9a..81fa36d55 100644
--- a/src/Fl_Text_Buffer.cxx
+++ b/src/Fl_Text_Buffer.cxx
@@ -2127,7 +2127,7 @@ int Fl_Text_Buffer::prev_char(int pos) const
int Fl_Text_Buffer::next_char(int pos) const
{
IS_UTF8_ALIGNED2(this, (pos))
- int l = fl_utf8len1(byte_at(pos));
+ unsigned l = fl_utf8len1(byte_at(pos));
if (l > 2) { // test for composed character only if pos is at long codepoint
int p = pos, ll, b;
char t[40]; // crazyest composed characters I know use 28 bytes in UTF8 (e.g., 🏴󠁧󠁢󠁷󠁬󠁳󠁿)