TGML Document Type Element and Metadata
Each TGML document contains the TGML root element. It also contains metadata created and interpreted by the TGML application.
Document Type Element
The root element of a TGML document is <TGML>. This element specifies that the document type is TGML.
Attribute | Type | Description |
---|---|---|
Background |
Brush |
The background color of the document canvas (the viewing area). |
DisablePanAndZoom |
Boolean |
Disables the normal zoom and pan commands in the viewer. For example useful in kiosk mode or headers/footers. |
Height |
Double |
The height of the document. See Remarks. |
Stretch |
Stretch |
Specifies how the document shall be stretched initially within a viewer. See Remarks. |
UseGlobalScripts |
Boolean |
Enable a single execution context for scripts. For more information, see the TGML Script Context section. |
Width |
Double |
The width of the document. See Remarks. |
Remarks
The viewer uses the width, height, and stretch information to determine how the document initially is stretched.
The viewer can display a document where information about width and height is missing. When you view such a document no stretching is applied and any scroll bars are disabled.
Stretch="None": Preserve the original size. This usually means that scroll bars are enabled so the user can scroll to the right and the bottom of the document.
Stretch="Uniform": Resize the content, preserving the natural aspect ratio. Scroll bars are initially disabled.
Stretch="Fill": The content is resized but aspect ratio is not preserved. Scroll bars are initially disabled.
Metadata
The <Metadata> element carries textual information about its parent element. It is up to the TGML application to create and interpret the metadata.
Applying metadata to the outermost TGML element is the same as applying the information to the TGML document.
Attribute | Type | Description |
---|---|---|
Name |
String |
A name that identifies the information. |
Value |
String |
The information. |