13.1. Introduction to Characters [sec_13-1]

13.1.1. Function CHAR-CODE
13.1.2. Type BASE-CHAR
13.1.3. Function EXT:CHAR-WIDTH

13.1.1. Function CHAR-CODE

CHAR-CODE takes values from 0 (inclusive) to CHAR-CODE-LIMIT (exclusive), i.e., the implementation supports exactly CHAR-CODE-LIMIT characters.

Table 13.1. Number of characters

binaries builtwithout UNICODE supportwith UNICODE support
CHAR-CODE-LIMIT28 = 25617 * 216 = 1114112

13.1.2. Type BASE-CHAR

The types EXT:STRING-CHAR and BASE-CHAR are equivalent to CHARACTER. EXT:STRING-CHAR used to be available as STRING-CHAR prior to removal from [ANSI CL standard] by CHARACTER-PROPOSAL:2.

13.1.3. Function EXT:CHAR-WIDTH

(EXT:CHAR-WIDTH char) returns the number of screen columns occupied by char. The value is

0
for non-spacing characters (such as control characters and many combining characters);
2
for double-width East Asian characters;
1
for all other characters.

See also function EXT:STRING-WIDTH.


These notes document CLISP version 2.49Last modified: 2010-07-07