Public API
This page lists exported symbols of CTBase.Unicode.
From CTBase.Unicode
CTBase.Unicode [Module]
CTBase.Unicode Module
UnicodeUnicode character utilities for CTBase.
This module provides functions for converting integers to Unicode subscript and superscript characters, useful for mathematical notation and display.
ctindice [Function]
CTBase.Unicode.ctindice Function
ctindice(i::Int64) -> CharReturn the integer i ∈ [0, 9] as a Unicode subscript character.
Throws an CTBase.Exceptions.IncorrectArgument exception if i is outside this range.
The Unicode subscript digits start at codepoint U+2080 for '0' and continue sequentially.
Example
julia> using CTBase
julia> CTBase.ctindice(3)
'₃': Unicode U+2083 (category No: Number, other)ctindices [Function]
CTBase.Unicode.ctindices Function
ctindices(i::Int64) -> StringReturn the integer i ≥ 0 as a string of Unicode subscript characters.
Throws an CTBase.Exceptions.IncorrectArgument if i is negative.
Example
julia> using CTBase
julia> CTBase.ctindices(123)
"₁₂₃"ctupperscript [Function]
CTBase.Unicode.ctupperscript Function
ctupperscript(i::Int64) -> CharReturn the integer i ∈ [0, 9] as a Unicode superscript (upper) character.
Throws an CTBase.Exceptions.IncorrectArgument exception if i is outside this range.
Note: Unicode superscripts ¹ (U+00B9), ² (U+00B2), and ³ (U+00B3) are special cases. The other digits ⁰ (U+2070) and ⁴ to ⁹ (U+2074 to U+2079) are mostly contiguous.
Example
julia> using CTBase
julia> CTBase.ctupperscript(2)
'²': Unicode U+00B2 (category No: Number, other)ctupperscripts [Function]
CTBase.Unicode.ctupperscripts Function
ctupperscripts(i::Int64) -> StringReturn the integer i ≥ 0 as a string of Unicode superscript characters.
Throws an CTBase.Exceptions.IncorrectArgument if i is negative.
Example
julia> using CTBase
julia> CTBase.ctupperscripts(123)
"¹²³"