Specifies the handling of unmapped characters. The function performs more quickly when none of these flags is set.
The following flags can be used:
- COMPOSITECHECK
Converts composite characters to precomposed characters.
- SEPCHARS
Generates separate characters during conversion. This is the default conversion behavior.
- DISCARDNS
Discards nonspacing characters during conversion.
- DEFAULTCHAR
Replaces non-convertible characters with the default character during conversion.
When compositecheck
is specified, the function converts composite characters to precomposed characters. A composite character consists of a base character and a nonspacing character, each having different character values. A precomposed character has a single character value for a combination of a base and a nonspacing character. In the character è, the "e" is the base character, and the "grave" accent mark is the nonspacing character.
When compositecheck
is specified, it can use the last three flags in this list (discardns, sepchars
, and defaultchar
) to customize the conversion to precomposed characters. These flags determine the function's behavior when there is no precomposed mapping for a combination of a base and a nonspace character in a Unicode character string. These last three flags can be used only if the compositecheck
flag is set. The function's default behavior is to generate separate characters (sepchars
) for unmapped composite characters.