An ASCII character represented as a signed 8-bit integer (-128 to 127). Valid ASCII values are in the range 0-127. Chars may be written as literals using the $ sign. For example: $a, $b, $c. Some special characters can be expressed as literals using escape sequences (for example, $\n
for newline). See Literals: Characters for more information.
Chars may be created from Integers using the methods Integer: -asAscii and Integer: -asDigit.
Note that, while Char does not support encodings aside from ASCII—such as multi-byte encodings like UTF-8 and UTF-16, or the full Latin-1 (ISO 8859-1) character set—Chars with negative values are perfectly legal, and may be strung together in strings that use these encodings.
The SuperCollider IDE uses UTF-8 to decode and display strings. See String for more information.
Newline ($\n)
.
Carriage return ($\r)
.
Horizontal tab ($\t)
.
Form feed ($\f)
.
Vertical tab ($\v)
.
Single space ($ )
.
Comma ($,)
.
Asterisk ($*)
.
A string containing all characters allowed in a binary operator: "!@%&*-+=|<>?/"
.
the integer ASCII value of a Char.
an integer value from 0 to 9 for chars $0 to $9, and values 10 to 35 for chars $a to $z or $A to $Z.
the upper case version of a char. Nonalphabetic chars return themselves.
a lower case version of a char. Nonalphabetic chars return themselves.
whether the char is an alphabetic character.
whether the char is an alphabetic or numeric character.
whether the char is printable.
whether the char is a punctuation character.
true if the char is white space: any of [$ , $\f, $\n, $\r, $\t, $\v]
.
true if the char is a decimal digit $0 to $9.
true if the char is safe for use in a filename. Excludes the path separators / and :