mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-22 03:02:06 +00:00
Add support for multiple charmaps
This adds two new directives: newcharmap and setcharmap. newcharmap creates a new charmap and switches to it. setcharmap switches to an existing charmap.
This commit is contained in:
@@ -1140,9 +1140,27 @@ CHARMAP "í", 20
|
||||
CHARMAP "A", 128
|
||||
.Ed
|
||||
.Pp
|
||||
It is possible to create multiple character maps and then switch between them
|
||||
as desired. This can be used to encode debug information in ASCII and use
|
||||
a different encoding for other purposes, for example. Initially, there is
|
||||
one character map called
|
||||
.Sy main
|
||||
and it is automatically selected as the current character map from the
|
||||
beginning.
|
||||
.Bl -column "NEWCHARMAP name, basename"
|
||||
.It Sy Command Ta Sy Meaning
|
||||
.It Ic NEWCHARMAP Ar name Ta Creates a new, empty character map called
|
||||
.Ic name .
|
||||
.It Ic NEWCHARMAP Ar name , basename Ta Creates a new character map called
|
||||
. Ic name ,
|
||||
copied from character map
|
||||
.Ic basename .
|
||||
.It Ic SETCHARMAP Ar name Ta Switch to character map Ic name .
|
||||
.El
|
||||
.Pp
|
||||
.Sy Note:
|
||||
Character maps affect all strings in the file from the point in which they are
|
||||
defined.
|
||||
defined, until switching to a different character map.
|
||||
This means that any string that the code may want to print as debug information
|
||||
will also be affected by it.
|
||||
.Pp
|
||||
|
||||
Reference in New Issue
Block a user