utf8

Mostrar obsoleto

This library provides basic support for UTF-8 encoding. This library does not provide any support for Unicode other than the handling of the encoding. Any operation that needs the meaning of a character, such as character classification, is outside its scope.

Unless stated otherwise, all functions that expect a byte position as a parameter assume that the given position is either the start of a byte sequence or one plus the length of the subject string. As in the string library, negative indices count from the end of the string.

You can find a large catalog of usable UTF-8characters here.

Resumo

Propriedades

  • The pattern "[%z\x01-\x7F\xC2-\xF4][\x80-\xBF]*", which matches exactly zero or more UTF-8 byte sequence, assuming that the subject is a valid UTF-8 string.

Funções

char

Parâmetros

codepoints: Tuple<number>

Devolução

Parâmetros

str: string

codepoint

Parâmetros

str: string
Valor Padrão: 1
Valor Padrão: i

Devolução

Parâmetros

Valor Padrão: 1
Valor Padrão: -1

Devolução

offset

Parâmetros

Valor Padrão: 1

Devolução

graphemes

Parâmetros

Devolução

nfcnormalize

Parâmetros

str: string

Devolução

nfdnormalize

Parâmetros

str: string

Devolução

Propriedades

charpattern

The pattern "[%z\x01-\x7F\xC2-\xF4][\x80-\xBF]*", which matches exactly zero or more UTF-8 byte sequence, assuming that the subject is a valid UTF-8 string.