Document Structure

An SPDL document may represent either a single page or a set of pages. The primary structure elements from which an SPDL document is constructed are the PICTURE and PAGESET structure elements.

A PICTURE describes an image which can be considered as a single entity. It may be a page image or a partial page image. A PAGESET describes one or more pages.

There are two additional semantically distinct structure elements which are important to the SPDL document structure.

These structure elements are not syntactically distinct from the PICTURE and PAGESET structure elements, but are distinguished by their position in the hierarchical structure.

Each PAGESET or PICTURE is a BLOCK and has an associated Block State as defined in . Each PAGESET or PICTURE is either a DOCUMENT or the subordinate of a superior BLOCK.

DOCUMENT

A DOCUMENT structure element shall be one of:

which is not subordinate to any other structure element.

The processing of a DOCUMENT shall consist of:

  1. resetting the mechanism for the presentation of the completed document;
  2. initializing the presentation parameters;
  3. if the DOCUMENT is a PAGESET, processing it as specified in ;
  4. if the DOCUMENT is a PAGE, processing it as specified in ;
  5. performing any finishing processes on the document;
  6. presenting the completed document.

PAGESET

A PAGESET structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order.

PAGESET Processing

The processing of a PAGESET shall consist of:

  1. creating a Block State for the PAGESET as specified in ;
  2. processing the immediately subordinate PROLOGUE if present;
  3. processing each of the immediately subordinate PAGESET and PAGE structure elements in their sequential order;
  4. destroying the Block State for the PAGESET.

If the PAGESET has no subordinate PAGE structure elements, no page image shall be rendered as a result of processing the PAGESET.

PAGE

A PAGE structure element shall be a PICTURE which is not subordinate to any other PICTURE structure element.

The processing of a PAGE structure element shall consist of:

  1. establishing a Current Page Image associated with the PAGE whose initial value is a blank page image as specified in ;
  2. processing the PICTURE structure element as specified in ;
  3. rendering the Current Page Image associated with the PAGE on an instance of the medium.

The rendering of the Current Page Image associated with the PAGE on an instance of the medium is specified in .

PICTURE

A PICTURE structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order.

A PICTURE which has an immediately subordinate PICTURE BODY shall be called an SPDL PICTURE. A PICTURE which has an immediately subordinate NON-SPDL PICTURE BODY shall be called a NON-SPDL PICTURE.

CONTENT REPRESENTATION IDENTIFIER

A CONTENT REPRESENTATION IDENTIFIER shall be a base structure element. The value of a CONTENT REPRESENTATION IDENTIFIER shall be of type Public Object Identifier.

The Object Names for which Public Object Identifiers are defined by this International Standard and the meaning of those values shall be as shown in . Object Namemeaning Content::SPDL-Binarythe PICTURE has an immediately subordinate PICTURE BODY for which the content of each immediately subordinate TOKENSEQUENCE is an instance of the SPDL content notation in the Binary Content Representation and Interchange Format; Content::SPDL-ClearTextthe PICTURE has an immediately subordinate PICTURE BODY for which the content of each immediately subordinate TOKENSEQUENCE is an instance of the SPDL content notation in the Clear Text Content Representation and Interchange Format;

Any other value of the CONTENT REPRESENTATION IDENTIFIER specifies that the PICTURE has an immediately subordinate NON-SPDL PICTURE BODY structure element and identifies the format of the NON-SPDL PICTURE BODY structure element.

PICTURE BODY

A PICTURE BODY structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order. The TOKENSEQUENCE structure element is defined in .

NON-SPDL PICTURE BODY

The NON-SPDL PICTURE BODY structure element is outside of the scope of this International Standard. The structure of a NON-SPDL PICTURE BODY is identified by the value of the CONTENT REPRESENTATION IDENTIFIER of the most immediately superior PICTURE, and is defined by owner of that Public Object Identifier.

SPDL PICTURE Processing

The processing of an SPDL PICTURE shall consist of:

  1. creating a Block State for the PICTURE as specified in ;
  2. processing the immediately subordinate PROLOGUE if present;
  3. processing each of the PICTURE or TOKENSEQUENCE structure elements which is immediately subordinate to the subordinate PICTURE BODY in their sequential order;
  4. destroying the Block State for the PICTURE.

The processing of each TOKENSEQUENCE structure element which is immediately subordinate to the subordinate PICTURE BODY shall consist of

  1. Calling the Content Processor with:
    • a content value which is the value of the TOKENSEQUENCE;
    • a Context of Interpretation which is obtained from the Block State of the most immediately superior PICTURE as specified in ;
    • the Current Page Image of the most immediately superior PAGE;
  2. Upon completion of content processing,
    • replacing the Current Virtual Machine State of the Block State of the most immediately superior PICTURE with the Virtual Machine State returned by the Content Processor;
    • replacing the Current Page Image of the most immediately superior PAGE with the Current Page Image returned by the Content Processor.

NON-SPDL PICTURE Processing

The processing of a NON-SPDL PICTURE depends on whether the Structure Processor is able to recognize the value of the CONTENT REPRESENTATION IDENTIFIER and to process the NON-SPDL PICTURE BODY as specified by that value. The processing of a NON-SPDL PICTURE shall consist of one of:

PROLOGUE

A PROLOGUE structure element and all of the subordinates of a PROLOGUE structure element shall be called Prologue Structure Elements. A PROLOGUE structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order.

The processing of a PROLOGUE structure element shall consist of

  1. processing each of the immediately subordinate structure elements in their order of occurrence;
  2. at the end of the processing of the immediately subordinate structure elements, setting the Inheritable Context Stack of the Block State of the most immediately superior BLOCK to a copy of the Context Stack of the Current Virtual Machine State of that Block State.

INFORMATIVE DECLARATION

An INFORMATIVE DECLARATION structure element provides information about the BLOCK in the form of hints. A hint is information which is not required to be accurate or complete, but which may still be useful. An example of a hint is a list of fonts or other resources required for the presentation of the document.

An INFORMATIVE DECLARATION structure element shall be a composite structure element which shall have the following immediate subordinates:

HINT

A HINT structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order.

HINT NAME

A HINT NAME structure element shall be a base structure element. The value of a HINT NAME structure element shall be of type Environment Identifier.

HINT VALUE

A HINT VALUE structure element may be a base structure element or a composite structure element, depending on the value of the peer HINT NAME.

If the HINT VALUE is a base structure element, the type of the value shall depend on the value of the peer HINT NAME. If the HINT VALUE is a composite structure element, the immediate subordinates shall depend on the value of the peer HINT NAME.

INFORMATIVE DECLARATION Processing

An INFORMATIVE DECLARATION structure element shall have no effect on document presentation.

Hints

The following HINT structure elements are defined by this International Standard.

Bounding Box

This HINT identifies the size of the smallest bounding box which will contain all of the images specified by the content of the PAGESET or PICTURE, in the units of the User Coordinate System in effect when the PAGESET or PICTURE is used.

HINT NAME

The value of the subordinate HINT NAME structure element shall be the Public Object Identifier corresponding to the Object Name Hints::BoundingBox.

HINT VALUE

The subordinate HINT VALUE structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order.

MINIMUM X

A MINIMUM X structure element shall be a base structure element. The value of a MINIMUM X structure element shall be of type Number.

MINIMUM Y

A MINIMUM Y structure element shall be a base structure element. The value of a MINIMUM Y structure element shall be of type Number.

MAXIMUM X

A MAXIMUM X structure element shall be a base structure element. The value of a MAXIMUM X structure element shall be of type Number.

MAXIMUM Y

A MAXIMUM Y structure element shall be a base structure element. The value of a MAXIMUM Y structure element shall be of type Number.

Number of Pages

This HINT identifies the number of PAGE structure elements in a PAGESET.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::NumberOfPages.

HINT VALUE

The subordinate HINT VALUE structure element shall be a base structure element. The value of the subordinate HINT VALUE structure element shall be of type Cardinal.

Orientation

This HINT identifies orientation of the image generated by a PICTURE or the page images generated by a PAGESET.

HINT NAME

The value of the subordinate HINT NAME structure element shall be the Public Object Identifier corresponding to the Object Name Hints::Orientation.

HINT VALUE

The subordinate HINT VALUE structure element shall be a base. structure element. The type of the value of the subordinate HINT VALUE structure element shall be an Enumerated type which identifies an orientation. The values of this type and the orientations identified shall be as shown in . ValueOrientation portraitportrait (shorter dimension parallel to the x-axis); landscapelandscape (longer dimension parallel to the x-axis);

Font References

This HINT identifies the Font References included in FONT REFERENCE FONT SPECIFICATION structure elements in the immediately superior BLOCK or in subordinate BLOCKs.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::FontReferences.

HINT VALUE

The subordinate HINT VALUE shall be a composite structure element which shall have the following immediate subordinates:

External References

This HINT identifies the structure elements included by reference in the immediately superior BLOCK or in subordinate BLOCKs.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::ExternalReferences.

HINT VALUE

The subordinate HINT VALUE shall be a composite structure element which shall have the following immediate subordinates:

Resources Used

This HINT identifies the resources declared in RESOURCE DECLARATION or RESOURCE DEFINITION structure elements in the immediately superior BLOCK or in subordinate BLOCKs.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::ResourcesUsed.

HINT VALUE

The subordinate HINT VALUE shall be a composite structure element which shall have the following immediate subordinates:

Color Space Families Used

This HINT identifies the color space families of color space resources used or COLOR SPACE SPECIFICATIONs in the immediately superior BLOCK or in subordinate BLOCKs.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::ColorSpaceFamiliesUsed.

HINT VALUE

The subordinate HINT VALUE shall be a composite structure element which shall have the following immediate subordinates:

Media Used

This HINT identifies the media declared in MEDIUM DECLARATION structure elements in the immediately superior BLOCK or in subordinate BLOCKs.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::MediaUsed.

HINT VALUE

The subordinate HINT VALUE shall be a composite structure element which shall have the following immediate subordinates:

Colorant Sets Used

This HINT identifies the colorant sets identified in COLORANT SET DPI structure elements in the immediately superior BLOCK or in subordinate BLOCKs.

HINT NAME

The value of the subordinate HINT NAME shall be the Public Object Identifier corresponding to the Object Name Hints::ColorantSetsUsed.

HINT VALUE

The subordinate HINT VALUE shall be a composite structure element which shall have the following immediate subordinates:

NON-SPDL OPERATION

A NON-SPDL OPERATION structure element may be used to specify an operation which may be performed by processes other than SPDL Presentation Processes which process or present SPDL documents. Operations which may be specified by NON-SPDL OPERATION structure elements are outside of the scope of this International Standard. A NON-SPDL OPERATION structure element has no effect on document presentation by an SPDL Presentation Process.

A NON-SPDL OPERATION structure element shall be a composite structure element which shall have the following immediate subordinates:

The immediate subordinates shall occur in the above order.

OPERATION NAME

An OPERATION NAME structure element shall be a base structure element. The value of a OPERATION NAME shall be of type Environment Identifier.

OPERATION VALUE

An OPERATION VALUE structure element may be a base structure element or a composite structure element, depending on the value of the peer OPERATION NAME. If the OPERATION VALUE is a base structure element, the type of the value shall depend on the value of the peer OPERATION NAME. If the OPERATION VALUE is a composite structure element, the immediate subordinates shall depend on the value of the peer OPERATION NAME.

NON-SPDL OPERATION Processing

The specification of the semantics of an NON-SPDL OPERATION and of the syntax of the OPERATION VALUE corresponding to any particular OPERATION NAME value shall be the responsibility of the owner of the Public Object Identifier which is the value of the OPERATION NAME.

A NON-SPDL OPERATION structure element shall have no effect on document presentation by an SPDL Presentation Process. The effect of NON-SPDL OPERATION on the presentation of SPDL documents by processes other than an SPDL Presentation Process is outside of the scope of this International Standard. NON-SPDL OPERATION structure elements may affect the presentation of SPDL documents by presentation processes other than SPDL Presentation Processes.

CONTEXT DECLARATION

A CONTEXT DECLARATION structure element shall be a composite structure element which shall have the following immediate subordinates:

The INTERNAL RESOURCE IDENTIFIER structure element is defined in .

CONTEXT DECLARATION Processing

If the CONTEXT DECLARATION consists of n INTERNAL RESOURCE IDENTIFIER structure elements whose values are name1 . . . . namen, if for each i, 1≤in,

and if SystemDictRef and UserDictRef are DictionaryReferences which reference the Context Dictionaries defined in , then the processing of the CONTEXT DECLARATION shall consist of replacing the Context Stack of the Block State of the most immediately superior BLOCK with the Context Stack consisting of (using the notation of ):

  • <DictRefn: DictionaryReference>
  • . . .
  • <DictRef1: DictionaryReference>
  • <UserDictRef: DictionaryReference>
  • <SystemDictRef: DictionaryReference>

    A structure error shall occur if any of the values name1 . . . . namen has not been bound to a Context Dictionary in the context of the CONTEXT DECLARATION.

    If the CONTEXT DECLARATION has no subordinate INTERNAL RESOURCE IDENTIFIER structure elements, the processing of the CONTEXT DECLARATION shall consist of replacing the Context Stack of the Block State of the most immediately superior BLOCK with the Context Stack consisting of:

  • <UserDictRef: DictionaryReference>
  • <SystemDictRef: DictionaryReference>

    CONTEXT ADDITION

    A CONTEXT ADDITION structure element shall be a composite structure element which shall have the following immediate subordinates:

    • one INTERNAL RESOURCE IDENTIFIER structure element.

    The INTERNAL RESOURCE IDENTIFIER structure element is defined in .

    CONTEXT ADDITION Processing

    The processing of a CONTEXT ADDITION shall consist of pushing the DictionaryReference which is bound to the value of the subordinate INTERNAL RESOURCE IDENTIFIER on the Context Stack of the Block State of the most immediately superior BLOCK.

    A structure error shall occur if the value of the INTERNAL RESOURCE IDENTIFIER has not been bound to a Context Dictionary in the context of the CONTEXT ADDITION.

    SETUP PROCEDURE

    A SETUP PROCEDURE shall be a composite structure element which shall have the following immediate subordinates:

    • one or more TOKENSEQUENCE structure elements.

    SETUP PROCEDURE Processing

    The processing of a SETUP PROCEDURE shall consist of:

    1. Calling the Content Processor with:
      • a content value which is obtained by concatenating the values of the TOKENSEQUENCE structure elements which are immediately subordinate to the SETUP PROCEDURE;
      • a Context of Interpretation which is obtained from the Block State of the most immediately superior BLOCK as specified in .
    2. Upon completion of content processing, replacing the
      • Graphics State Stack;
      • Current Graphics State;
      • ordered set of Save Objects;
      • set of referenced objects;
      • set of state variables;
      of the Block State of the most immediately superior BLOCK with the corresponding elements of the Virtual Machine State returned by the Content Processor. A structure error or warning shall occur if the status returned by the Content Processor is other than OK.

    No changes are made to the Context Stack or Operand Stack of the Block State of the most immediately superior BLOCK or to the Current Page Image as a result of the processing of a SETUP PROCEDURE. A SETUP PROCEDURE in the PROLOGUE of a PAGESET can set up the Current Graphics State, the set of referenced objects, and the set of state variables of the Initial Block State for TOKENSEQUENCE and PAGE structure elements immediately subordinate to that PAGESET.