Previous Next
1060
APPENDIX G Example PDF Files
G.2 Simple Text String Example
Example G.2 is the classic “Hello World” example built from the preceding exam-
ple. It shows a single line of text consisting of the string Hello World, illustrating
the use of fonts and several text-related PDF operators. The string is displayed in
24-point Helvetica. Because Helvetica is one of the standard 14 fonts, no font
descriptor is needed.
Table G.2 lists the objects in this example.
TABLE G.2 Objects in simple text string example
OBJECT NUMBER OBJECT TYPE
1 Catalog (document catalog)
2 Outlines (outline dictionary)
3 Pages (page tree node)
4 Page (page object)
5 Content stream
6 Procedure set array
7 Font (Type 1 font)
Example G.2
%PDF−1. 4
1 0 obj
<< /Type /Catalog
/Outlines 2 0 R
/Pages 3 0 R
>>
endobj
2 0 obj
<< /Type /Outlines
/Count 0
>>
endobj
Previous Next