Hewlett-Packard Vancouver Site
Preface and Printing History
Printing History
About this Developer’s Guide
Which printers are covered by this guide1
Special Notes
Special Note HP DeskJet 710C, 720C and 820C Series printers
Table of Contents
HP PCL Commands
Fonts
HP LaserJet Bitmap Character Definition
Printer Commands
Length set to 66 lines
Setting
How This Developer’s Guide Works
Length is set, in number
Command Options F
Command Summary D
Command Usage Table E
Command Option Recognition Grid G
Detailed Command Description
Important Point
Introduction to HP PCL
What are Printer Commands?
HP PCL Commands
History of HP PCL Printer Language
Syntax of Escape Sequences
Two-Character Escape Sequences
Parameterized Escape Sequences
Esc & l 1 O
Esc
Text Area
Logical Page, Physical
Layout
Current Active Position CAP
CAP Position
CAP Reference Point
Print Environment
Merged Text and Graphics
Programming Hints
Follow Specifications
Priority of Feature Set Commands
Leverage from Previous Programs
Priority of Commands
Time Savers
Programming Hints
Control Codes and Special Character Codes
HP PCL Commands
Testing Commands
Print Modes
Display Functions turned on
Display Functions Mode on
Display Functions Mode OFF
Display Functions turned off
Text Enhancements
CR = CR LF = CR, LF FF =
CR = CR LF = LF FF = FF
CR = CR, LF LF = LF FF = FF
CR = CR, LF LF = CR, LF FF
Enables End-of-Line Wrap
Disables End-of-Line Wrap
End-of-Line Wrap
Reset Esc E
Job Control
Gray Balance Default Modes
Printer Control
Gray Balance
Dry Timer
Dry Timer Defaults
Normal quality selected
EconoFast mode selected
Print Quality
Best quality selected
Special paper HP Premium
Plain paper
Bond paper
Inkjet Paper
HP PCL Commands
Printer Diagnostics
Self-Test Esc z
Control
Length Line Values
By value index in the following
Size
Size set to that indicated
Tables
Value Description
Unchanged
Load z-fold media banners
Print current page source is
Load from tray
Landscape
Orientation
Portrait
Reverse Portrait
Horizontal Motion Index
Number of 1/120 inch
Increments
Between rows
Vertical Motion Index
Number of 1/48 inch increments
Out of range values
Per inch
Line Spacing
Sets the number of lines printed
Clear Horizontal Margins
Edge of the specified column
Left Margin
Sets the left margin to the left
Right Margin
Top margin is set to specified
Lines-per-inch setting
Top Margin
Number of lines at the current
Sets length of the text area,
Disables perforation skip mode
Enables perforation skip mode
Lines, from the top margin
HP PCL Commands
Carriage Return
Horizontal Positioning Commands
Backspace
Space
Formfeed
Horizontal Tab
Specified number of decipoints
Move CAP Horizontal Decipoints
Moves CAP horizontally by
Inch
Specified number of HP PCL
Specified number of columns
Limit
Units
HP PCL Commands
Moves CAP to the same
Vertical Positioning Commands
Move CAP Vertical Rows
Column position on a new line
Move CAP Vertical Decipoints
Moves CAP to a new position
Along the vertical axis
HP PCL units along the Y
Move CAP Vertical HP PCL Units
Moves CAP specified number
Axis
Font Symbol Set
Font Selection
Font Selection by Attribute
Symbol Set Name
TIS TAPCI23
Inter character spacing for
Fixed spacing
Proportional spacing
Current font is set
Font Height
Height for current font is set
Specified characteristics are
Font Style
Applied to font style request
Matching Algorithm
Extra thin
Book or text weight
Ultra thin
Thin
Font Selection by ID
Font with indicated ID is
Selected
Font ID Esc * c # D
Downloading Fonts
Download Font Esc s # W font definition
Download Font
Character Code
Download Character
Delete all temporary fonts
Delete all fonts temp
Permanent, and soft
Temp, permanent, and soft
Commands Allowed in Raster Mode
Raster Mode
Commands Locked Out of Raster Mode
Raster Graphics
Start graphics at logical
Printer returns to text mode
Command processing
Left boundary current vertical
Graphics data printed at 150 dpi
Graphics data printed at 75 dpi
Graphics data printed at 100 dpi
Graphics data printed at 300 dpi
Raster region width is set to
Current resolutiona
Source Raster Width
Specified number of pixels at
Number of raster lines of vertical
Offset
Cursor is moved specified
Movement
Graphics data for a single plane
Raster Data Transfer
Specified number of bytes
Data is set to the printer.
Data bytes sent to the printer as
Transfer Raster by Row/Block
Following specified number
Data
Raster Compression
Method 2 Tagged Image File Format Encoding Tiff revision
Has precedence if it is met before the literal run count
Replacement count 1 Left offset from the current byte O
Method 3 Delta Row Encoding
Delta ROW Example
Row 2 Esc * b 2 W
Method 9 Compressed Replacement Delta Row Encoding
Row 1 Esc * b 3 m 2 W 00000001
Row 3 Esc * b 5 W 000000000000111100100010101010101010
Control Bit
Control Bit =
HP PCL Commands
Planes, device CMY palette
Color
Single plane K palette
Planes, device RGB palette
White no ink Black
Black/Yellow Black/Magenta
Foreground Color
Specified by the given index
Current palette
Planes per Row Index Color
Planes per Row Index Color Printed
Fonts
Standard Bitmap Font Definition
Format
Resolution-Specified Bitmap Font Definition
Symbol Set Type Ubyte
Font Descriptor Size Uint
Descriptor Format Ubyte
Font Type Ubyte
Style MSB Uint
Cell Height Uint
Baseline Position Uint
Cell Width Uint
Orientation Ubyte
Character Set UINT16
Symbol Set Uint
Spacing Bool
Pitch Uint
XHeight Uint
Stroke Weight Sbyte
Height Uint
Width Type Sbyte
Typeface LSB/MSB Ubyte
Typeface Family Value
Serif Style Ubyte
Quality
Underline Thickness Ubyte
Placement
Underline Position Sbyte
Text Height Uint
Pitch Extended Ubyte
First Code Uint
Last Code/Number of Chars Uint
Height Extended Ubyte
Font Number Uint
Resolution Uint
Cap Height Uint
Font Name ASC16
Segment Size
Copyright
Font Scaling Technology
102
Bitmap Resolution Segment
Resolution UINT16
103
Style UINT32
Stroke Weight UINT32
Character Enhancement Segment
104
Sizing UINT16
105
Half-Width-Space Character Code
Dual-Pitch-Space Char Segment
Full-Width-Space Character Code UINT16
106
HP LaserJet Bitmap Character Definition
Format Ubyte
107
Class Ubyte
Continuation Bool
Descriptor Size Ubyte
108
109
Class 2 Compressed Bitmap Character Data 110
Character Width Uint
Left Offset Sint
Top Offset Sint
Character Height Uint
Delta X Sint
Character Data
112
Banner Printing
Esc & l # H
113
Moving to a New Logical
Command Sequence
Margins
Unloading Continuous Media
Sample HP PCL for a Banner Print Job
Power-On with Continuous Media
Power-Off with Continuous Media
Printing Cutsheet with Z-Fold Media
HP PCL Code Samples
Formatting Program Example
116
117
Commands Sent to Printer
118
14.3 3-Plane Color Graphics
119
14.4 4-Plane Color Graphics
120
121
Printer Commands
122
123
Comments & Feedback
Other Resources for Assistance
HP Developer Exchange
124