RPM ASA Transform

Sat, 10/05/2019 - 19:28 By Dave Brooks

What it does

Converts ASA carriage control to text markup.

Purpose

ASA is one of the early forms of text markup used on the Internet; this transform converts ASA into our own internal format, for producing PDF, printing PCL on a printer, etc. For documentation on ASA carriage controls, please see RFC 454, section III.B (at the end) and RFC 189, Appendix C.

Setup

  • Page Margins Select the size (in inches) of the top, bottom, left, and right margins.
  • Use Lines per inch When selected, the vertical size of the font will be scaled to print only the configured number of lines per inch.
    Note: Use the following formula to calculate lines per inch. LPI = Lines / (Paper Height - (left margin + right margin))
  • Fit lines per page When selected, the font size will be scaled to fit the configured number of lines on the page.
  • Use Characters per inch When selected, the horizontal size of the font will be scaled to print the configured number of characters per inch.
    Note: Use the following formula to calculate characters per inch. CPI = Characters / (Paper Width - (left margin + right margin))ASA to Text Markup
  • Fit columns per line When selected, the font size will be scaled to fit the configured number of characters horizontally on the page.
  • Select Font Click the Font button to change the font that will be applied to the entire document when printed.
  • Input codepage The character set, or encoding, of the incoming print documents.
  • Orientation Specifies the orientation of the orientation to be used during output.
  • Wrap lines Add line breaks if a line does not fit within the printable width of the paper. If not selected, long lines will be truncated.
  • Remove control characters When selected, non-whitespace characters with an ASCII value less than 0x19 will be removed.
  • Suppress blank pages If the document has any blank pages, they will not be printed. You may want this option turned off if you are printing duplex documents.

ASA commands

The first byte of each line contains a command character, which RPM interprets this way.

  • 0 (zero) = this line to be double-spaced
  • 1 (one) = this line to start on a new page
  • + (plus) = overwrite the previous line; used to bold, underline, or overstrike words or characters.
  • - (dash) = this line to be triple-spaced

Any other character causes the line to be single-spaced.