blob: 25ab2897cc5a84804b3853e5bab028906b046879 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
'\" t
.\" Copyright (c) 2025 Bruce Hill
.\" All rights reserved.
.\"
.TH Text.from_utf8 3 2025-11-29 "Tomo man-pages"
.SH NAME
Text.from_utf8 \- convert UTF8 byte list to text
.SH LIBRARY
Tomo Standard Library
.SH SYNOPSIS
.nf
.BI Text.from_utf8\ :\ func(bytes:\ [Byte]\ ->\ [Text])
.fi
.SH DESCRIPTION
Returns text that has been constructed from the given UTF8 bytes.
.SH ARGUMENTS
.TS
allbox;
lb lb lbx lb
l l l l.
Name Type Description Default
bytes [Byte] The UTF-8 bytes of the desired text. -
.TE
.SH RETURN
A new text based on the input UTF8 bytes after normalization has been applied.
.SH NOTES
The text will be normalized, so the resulting text's UTF8 bytes may not exactly match the input.
.SH EXAMPLES
.EX
assert Text.from_utf8([195, 133, 107, 101]) == "Åke"
.EE
.SH SEE ALSO
.BR Tomo-Text (3)
|