]> _ Git - termbox2.git/commit
fix bug with adding combining chars to a full-width char
authorAdam Saponara <as@php.net>
Wed, 18 Dec 2024 03:12:25 +0000 (22:12 -0500)
committerAdam Saponara <as@php.net>
Wed, 18 Dec 2024 04:14:10 +0000 (23:14 -0500)
commit7487f1beea2cb54e1ce2e459e4777901b51aab75
tree3497a52cf48f629780c3c66c2c97abd93752d3a6
parent02e28d08d79e9af3de86d41a163bb83383cdb5c1
fix bug with adding combining chars to a full-width char

the logic was incorrectly sending the combinin char to x-1, but that
assumed a wcwidth==1 char. save last printed x coord and use that
instead.

xterm's ansi output for this is a little strange. unlike other
`expected.ansi` files, cat-ing this one to stdout doesn't seem to
render the correct output, and if you peek at its contents you'll see
some "\xef\xbf\xbf" (U+FFFF) which is an invalid codepoint. in any
case, it still picks up the regression so i'm adding it.
termbox2.h
tests/test_egc/expected.ansi
tests/test_egc/test.php
tests/test_prepend.php