Printer models are defined in terms of 14 attributes. Each model has a name and a UID. A printer model statement has the following syntax:
Model model-label
Name model-name [ RequiresPrinterPort ]
Uid model-UID
Flags model-flags
Resources resources-label
KPixelWidth pixel-width
KPixelHeight pixel-height
PortraitOffset left-offset right-offset
LandscapeOffset left-offset right-offset
MinMarginLeft min-left-margin
MinMarginRight min-right-margin
MinMarginTop min-top-margin
MinMarginBottom min-bottom-margin
DisplayMode display-mode
typeface-section
EndModel
Note that:
margins are measured in pixels
the Flags attribute allows the driver-writer to specify any flags for this model, and they are interpreted in the .pdl
code. These
flags are normally used to distinguish the capabilities of different models of printer within the same driver.
Model HPLJ3
Name "HP LaserJet III" RequiresPrinterPort
Uid 268435723
Flags 0
Resources Pcl5dResources
KPixelWidth 4800 ! Twips = 300 dots per inch
KPixelHeight 4800
PortraitOffset 75 0 ! Pixels
LandscapeOffset 60 0
MinMarginLeft 50 ! Pixels
MinMarginRight 50
MinMarginTop 50
MinMarginBottom 50
DisplayMode Gray2
TypefaceFontss
Courier
LinePrinter
CgTimes
Univers
EndTypefaceFontss
EndModel