IPAttributesDoc.tioga
Copyright Ó 1991 by Xerox Corporation. All rights reserved.
Ken Pier, February 3, 1992 4:27 pm PST
Michael Plass, June 16, 1993 9:52 am PDT
IPAttributesDoc
CEDAR 10.1 FOR INTERNAL XEROX USE ONLY
IPAttributesDoc
Document attributes for Interpress
Ken Pier
Ó Copyright 1992 Xerox Corporation. All rights reserved.
Abstract: Not an entire package, but found in IPRegister.df. Implements picking apart the Interpress skeleton instructions vector and translating instructions into terms, called "attributes," that the RoadRunner sequencer understands.
Created by: Ken Pier
Maintained by: Ken Pier <Pier:PARC:Xerox>
Keywords: printing instructions, Interpress, skeleton, sequencer, attributes
XEROX  Xerox Corporation
   Palo Alto Research Center
   3333 Coyote Hill Road
   Palo Alto, California 94304

For Internal Xerox Use Only
1. IPAttributes
IPAttributes interface
IPAttributes.mesa exports a single procedure, IPAttr, which is a DecomposerRegistry.AttributesProc. An Interpress decomposer, such as SimpleIPRegister.mesa by Russ Atkinson, may use this procedure to set attributes from the Interpress skeleton printing instructions vector.
IPAttributesImpl
EXPORTS IPAttributes.mesa. This implementation deals with most of the known attributes by providing dummy strings for such attributes as DocumentName and RecipientName which are not found in vanilla Interpress3.0 masters yet. It also deals with Media by interpreting only the first element of the possibly multi-element Media vector.
IPAttributesImpl2
EXPORTS IPAttributes.mesa. IPAttributesImpl2 is a more sophisticated implementation which does not provide dummy values for those which it cannot interpret and does interpret the Media vector to set as attributes the full set of mediumDescriptions found in the Media vector.
2. Use
Requiring an implementation
Use either:
Require Printing10.0 IPRegister IPAttributes
or
Require Printing10.0 IPRegister IPAttributes2
to load the desired implementation after the DummySequencer itself has been Required; see /Printing10.0/DummySequencer/DummySequencerDoc.tioga for instructions on running DummySequencer. Then type
IPAttributesOn
or
IPAttributesOff
as desired in the PSWorld Commander to enable/disable attribute setting.
If the Sequencer is started in Debug mode, IPAttributes will print out the entire IP skeleton instructions vector and its own calls to SetAttr. For example:
Instructions Vector:
[30: plex, duplex, ximageshift, n: 635, d: 100000, media, [1: [2: mediumName, defaultMedium]], plex, simplex, xImageShift, 0.0, copySelect, [2: 1, 1], copyName, [2: 10000000, null], mediaSelect, [2: 10000000, [2: 10000000, 1]], onSimplex, [2: 10000000, 1], pageSelect, [2: 10000000, [2: 10000000, 1]], breakPageFont, [3: Xerox, XC1-2-2, Modern], breakPageType, verbose, finishing, finishingNone, outputPosition, [2: 10000000, 0], set, professionalGraphics]
-- IPAttr*[Plex, 2]
-- SetAttr*[Plex, #2]
-- IPAttr*[AccountInfo, "uNkNoWn IV property: AccountInfo"]
-- SetAttr*[AccountInfo, "uNkNoWn IV property: AccountInfo"]
-- IPAttr*[Media, 216, 279, "", "white", 75]
-- SetAttr*[Media, [xSize: 216, ySize: 279, formType: , color: white, weight: 75]]
-- IPAttr*[SenderName, "uNkNoWn IV property: SenderName"]
-- SetAttr*[SenderName, "uNkNoWn IV property: SenderName"]
-- IPAttr*[ImageShift, 6, 0]
-- SetAttr*[ImageShift, [w: 6, h: 0]]
-- IPAttr*[DocumentName, "uNkNoWn IV property: DocumentName"]
-- SetAttr*[DocumentName, "uNkNoWn IV property: DocumentName"]
-- IPAttr*[Staple, FALSE]
-- SetAttr*[Staple, FALSE]
-- IPAttr*[Priority, 127]
-- SetAttr*[Priority, 127]
-- IPAttr*[RecipientName, "uNkNoWn IV property: RecipientName"]
-- SetAttr*[RecipientName, "uNkNoWn IV property: RecipientName"]

In the above example, from IPAttributesImpl, IPAttr supplies dummy or default values for elements it cannot find in the Instructions Vector. IPAttributesImpl2 simply does not provide those values, as shown below:
Instructions Vector:
[30: plex, duplex, ximageshift, n: 635, d: 100000, media, [1: [2: mediumName, defaultMedium]], plex, simplex, xImageShift, 0.0, copySelect, [2: 1, 1], copyName, [2: 10000000, null], mediaSelect, [2: 10000000, [2: 10000000, 1]], onSimplex, [2: 10000000, 1], pageSelect, [2: 10000000, [2: 10000000, 1]], breakPageFont, [3: Xerox, XC1-2-2, Modern], breakPageType, verbose, finishing, finishingNone, outputPosition, [2: 10000000, 0], set, professionalGraphics]
-- IPAttr*[Plex, #2]
-- SetAttr*[Plex, #2]
-- IPAttr*[Media, [xSize: 216, ySize: 279, formType: defaultMedium, color: white, weight: 75]]
-- SetAttr*[Media, [xSize: 216, ySize: 279, formType: defaultMedium, color: white, weight: 75]]
-- IPAttr*[ImageShift, [w: 6, h: 0]]
-- SetAttr*[ImageShift, [w: 6, h: 0]]
-- IPAttr*[Staple, FALSE]
-- SetAttr*[Staple, FALSE]
3. Maintenance and Evolution
Keeping track
Any IPAttributes implementation must track the Attributes known to the particular decomposer environment in which it will be called. In particular, the attribute registrations in the Start Code of both AttributeTranslationImpl and any IPAttributes implementation should match to the extent that a translatable attribute, such as Staple, found in AttributeTranslationImpl is satisfied by an IP attribute, such as Finishing, found in the instructions vector.
Current State
The current IPAttributes implementations know about:
Attribute   corresponding IP3.0 extended Instruction(s)
SenderName   docCreator
RecipientName   docCreator
DocumentName   docName
Priority    jobPriority
Plex    plex
Staple    finishing
ImageShift   xImageShift, yImageShift
AccountInfo   jobAccountName
Media    [mediumXSize, mediumYSize, mediumName, color,
    weight]
This list will grow as the Decomposer and Sequencer implementations evolve. To add an attribute, it must be registered in the IP attributes table maintained by an IPAttributes implementation. See either IPAttributeImpl or IPAttributeImpl2 for details