screen: use UTF-8 representation

Store text in ScreenLines as UTF-8, so it can be sent as-is to the UI
layer. `utfc_char2bytes(off,buf)` is removed, as `ScreenLines[off]` now
already contains this representation.

To recover the codepoints that the screen arrays previously contained, use
utfc_ptr2char (or utf_ptr2char to ignore composing chars).

NB: This commit does NOT change how screen.c processes incoming UTF-8 data
from buffers, cmdline, messages etc. Any algorithm that operates on UCS-4
(like arabic shaping, treatment of non-printable chars)
is left unchanged for now.
This commit is contained in:
Björn Linse
2018-02-10 11:03:59 +01:00
parent 315b7f8632
commit d8e18c96a9
5 changed files with 365 additions and 667 deletions

File diff suppressed because it is too large Load Diff