The AFP Architecture

This chapter contains information regarding technical issues in AFP (Advanced Function Printing). The information is essential in order to understand this guide. For a detailed description of all AFP technical issues, please refer to the relevant IBM publications referenced in Introduction.

AFP External Resources

There are five AFP external resources. These are:

  • Fonts

  • PAGEDEFs

  • FORMDEFs

  • Page Segments (Images)

  • Overlays

These resources are stored in system and user libraries. PSF, the AFP printer driver, dynamically manages all the resources required for AFP printing. PSF detects when an output dataset requires an external resource and retrieves the resource from the library as defined in the appropriate DD statement in the PSF procedure.

Each external resource type usually resides in a separate library. It is possible to have a number of libraries for each resource type. In this case, the libraries are concatenated in the appropriate PSF DD statements in the PSF procedure.

A number of methods exist for specifying that an external resource is required, depending on the type of resource.

Methods of assigning external AFP resources are described below.

Fonts

  • Fonts can be specified, using the CHARS parameter, in the JCL of the job that produces the output. The CHARS parameter can appear in the DD or OUTPUT statement. When using this method, the following restriction must be considered: The CHARS JCL parameter is limited to four characters, but the font name may be up to six characters (in the case of Typographic Fonts).

  • Fonts can be specified, using dynamic allocation (SVC99), in the application program that produces the output.

  • Fonts can be specified in a PAGEDEF definition (up to 6 characters).

  • If a font is not specified in any of the above, the default font specified in the PSF procedure is used. (If a CHARS subparameter is specified in the DEVICE initialization statement of JES3, then the PSF definitions are overridden.)

PAGEDEFs and FORMDEFs

  • PAGEDEFs and FORMDEFs can be specified in the JCL of the job that produces the output using the PAGEDEF and FORMDEF parameters. The PAGEDEF and FORMDEF parameters can appear only in an OUTPUT statement.

  • A PAGEDEF can also be specified using the FCB parameter in a DD statement. When using this method, the following restriction must be taken into account: The FCB parameter is limited to four characters, and a PAGEDEF name can be up to six characters.

  • If a PAGEDEF and/or FORMDEF is not specified in any of the above, the default PAGEDEF and/or FORMDEF specified in the PSF procedure is used.

Page Segments

  • Page Segments are usually specified in Overlays.

  • Page Segments can be specified in-line in the output data stream using the IPS (Include Page Segment) structured field record. The IPS record can either place the segment in a specific position relative to the page origin, or position the segment at the current print position.

  • The Page Segment can also be specified in a PAGEDEF, but this alone does not make the Page Segment print. This is only used for performance reasons and an IPS structured field is required.

  • When using DCF:Script/VS Language, use the SI (Segment Include) control word to identify a segment to be included (for example, in a specific column when the document is printed). The segment is either centered, or left or right aligned according to the current text formatting settings.

A Page Segment can be printed only in the ACROSS direction, regardless of the print direction you specify in your page definition. Therefore, you must build the Page Segment rotated to the same print direction as the page on which you are printing.

Overlays

  • Overlays are specified in a FORMDEF definition.

  • Overlays can be specified in-line in the output data stream using the IPO (Include Page Overlay) structured field (PSF version 2 and later only). Print position may be relative to the current line, or defined for a specific position on the page. The Overlays must be listed in a PAGEDEF and invoked using the IPO structured field.