1POD2PDF(1) User Contributed Perl Documentation POD2PDF(1)
2
3
4
6 pod2pdf - converts Pod to PDF format
7
9 pod2pdf converts documents written in Perl's POD (Plain Old
10 Documentation) format to PDF files.
11
12 Usage
13 pod2pdf [options] input.pod >output.pdf
14
15 If no input filename is specified, pod2pdf will read from STDIN, e.g.
16
17 perldoc -u File::Find | pod2pdf [options] >File-Find.pdf
18
19 Options
20 pod2pdf accepts the following command-line options:
21
22 "--output-file"
23 Sets the output filename for the generated PDF file. By default
24 pod2pdf will output to STDOUT.
25
26 "--page-size"
27 Sets the page size to be used in the PDF file, can be set to any of
28 the standard paper sizes (A4, A5, Letter, etc). Defaults to A4.
29
30 "--page-orientation"
31 Controls if pages are produces in landscape or portrait format.
32 Defaults to 'portrait'.
33
34 "--page-width", "--page-height"
35 Sets the width and height of the generated pages in points (for
36 using non-standard paper sizes).
37
38 "--left-margin", "--right-margin", "--top-margin", "--bottom-margin"
39 Allows each of the page margins (top, bottom, left, and right) to
40 be individually set in points.
41
42 "--margins"
43 Sets all page margins to the same size (specified in points).
44
45 "--header", "--noheader"
46 Controls if a header (containing the page title, and optional
47 timestamp and icon) will be included on each page. Defaults to on,
48 so use "--noheader" to disable.
49
50 "--title"
51 Sets the page title (defaults to the input filename).
52
53 "--timestamp"
54 Boolean option - if set, includes the 'last modified' timestamp of
55 the input file in the page header.
56
57 "--icon"
58 Filename of an icon to be displayed in the top left corner of each
59 page.
60
61 "--icon-scale"
62 Scaling value for the header icon (defaults to 0.25).
63
64 "--footer", "--nofooter"
65 Controls if a footer (containg the current page number and optional
66 text string) will be included on each page. By default the footer
67 will be included, so use "--nofooter" to disable.
68
69 "--footer-text"
70 Sets an optional footer text string that will be included in the
71 bottom left corner of each page.
72
73 "--version"
74 Prints version number and exits.
75
76 Configuration files
77 Sets of command-line options may be saved into configuration files.
78
79 A configuration file contains options in the same format as used by
80 pod2pdf on the command-line, with one option given on each line of the
81 file, e.g.
82
83 --page-size A5
84 --page-orientation landscape
85
86 To use a config file, invoke pod2pdf with the option
87 "@/path/to/configfile.conf".
88
89 For example, if you wanted to always include a company logo, timestamp,
90 and copyright notice in your PDF files, create a file mycompany.conf
91 containing the following:
92
93 --icon "/path/to/your/logo.png"
94 --footer-text "Copyright 2007 MyCompany Limited"
95 --timestamp
96
97 Then invoke pod2pdf as:
98
99 pod2pdf @/path/to/mycompany.conf input.pod >output.pdf
100
101 If you create a config file called pod2pdf.conf and place this in the
102 same directory as the pod2pdf script, it will be loaded as the default
103 configuration.
104
106 As well as the standard POD commands (see perlpodspec), pod2pdf
107 supports the following extensions to the POD format:
108
109 "=ff"
110 The "=ff" command inserts a page bread (form feed) into the
111 document.
112
113 "O<...>"
114 The "O<...>" formatting code inserts an external object (file) into
115 the document. This is primarily intended for embedding images, e.g.
116
117 O</path/to/figure1.jpg>
118
119 to insert diagrams, etc into documentation.
120
121 pod2pdf supports the file types JPG, GIF, TIFF, PNG, and PNM for
122 embedded objects.
123
125 pod2pdf requires the following modules to be installed:
126
127 PDF::API2
128 Pod::Escapes
129 Getopt::ArgvFile
130
131 Additionally to use images, the modules File::Type and Image::Size must
132 be installed, and to specify alternative page sizes the Paper::Specs
133 module is required.
134
136 The pod2pdf homepage: <http://perl.jonallen.info/projects/pod2pdf>
137
138 For more information about POD, read the perlpod manpage or see the POD
139 page on the Perl 5 Wiki
140 (<http://www.perlfoundation.org/perl5/index.cgi?pod>).
141
143 Copyright (C) 2007 Jon Allen (JJ) <jj@jonallen.info>
144
145 This software is licensed under the terms of the Artistic License
146 version 2.0.
147
148 For full license details, please read the file artistic-2_0.txt
149 included with this distribution, or see
150 <http://www.perlfoundation.org/legal/licenses/artistic-2_0.html>.
151
152
153
154perl v5.34.0 2022-01-21 POD2PDF(1)