package lablgtk3
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=4014ac73afd502cfce862fc65a3c77372fb191a8f317d6803f1a9372172bd1ca
md5=7f0027b74aaa85329dacba062e1c2b95
doc/lablgtk3/Gutf8/index.html
Module Gutf8
Pure ocaml module for conversion between UCS and UTF8
type unistring = unichar array
val from_unichar : unichar -> string
from_unichar 0xiii
converts a code point iii
(usually in hexadecimal form) into a string containing the UTF-8 encoded character 0xiii
. See unicode.org for charmaps. Does not check that the given code point is a valid unicode point.
val from_unistring : unistring -> string
to_unichar_validated
decodes an UTF-8 encoded code point and checks for incomplete characters, invalid characters and overlong encodings.
to_unichar
decodes an UTF-8 encoded code point. Result is undefined if pos
does not point to a valid UTF-8 encoded character.
val to_unistring : string -> unistring
to_unistring
decodes an UTF-8 encoded string into an array of unichar
. The string must be valid.
val first_char : string -> unichar
first_char
returns the first UTF-8 encoded code point.
next
returns the position of the code point following the one at pos
.
module Error : sig ... end
to_unichar_validated
may raise PARTIAL_INPUT
or ILLEGAL_SEQUENCE