The unicode API provides codepoint-aware string helpers and display-width helpers for terminal-safe text handling.
- Repository:
opencomputers - Type: core runtime API
OpenComputers/src\main\scala\li\cil\oc\server\machine\luac\UnicodeAPI.scala
local unicode = require("unicode")
print(unicode.len("hello"))- Description: Create a string from one or more Unicode codepoints.
- Description: Return the codepoint length of a string.
- Description: Return a lowercase version of the string.
- Description: Return the reversed Unicode string.
- Description: Return a substring by codepoint index.
- Description: Return an uppercase version of the string.
- Description: Return whether the first codepoint is wide.
- Description: Return the display width of the first codepoint.
- Description: Return the display width of a string.
- Description: Truncate a string to a target display width.
computercomponentosunicode