1Pbmtextps User Manual(0)                              Pbmtextps User Manual(0)
2
3
4

NAME

6       pbmtextps - render text into a PBM image using a postscript interpreter
7
8

SYNOPSIS

10       pbmtextps [-font fontname] [-fontsize float] [-resolution n] [-leftmar‐
11       gin=n] [-rightmargin=n]  [-topmargin=n]  [-bottommargin=n]  [-ascent=n]
12       [-descent=n] [-pad] [-crop] [-stroke n] [-verbose] [-dump-ps] text
13
14

DESCRIPTION

16       This program is part of Netpbm(1).
17
18       pbmtextps takes a single line of text from the command line and renders
19       it into a PBM image.  The image is of a single line  of  text;  newline
20       characters in the input have no effect.
21
22       See  pbmtext for a more sophisticated generator of text, but using less
23       common font formats.  pbmtext can generate multiple lines of text.
24
25       The -plain common option  ⟨index.html#commonoptions⟩    has  no  effect
26       before Netpbm 10.42 (March 2008).  The output is always raw PBM.
27
28
29   Margins
30       By  default,  the image is cropped at the top and the right.  It is not
31       cropped at the left or bottom so that the text begins at the same posi‐
32       tion  relative  to the origin.  The size of the default left and bottom
33       margins is explained below.
34
35       You can set whatever margin you want with options -leftmargin,  -right‐
36       margin,  -topmargin  and  -bottommargin.  The specified amount of white
37       space gets added to the far edge of type, e.g. if you specify 10 points
38       for -topmargin, you will get 10 points of white space above the highest
39       character on the line.  Specify 0 to crop a side.
40
41       -ascent adds white space to the top to reach a specified distance above
42       the  text  baseline,  and -descent adds white space to to the bottom to
43       reach a specified distance below the text baseline.
44
45       -ascent and -descent are more useful than -topmargin  and  -bottomargin
46       when  you  render  two  pieces of text (in separate invocations of pbm‐
47       textps) that you  will  concatenate  horizontally.   With  -ascent  and
48       -descent, the two images will be the same height with the text baseline
49       in the same place.  With -topmargin and -bottommargin, that may not  be
50       the case.
51
52       Example:
53
54            $ pbmtextps -font=Times-Roman -descent=20 \
55                 'The soup is called' > a1.pbm
56            $ pbmtextps -font=Itallic -descent=20 'Goulash.' > a2.pbm
57            $ pnmcat -lr -jb a1.pbm a2.pbm > out.pbm
58
59       If  you have -ascent, there is probably no point in specifying -topmar‐
60       gin too, but if you do, the effect is cumulative.  The same is true  of
61       -descent and -bottommargin.
62
63       -pad  pads the image on the top and bottom to the where the highest and
64       lowest characters in the font would reach, even if you don't have those
65       characters  in your text.  This is useful if you will generate multiple
66       images of text (with multiple invocations of pbmtextps) and concatenate
67       them  vertically to create a multiline text image.  -pad makes sure the
68       lines in this image are equally spaced.
69
70       Example:
71
72           $ pbmtextps 'cat'   | pamfile
73           $ pbmtextps 'Catty' | pamfile
74
75       The commands above, with no -pad, show that the 'Catty' image is higher
76       because capital C reaches high and 'y' reaches low.
77
78           $ pbmtextps -pad 'cat'   | pamfile
79           $ pbmtextps -pad 'Catty' | pamfile
80
81       The  commands  above,  with  -pad,  show  that both images are the same
82       height.
83
84       If you specify -pad with -ascent  or  -descent,  the  larger  value  is
85       effective.
86
87       -crop makes the program crop all sides to the far edge of the type.  It
88       is the same as -leftmargin=0  -rightmargin=0  -topmargin=0  -bottommar‐
89       gin=0.
90
91       You cannot specify any other margin-affecting options with -crop.
92
93       The  default  top margin, when you specify neither -ascent, -topmargin,
94       nor -pad, is as if you specified topmargin=0.
95
96       The default bottom margin, when you specify neither -descent,  -bottom‐
97       margin, nor -pad, is as if you specified -descent=1.5*fontsize.
98
99       The  default left margin, when you do not specify -leftmargin, is as if
100       you specified -leftmargin=0.5*fontsize.
101
102       The default right margin, when you do not specify -rightmargin,  is  as
103       if you specified -rightmargin=0.
104
105
106

OPTIONS

108       In  addition  to  the options common to all programs based on libnetpbm
109       (most notably -quiet, see
110        Common Options ⟨index.html#commonoptions⟩ ), pbmtextps recognizes  the
111       following command line options:
112
113
114
115       -font=fontname
116
117              This  specifies  the  font  to use.  fontname is the name of any
118              valid postscript font which is installed on the system.
119
120              The default is TimesRoman.
121
122              Warning: if fontname does not name a valid font, pbmtextps  just
123              uses the default font.  It does not tell you it is doing this.
124
125
126       -fontsize=float
127              This  is  the  size  of the font in points.  See the -resolution
128              option for information on how to interpret this size.
129
130              The default is 24 points.
131
132              Before Netpbm 10.75 (June 2016), this has to be a whole number.
133
134
135       -resolution=n
136              This is the resolution in dots per inch of distance measurements
137              pertaining  to  generation  of the image.  PBM images don't have
138              any inherent resolution, so a distance such as "1 inch"  doesn't
139              mean  anything  unless  you  separately  specify what resolution
140              you're talking about.  That's what this option does.
141
142              In particular, the meaning of the font  size  is  determined  by
143              this  resolution.  If the font size is 24 points and the resolu‐
144              tion is 150 dpi, then the font size is 50 pixels.
145
146              The default is 150 dpi.
147
148
149       -leftmargin=n
150
151       -rightmargin=n
152
153       -topmargin=n
154
155       -bottommargin=n
156              These options control the margins added to the  image,  measured
157              from  the  far  edge  of  the type.  See Margins ⟨#margins⟩  for
158              details.
159
160              All sizes are in points, as a floating point number.
161
162              These options were new in Netpbm 10.75 (June 2016).
163
164
165       -ascent=n
166
167       -descent=n
168              These options control the margins added to the  image,  measured
169              from the text baseline.  See Margins ⟨#margins⟩  for details.
170
171              Sizes are in points, as a floating point number.
172
173              These options were new in Netpbm 10.75 (June 2016).
174
175
176       -pad   This pads the image on the top and bottom to the where the high‐
177              est and lowest characters in the font would reach, even  if  you
178              don't   have   those  characters  in  your  text.   See  Margins
179              ⟨#margins⟩  for details.
180
181              This option was new in Netpbm 10.75 (June 2016).
182
183
184       -crop  This makes the program crop all sides to the  far  edge  of  the
185              type.   It  is the same as -leftmargin=0 -rightmargin=0 -topmar‐
186              gin=0 -bottommargin=0.  See Margins ⟨#margins⟩  for details.
187
188              This option was new in Netpbm 10.75 (June 2016).
189
190
191       -stroke=n
192              This is the width of line, in points, to use  for  stroke  font.
193              There  is  no  default  stroke  width because the characters are
194              solid by default.
195
196
197       -verbose
198              This option makes pbmtextps display extra information  on  Stan‐
199              dard Error about its processing.
200
201
202       -dump-ps
203              This  option  makes pbmtextps write to Standard Output the Post‐
204              script program it would use to create the image, rather than the
205              image  itself.  You can use this as input to a Postscript inter‐
206              preter (such as Ghostscript or a a printer) or to understand the
207              program better.
208
209              This option was new in Netpbm 10.75 (June 2016).
210
211
212
213

USAGE

215       You can generate antialiased text by using a larger resolution than the
216       default and scaling the image down using pamscale.
217
218       See the manual for the similar pbmtext for more advice on usage.
219
220

HISTORY

222       pbmtextps was added to Netpbm in Release 10.0 (June 2002).
223
224
225

SEE ALSO

227       pbmtext(1), pamcut(1),  pnmcrop(1),  pamcomp(1),  ppmchange(1),  pnmro‐
228       tate(1), pamscale(1), ppmlabel(1), pbm(1)
229
230

AUTHOR

232       Copyright (C) 2002 by James McCann
233

DOCUMENT SOURCE

235       This  manual  page was generated by the Netpbm tool 'makeman' from HTML
236       source.  The master documentation is at
237
238              http://netpbm.sourceforge.net/doc/pbmtextps.html
239
240netpbm documentation             15 June 2016         Pbmtextps User Manual(0)
Impressum