13.1. Introduction to Characters
Prev | Chapter 13. Characters | Next

## 13.1. Introduction to Characters [sec_13-1]

### 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 built | without UNICODE support | with UNICODE support
--- | --- | ---
`CHAR-CODE-LIMIT` | 28 = 256 | 17 * 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.45 | Last modified: 2008-05-14

Enter your search termsSubmit search form
Webclisp.cons.orgclisp.podval.orgwww.lisp.org

Prev | Up | Next
Chapter 13. Characters | Home | 13.2. Character sets