Digital ANSI-Compliant Printing Protocol Level 3 Programming Reference Manual

*HyperReader

  CONTENTS

  Title Page

  Copyright Page

  Preface

  1      Protocol Concepts

  1.1     Levels of the Protocol

  1.2     Extensions and Exceptions to the Protocol

  1.3     Relationship to the Printing Environment

  2      Character Processing

  2.1     Coded Characters

  2.2     Printable Characters
    2.2.1      Selecting Graphic Character Sets

  2.3     Control Characters

  2.4     Special Characters
    2.4.1      Processing 2/0
    2.4.2      Processing 7/15
    2.4.3      Processing 10/0
    2.4.4      Processing 15/15

  2.5     Control Functions
    2.5.1      Escape Sequence Format
    2.5.2      Control Sequence Format
      2.5.2.1      Parameter Values in Control Sequences
      2.5.2.2      Private Parameters
      2.5.2.3      Selectable Modes
    2.5.3      Control Strings
      2.5.3.1      Device Control String Format
      2.5.3.2      Application Program Command, Operating System Command, and Privacy Message Control Strings
    2.5.4      Special Parsing Requirements

  3      Page Coordinate System

  3.1     Coordinate System Models
    3.1.1      Character Cell Model
    3.1.2      Point Model
    3.1.3      Conformance to Models
    3.1.4      Origin and Extent
    3.1.5      Unit Conversions and the Origin

  3.2     Positioning and Movement
    3.2.1      Advance Increments
      3.2.1.1      Fixed HAI
      3.2.1.2      Font-Dependent HAI
      3.2.1.3      Proportional HAI
      3.2.1.4      Fixed VAI
      3.2.1.5      Font-Dependent VAI
    3.2.2      Positioning Control Functions

  3.3     Bounds
    3.3.1      Left Margin Position
    3.3.2      Right Margin Position
    3.3.3      Top Margin Line
    3.3.4      Bottom Margin Line
    3.3.5      Line Home Position
    3.3.6      Line End Position
    3.3.7      Page Home Line
    3.3.8      Page End Line

  3.4     Limits at the Printable Area

  3.5     Logical Page to Physical Sheet Mapping

  3.6     Variable Paper Size Mapping

  3.7     Minimum Size of Printable Area

  3.8     First Character Flag

  3.9     Partial Line Motion (PLU and PLD)

  3.10    Side Effects of Positioning Controls

  3.11    Tabs

  3.12    Duplex Command Set
    3.12.1     Logical and Physical Duplex
    3.12.2     Tumbling
    3.12.3     Newsheet
    3.12.4     Duplex Examples

  3.13    Conditional Form Feed

  3.14    Conditional Sheet Feed

  3.15    Page Break

  4      Fonts

  4.1     Character Sets

  4.2     Fonts
    4.2.1      Font Attributes
    4.2.2      Type Family
    4.2.3      Font Collection
    4.2.4      Font Collection Plus
    4.2.5      Font
    4.2.6      Font File

  4.3     The Font Repertory
    4.3.1      Font Cartridges
    4.3.2      Algorithmic Transformations
    4.3.3      Supported Character Sets

  4.4     The Font Selection Process
    4.4.1      Font Dictionary
    4.4.2      Current Font Definition (CFD)
      4.4.2.1      Type Family
      4.4.2.2      Spacing
      4.4.2.3      Type Size
      4.4.2.4      Scale Factor
      4.4.2.5      Style
      4.4.2.6      Weight
      4.4.2.7      Proportion
      4.4.2.8      Rotation
      4.4.2.9      Character Set
    4.4.3      Font Grading
      4.4.3.1      Type Family
      4.4.3.2      Spacing Criterion
      4.4.3.3      Spacing Value
      4.4.3.4      Type Size
      4.4.3.5      Scale Factor
      4.4.3.6      Style
      4.4.3.7      Weight
      4.4.3.8      Proportion
      4.4.3.9      Rotation
      4.4.3.10     Character Set
    4.4.4      Font Selection
      4.4.4.1      Order of Evaluation
      4.4.4.2      Equivalent Grades
    4.4.5      Imaging Algorithmic Transformations
      4.4.5.1      Type Family
      4.4.5.2      Spacing Criterion
      4.4.5.3      Spacing Value
      4.4.5.4      Type Size
      4.4.5.5      Bold (Weight)
      4.4.5.6      Italic (Style)
      4.4.5.7      Underline (Style)
      4.4.5.8      Overline (Style)
      4.4.5.9      Double Underline (Style)
      4.4.5.10     Character Set

  4.5     Downloading Font Files
    4.5.1      Sixel Encoding of Binary Data
    4.5.2      Initial Font File Orientation
    4.5.3      Validation of a Font File Record

  5      Sixel Graphics

  5.1     Terminology and Concepts

  5.2     Converting Sixel Data

  5.3     Selecting Sixel Graphics Mode

  5.4     Protocol Structure
    5.4.1      Protocol Selector - Formatting Information
      5.4.1.1      Ps1
      5.4.1.2      Ps2
      5.4.1.3      Pn3
      5.4.1.4 q - Sixel Graphics Protocol Selector Final
    5.4.2      Picture Data
    5.4.3      String Terminator

  5.5     Character Processing in Sixel Graphics Mode
    5.5.1      Sixel Printable Characters
    5.5.2      Sixel Graphics Control Codes
    5.5.3      Numeric Parameters
    5.5.4      Parameter Separator
    5.5.5      Exiting Sixel Graphics Mode

  5.6     Sixel Graphics and Text Interactions
    5.6.1      State upon Entering Sixel Graphics Mode
    5.6.2      Interaction with Text Margins
    5.6.3      Interaction with the First Character Flag
    5.6.4      State After Exiting Sixel Graphics Mode

  5.7     Graphics Programming Considerations
    5.7.1      Parameter Usage and Interactions
    5.7.2      Compatibility
    5.7.3      Quality
    5.7.4      Compatibility or Quality

  5.8     Sixel Control Codes

  DECGCI (#) - Graphics Color Introducer

  DECGCR ($) - Graphics Carriage Return

  DECGNL (-) - Graphics Next Line

  DECGRA (") - Set Raster Attributes

  DECGRI (!)  - Graphics Repeat Introducer

  6      Control Characters

  6.1     Control Characters

  6.2     C0 Control Characters

  6.3     C1 Control Characters

  7      Command Dictionary

  ASCEF - Announce Subset of Code Extension Facilities

  CPR - Cursor Position Report

  CRM - Control Representation Mode

  CUU - Cursor Up

  DA - Device Attributes

  DAR (generic response) - Device Attributes Report

  DAR (alias response) - Device Attributes Report

  DA2 - Secondary Device Attributes

  DA2R - Secondary Device Attributes Report

  DECASFC - Automatic Sheet Feeder Control

  DECATFF - Assign Type Family or Font

  DECAUPSS - Assign User Preference Supplemental Set

  DECAWM - Autowrap Mode

  DECCAHT - Clear All Horizontal Tabs

  DECCAVT - Clear All Vertical Tabs

  DECCRNLM - Carriage Return /New Line Mode

  DECDTFF - Delete Type Family or Font

  DECFIN - Document Finishing

  DECFSR - Font Status Report (0 or 1)

  DECFSR - Font Status Report (0 or 2)

  DECHTS - Horizontal Tab Set

  DECIPEM - Entering IBM Proprinter Emulation Mode

  DECIPEM - Returning from IBM Proprinter Emulation Mode

  DECLFF - Load Font File

  DECMM - Memory Management

  DECNS - Newsheet

  DECOPM - Origin Placement Mode

  DECPSM - Pitch Select Mode

  DECPSP - Proportional Spacing Mode

  DECRFS - Request Font Status

  DECRVEC - Draw Relative Vector

  DECSCL - Select Conformance Level

  DECSDPM - Set Duplex Print Mode

  DECSHORP - Set Horizontal Pitch

  DECSHTS - Set Horizontal Tab Stops

  DECSLPP - Set Lines per Physical Page

  DECSLRM - Set Left and Right Margins

  DECSNC - Set Number of Copies

  DECSSS - Set Sheet Size

  DECSTBM - Set Top and Bottom Margins

  DECSTR - Soft Terminal Reset

  DECSVTS - Set Vertical Tab Stops

  DECVEC - Draw Vector

  DECVERP - Set Vertical Pitch

  DECVPFS - Variable Page Format Select

  DECVTS - Vertical Tab Set

  DSR - Device Status Request

  DSR - Device Status Report

  GSM - Graphic Size Modification

  GSS - Graphic Size Selection

  HPA - Horizontal Position Absolute

  HPB - Horizontal Position Backward

  HPR - Horizontal Position Relative

  JFY - Justify

  LNM - Line Feed/New Line Mode

  LS * /LS * R/SS * - Locking and Single Shifts

  PFS - Page Format Select

  PUM - Positioning Unit Mode

  RIS - Reset to Initial State

  ROCS - Return from Other Coding System

  SCS - Select Character Set

  SGR - Select Graphic Rendition - Selecting Attributes

  SGR - Select Graphic Rendition - Selecting Fonts

  SHS - Set Horizontal Spacing

  SnC1R/DEC * C1 - C1 Transmit/Receive

  SOCS - Select Other Coding System

  SPI - Spacing Pitch Increment

  SSU - Select Size Unit

  SVS - Set Vertical Spacing

  TBC - Tab Clear

  VPA - Vertical Position Absolute

  VPB - Vertical Position Backward

  VPR - Vertical Position Relative

  A   Character Sets

  A.1     ASCII Character Set

  A.2     DEC Supplemental Character Set

  A.3     DEC Special Graphics Character Set

  A.4     DEC Technical Character Set

  A.5     ISO Latin Alphabet No.  1 Supplemental Character Set

  A.6     National Replacement Character (NRC) Sets

  A.7     Legal Character Set

  A.8     Hebrew Character Sets

  A.9     JIS Katakana Character Set

  B   Common Font File Format

  FIGURES

  2-1        Standard 8-Bit Code Table (Left Half)

  2-2        Standard 8-Bit Code Table (Right Half)

  2-3        Designating and Invoking Character Sets

  2-4        Escape Sequence Example

  2-5        Control Sequence Example

  3-1        Bounds in the Page Coordinate System

  3-2        HAI Equal to the Character Box

  3-3        HAI Greater Than the Character Box

  3-4        HAI Less Than the Character Box

  3-5        Logical Page and Physical Sheet Alignment

  3-6        Input for Duplex Examples

  3-7        True Duplex and Simplex Examples

  3-8        Duplex Master and Simplex Compressed Examples

  4-1        Three Bytes of Buffer Data

  5-1        Sixel Representation

  5-2        Sixel Graphics Device Control String (DCS) Envelope

  A-1        ASCII Character Set

  A-2        DEC Supplemental Character Set

  A-3        DEC Special Graphics Character Set

  A-4        DEC Technical Character Set

  A-5        ISO Latin Alphabet No.  1 Supplemental Character Set

  A-6        British Character Set

  A-7        DEC Finnish Character Set

  A-8        French Character Set

  A-9        DEC French-Canadian Character Set

  A-10       German Character Set

  A-11       ISO Italian Character Set

  A-12       JIS Roman Character Set

  A-13       DEC Norwegian/Danish Character Set

  A-14       ISO Spanish Character Set

  A-15       DEC Swedish Character Set

  A-16       Norwegian/Danish Character Set

  A-17       DEC Dutch Character Set

  A-18       DEC Swiss Character Set

  A-19       DEC Portuguese Character Set

  A-20       Legal Character Set

  A-21       DEC 7-Bit Hebrew Character Set

  A-22       DEC Hebrew Supplemental Character Set

  A-23       ISO Latin-Hebrew Supplemental Character Set

  A-24       JIS Katakana

  TABLES

  2-1        7-Bit and 8-Bit Control Character Equivalence

  2-2        Special Character Parsing

  3-1        Positioning Controls and Commands

  3-2        Printable Areas by Paper Size

  3-3        Side Effects of Vertical Positioning Controls

  3-4        Side Effects of Horizontal Positioning Controls

  3-5        Logical and Physical Print Mode Interactions

  4-1        Spacing Components

  5-1        Macro Parameter Selections

  5-2        Printable Dot Patterns for Sixel Graphics Mode

  5-3        Sixel Graphics Control Codes

  5-4        Compatible Dot Matrix/Printer Graphics

  7-1        Extension Parameters for Generic Primary DA Response

  7-2        Relative Vectors

  7-3        Page Length Parameters

  7-4        DECVPFS Selective Parameters

  7-5        PFS Margins and Format for Executive-Size Paper

  7-6        PFS Margins and Format for JIS-B5-Size Paper

  7-7        PFS Margins and Format for A5-Size Paper

  7-8        PFS Margins and Format for JIS-B4-Size Paper

  7-9        PFS Margins and Format for A3-Size Paper (397 mm X 420 mm)

  7-10       Standard Paper Sizes

  7-11       Left Anchor

  7-12       PFS Margins and Format for 8½ In.  x 11 In.  Paper

  7-13       PFS Margins and Format for 8½ In.  x 11 In.  Paper (Private)

  7-14       PFS Margins and Format for A4-Size Paper

  7-15       PFS Margins and Format for A4-Size Paper (Private)

  7-16       PFS Margins and Format for Legal-Size Paper

  7-17       Select Character Set Intermediate Character

  7-18       SCS Final Characters

  7-19       SCS Fallbacks

  7-20       SVS (Set Vertical Spacing) Millimeter Approximations

  7-21       SVS (Set Vertical Spacing) Error Accumulation over 25 cm.

  A-1        DEC Technical Character Set Component Characters

  B-1        CFFF Fields