Updated July 3 2003
Font Selection using Characteristics
Here is a basic introduction to font selection using the
characteristics of the font.
- fixed bit-pattern for each character, size is fixed. Scalable font - outline of the
characters, easily scaled to produce range of sizes. *1
- resident on printer ROM or downloaded. Soft font - resides in RAM
There are two methods used to select fonts. With the first, soft
fonts can be specified using their associated ID numbers –
<Esc>(#X for primary fonts, and <Esc>)#X for secondary
fonts, where # is the soft font ID. I will be adding this
information as soon as time permits.
The second method is to use the Font Select Table. There are two
independent font select tables: primary font (SI) and secondary font
(SO) table. These tables store the values of the characteristics
of their current fonts. The default settings come from the control
panel settings. We can change the values in these tables by
sending PCL commands. After changes are made the machine performs
a “Font Select”.
A Font Select searches available fonts and scalable typefaces to select
the one that most closely matches the characteristics in the font select
table. It is an elimination process with 9 (10) steps. Start
with all the fonts. Check the first characteristic and remove all
fonts that do not have this characteristic. Move to the next
characteristic with the remaining fonts and only keep the fonts that
have this characteristic. And the beat goes on till these is only
one font is left. This could be while still in the middle of the
table or right at the very end.
Resolution is a step, but not really counted. That is why I have
the (10) above. At 300dpi, 600dpi bitmap fonts are eliminated
before the selection begins. At 600dpi, the priority is 600dpi
bitmap, scalable, 300dpi bitmap fonts.
Considerations from highest priority
1. Symbol set
6. Stroke Weight
7. Typeface Family
All command examples are based on the primary font table
<ESC>(ID, where ID is the symbol set
Identifies the specific collection of symbols provided by a font.
Spacing <ESC>(s#P, where # is 0 for fixed and 1 for
Fixed-spaced and proportionally-spaced. In fixed-spaced the
inter-character spacing is equal whereas in proportional-spaced fonts
the inter-character spacing varies with the shape of the character.
Pitch <ESC>(s#H, where # is the number of characters
Number of characters per inch (for fixed-spaced fonts only) common ones
are 10, 12, 16.67. Used to calculate height for fixed-spaced
Height <ESC>(s#V, where # is the number of points
Ignored for fixed-spaced scalable fonts. Measured in points, it
is the height for the body of the type or "Em" *3
For bitmap and TrueType fonts there are 72 points in an inch. For
intellifonts there are 72.307 point in an inch.
Style <ESC>(s#S, where # is the number corresponding
to the style type.(1 is italic)
Posture (upright or italic)
Width (condensed, normal, expanded, …)
Structure (solid, outline, shadow, …)
Stroke weight <ESC>(s#B, where # is the number
corresponding to the weight. (3 is bold)
Thickness of the stroke. Light, standard, bold, …
standard is also called medium.
Typeface Family <ESC>(s#T, where # is the number
corresponding to the typeface. (16602 is Arial)
Comic Sans, Arial, line printer, … the character design.
For older printers with SIMM Fonts and Cartridge fonts
Soft font have priority over internal fonts
For bitmap fonts – if more than one font still exists at this point,
the orientation of the font is considered.
Landscape, reverse landscape, portrait, reverse portrait
The commands and their values for changing all these features can be
found in the HP PCL Comparison Guide.
Following the example on a previous page... Lets say we want to used a
fixed spaced font at 12 CPI, what would we need to do?
The escape sequence for Fixed-spaced fonts is <ESC>(s0P and we
already know the escape sequence for 12 CPI is <ESC>(s12H
Notice that the parameterized character and the group character are the
same(they both deal with font selection). There is a process in
place to write out commands with the same parameterized character and
group character in a short form. Notice the terminating character
in the middle of the escape sequence is now lower case, no longer
terminating the sequence just its own value. Anyway the above
You can see that this could save lots of time if you where entering 5
commands for font selection instead to the 2 we just did. Here is a real world example.
*1. Scalable font -
grouping of outline characters limited to one specific symbol set.
- grouping of outline characters of a specific typeface which can
produce multple symbol sets.
*2. Character size by spacing. Fixed space bitmap font -
both pitch and hieght are used to select the character size.
Fixed space scalable fonts - only pitch is used. Proportional
spaced fonts - only hieght is used
*3. Em - Body of the type - slightly larger than the distance
from the bottom of a descender (section below the base line) to the top
of an unaccented capital letter.
*4. Orientation - Newer printers can automatically rotate fonts
to the current orientation making all fonts available in all four
orientations. Eariler printers required the font to be in the
orientation of the page. Therefore, orientation is not as
important as it once was.