docs/userguide/ch3_pdffeatures.py
author rgbecker
Wed, 25 Oct 2000 08:57:46 +0000
changeset 494 54257447cfe9
parent 406 0444ca32fb1b
child 1128 bc5ca3b9a13b
permissions -rw-r--r--
Changed to indirect copyright
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
494
54257447cfe9 Changed to indirect copyright
rgbecker
parents: 406
diff changeset
     1
#copyright ReportLab Inc. 2000
54257447cfe9 Changed to indirect copyright
rgbecker
parents: 406
diff changeset
     2
#see license.txt for license details
54257447cfe9 Changed to indirect copyright
rgbecker
parents: 406
diff changeset
     3
#history http://cvs.sourceforge.net/cgi-bin/cvsweb.cgi/docs/userguide/ch3_pdffeatures.py?cvsroot=reportlab
54257447cfe9 Changed to indirect copyright
rgbecker
parents: 406
diff changeset
     4
#$Header: /tmp/reportlab/docs/userguide/ch3_pdffeatures.py,v 1.7 2000/10/25 08:57:45 rgbecker Exp $
341
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
     5
from genuserguide import *
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
     6
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
     7
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
     8
heading1("Exposing PDF Special Capabilities")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
     9
disc("""PDF provides a number of features to make electronic
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    10
    document viewing more efficient and comfortable, and
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    11
    our library exposes a number of these.""")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    12
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    13
heading2("Forms")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    14
disc("""The Form feature lets you create a block of graphics and text
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    15
    once near the start of a PDF file, and then simply refer to it on
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    16
    subsequent pages.  If you are dealing with a run of 5000 repetitive
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    17
    business forms - for example, one-page invoices or payslips - you
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    18
    only need to store the backdrop once and simply draw the changing
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    19
    text on each page.  Used correctly, forms can dramatically cut
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    20
    file size and production time, and apparently even speed things
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    21
    up on the printer.
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    22
    """)
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    23
disc("""Forms do not need to refer to a whole page; anything which
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    24
    might be repeated often should be placed in a form.""")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    25
disc("""The example below shows the basic sequence used.  A real
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    26
    program would probably define the forms up front and refer to
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    27
    them from another location.""")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    28
    
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    29
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    30
eg(examples.testforms)
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    31
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    32
heading2("Links and Destinations")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    33
disc("""PDF supports internal hyperlinks.  There is a very wide
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    34
    range of link types, destination types and events which
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    35
    can be triggered by a click.  At the moment we just
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
    36
    support the basic ability to jump from one part of a document
366
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    37
    to another.  The bookmark methods define a destination that is the endpoint
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    38
    of a jump.""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    39
#todo("code example here...")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    40
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    41
eg("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    42
 canvas.bookmarkPage(name)
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    43
 canvas.bookmarkHorizontalAbsolute(name, yhorizontal)""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    44
 
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    45
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    46
    The $bookmarkPage$ method bookmarks the entire page.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    47
    After jumping to an endpoint defined by $bookmarkPage$ the
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    48
    PDF browser will display the whole page on the screen.""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    49
    
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    50
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    51
    By contrast, $bookmarkHorizontalAbsolute$ defines a destination
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    52
    associated with a horizontal position on a page.  When the PDF browser
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    53
    jumps to a destination defined by $bookmarkHorizontalAbsolute$ the
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    54
    screen will show a part of the page with the horizontal line at
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    55
    ^y=$yhorizontal$^ near the top, omitting parts of the rest of the page
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    56
    if appropriate.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    57
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    58
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    59
pencilnote()
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    60
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    61
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    62
<i>Note:</i> The horizontal position $yhorizontal$ must be specified in terms
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    63
of the <i>default user space</i>.  In particular $bookmarkHorizontalAbsolute$
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    64
ignores any modified geometric transform in effect in the canvas graphics state.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    65
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    66
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    67
eg("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    68
 canvas.linkAbsolute(contents, destinationname, Rect=None, addtopage=1, name=None, **kw)
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    69
 """)
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    70
 
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    71
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    72
    The $linkAbsolute$ method defines a starting point for a jump.  When the user
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    73
    is browsing the generated document using a dynamic viewer (such as Acrobat Reader)
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    74
    when the mouse is clicked when the pointer is within the rectangle specified
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    75
    by $Rect$ the viewer will jump to the endpoint associated with $destinationname$.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    76
    As in the case with $bookmarkHorizontalAbsolute$ the rectangle $Rect$ must be
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    77
    specified in terms of the default user space.  The $contents$ parameter specifies
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    78
    a chunk of text which displays in the viewer if the user left-clicks on the region.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    79
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    80
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    81
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    82
The rectangle $Rect$ must be specified in terms of a tuple ^(x1,y1,x2,y2)^ identifying
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    83
the lower left and upper right points of the rectangle in default user space.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    84
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    85
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    86
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    87
For example the code
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    88
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    89
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    90
eg("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    91
    canvas.bookmarkHorizontalAbsolute("Meaning_of_life", 5*inch)
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    92
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    93
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    94
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    95
defines horizontal location on the currently drawn page with the identifier
397
d2e12adb2496 fixed typos.
dinu_gherman
parents: 376
diff changeset
    96
$Meaning_of_life$.  And the invocation (???)
366
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    97
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    98
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
    99
eg("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   100
 canvas.linkAbsolute("Find the Meaning of Life", "Meaning_of_life", 
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   101
                     (inch, inch, 6*inch, 2*inch))
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   102
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   103
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   104
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   105
By default during interactive viewing a rectangle appears around the
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   106
link.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   107
Use the keyword argument $Border='[0 0 0]'$ to
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   108
suppress the visible rectangle around the during viewing link.
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   109
For example
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   110
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   111
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   112
eg("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   113
 canvas.linkAbsolute("Meaning of Life", "Meaning_of_life", 
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   114
                     (inch, inch, 6*inch, 2*inch), Border='[0 0 0]')
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   115
""")
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   116
341
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   117
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   118
heading2("Outline Trees")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   119
disc("""Acrobat Reader has a navigation page which can hold a
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   120
    document outline; it should normally be visible when you
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   121
    open this guide.  We provide some simple methods to add
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   122
    outline entries.  Typically, a program to make a document
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   123
    (such as this user guide) will call the method
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   124
    $canvas.addOutlineEntry(^self, title, key, level=0,
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   125
    closed=None^)$ as it reaches each heading in the document.
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   126
    """)
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   127
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   128
disc("""^title^ is the caption which will be displayed in
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   129
    the left pane.  The ^key^ must be a string which is
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   130
    unique within the document and which names a bookmark,
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   131
    as with the hyperlinks.  The ^level^ is zero - the
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   132
    uppermost level - unless otherwise specified, and
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   133
    it is an error to go down more than one level at a time
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   134
    (for example to follow a level 0 heading by a level 2
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   135
     heading).  Finally, the ^closed^ argument specifies
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   136
    whether the node in the outline pane is closed
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   137
    or opened by default.""")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   138
    
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   139
disc("""The snippet below is taken from the document template
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   140
    that formats this user guide.  A central processor looks
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   141
    at each paragraph in turn, and makes a new outline entry
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   142
    when a new chapter occurs, taking the chapter heading text
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   143
    as the caption text.  The key is obtained from the
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   144
    chapter number (not shown here), so Chapter 2 has the
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   145
    key 'ch2'.  The bookmark to which the
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   146
    outline entry points aims at the whole page, but it could
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   147
    as easily have been an individual paragraph.
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   148
    """)
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   149
    
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   150
eg("""
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   151
#abridged code from our document template
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   152
if paragraph.style == 'Heading1':
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   153
    self.chapter = paragraph.getPlainText()
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   154
    key = 'ch%d' % self.chapterNo
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   155
    self.canv.bookmarkPage(key)
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   156
    self.canv.addOutlineEntry(paragraph.getPlainText(),
366
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   157
                                            key, 0, 0)
341
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   158
    """)
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   159
    
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   160
heading2("Page Transition Effects")
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   161
27c68d524504 Broke up the user guide into chapters.
andy_robinson
parents:
diff changeset
   162
366
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   163
eg("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   164
 canvas.setPageTransition(self, effectname=None, duration=1, 
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   165
                        direction=0,dimension='H',motion='I')
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   166
                        """)
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   167
                        
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   168
disc("""
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   169
The $setPageTransition$ method specifies how one page will be replaced with
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   170
the next.  By setting the page transition effect to "dissolve" for example
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   171
the current page will appear to melt away when it is replaced by the next
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   172
page during interactive viewing.  These effects are useful in spicing up
406
0444ca32fb1b Bruce Eckel spotted these typos.
rgbecker
parents: 397
diff changeset
   173
slide presentations, among other places.
366
a2b902ff8420 various expansions
aaron_watters
parents: 341
diff changeset
   174
Please see the reference manual for more detail on how to use this method.
374
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   175
""")
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   176
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   177
heading2("Internal File Annotations")
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   178
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   179
eg("""
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   180
 canvas.setAuthor(name)
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   181
 canvas.setTitle(title)
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   182
 canvas.setSubject(subj)
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   183
 """)
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   184
 
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   185
disc("""
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   186
These methods have no automatically seen visible effect on the document.
397
d2e12adb2496 fixed typos.
dinu_gherman
parents: 376
diff changeset
   187
They add internal annotations to the document.  These annotations can be
376
44b5c5b86985 filled in some blanks
aaron_watters
parents: 374
diff changeset
   188
viewed using the "Document Info" menu item of the browser and they also can
44b5c5b86985 filled in some blanks
aaron_watters
parents: 374
diff changeset
   189
be used as a simple standard way of providing basic information about the
44b5c5b86985 filled in some blanks
aaron_watters
parents: 374
diff changeset
   190
document to archiving software which need not parse the entire
44b5c5b86985 filled in some blanks
aaron_watters
parents: 374
diff changeset
   191
file.  To find the annotations view the $*.pdf$ output file using a standard
44b5c5b86985 filled in some blanks
aaron_watters
parents: 374
diff changeset
   192
text editor (such as $notepad$ on MS/Windows or $vi$ or $emacs$ on unix) and look
44b5c5b86985 filled in some blanks
aaron_watters
parents: 374
diff changeset
   193
for the string $/Author$ in the file contents.
374
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   194
""")
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   195
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   196
eg(examples.testannotations)
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   197
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   198
disc("""
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   199
If you want the subject, title, and author to automatically display
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   200
in the document when viewed and printed you must paint them onto the
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   201
document like any other text.
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   202
""")
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   203
1342601fdc4a minor edits, filled in some blanks
aaron_watters
parents: 366
diff changeset
   204
illust(examples.annotations, "Setting document internal annotations")
406
0444ca32fb1b Bruce Eckel spotted these typos.
rgbecker
parents: 397
diff changeset
   205