Expand description
Methods for normalizing Latin1 input into a UTF-16 sink.
NFC is not available, since Latin1 input is already known to be in NFC.
Constantsยง
Staticsยง
- COMPATIBILITY_
DECOMPOSITIONS ๐ - Table containing the compatibility decompositions.
- TABLE ๐
- Entries start from U+00A0 NO-BREAK SPACE. If the character is
always its own normalization, the value in the table is 0.
If the character has a compatibility decompositons, the value
in the table is the index into
COMPATIBILITY_DECOMPOSITIONSshifted left by two and the length of the subslice ofCOMPATIBILITY_DECOMPOSITIONSin the low 2 bits. This means that the high half is zero. Otherwise, the high 8 bits are the first character of the canonical decomposition and the low 8 bits are the offset that needs to be added to U+0300 to get the second character of the canonical decomposition.
Functionsยง
- compatibility_
decomposition ๐ - Writes the compatibility decomposition of
ctosink. - normalize_
nfd_ to - Normalize Latin1
textto NFD UTF-16 written tosink. - normalize_
nfkc_ to - Normalize Latin1
textto NFKC UTF-16 written tosink. - normalize_
nfkd_ to - Normalize Latin1
textto NFKD UTF-16 written tosink. - split_
normalized_ nfd - Split Latin1
textinto(head, tail)such that the first byte oftailis the first byte of input that is not in NFD. Iftextis fully in NFD,tailis empty. - split_
normalized_ nfkc - Split Latin1
textinto(head, tail)such that the first byte oftailis the first byte of input that is not in NFKC. Iftextis fully in NFKC,tailis empty. - split_
normalized_ nfkd - Split Latin1
textinto(head, tail)such that the first byte oftailis the first byte of input that is not in NFKD. Iftextis fully in NFKD,tailis empty.