
Switching Fonts
Set a Primary and Secondary Font
For PCL5, you can set one Primary and one Secondary font, then use the SI and SO commands to switch between them.
Commands used:
Command | ASCII | Hexadecimal | ||
|
|
|
| |
Assign FontID | <ESC> * c # D | 1B | 2A 63 # 44 | |
|
|
|
|
|
Assign FontID to FontFile in storage | <ESC> & n # W [01] | 1B | 26 | 6E # 57 [01] |
|
|
|
|
|
Set primary font by FontID | <ESC> ( # X | 1B | 28 | # 58 |
|
|
|
|
|
Set secondary font by FontID | <ESC> ) # X | 1B | 29 | # 58 |
|
|
|
|
|
Switch to primary font | SI | 0F |
|
|
|
|
|
|
|
Switch to secondary font | SO | 0E |
|
|
|
|
|
|
|
Example
To set the default resident font Courier as the Primary font and the downloaded font Download1.bin as the Secondary font, then switch between them:
<ESC>*c1000D<ESC>&n12W<01>Download1.bin
|
| / * assign Font ID 1000 to Download1.bin */ | |
<ESC>)1000X | /* Set Downloaded font as Secondary font */ | ||
<0F>[DATA | STRING].<0D><0A> | / * Select Primary font */ | |
<0E>[DATA | STRING].<0D><0A> | / * Select Secondary font */ | |
<0F>[DATA | STRING].<0D><0A> | / * Select Primary font */ | |
<0E>[DATA | STRING].<0D><0A> | / * Select Secondary font */ | |
<0C> |
|
|
|
27Printing Using Fonts and Forms