aboutsummaryrefslogtreecommitdiff
path: root/libgraphics/doc/libgraphics.ps
blob: 1a566f7a4961a41bec9d8f86a408245ffb9360a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
%!PS-Adobe-2.0
%%Version: 0.1
%%Creator: troff, Plan 9 edition
%%DocumentFonts: (atend)
%%Pages: (atend)
%%EndComments
%
% Version 3.3.2 prologue for troff files.
%

/#copies 1 store
/aspectratio 1 def
/formsperpage 1 def
/landscape false def
/linewidth .3 def
/magnification 1 def
/margin 0 def
/orientation 0 def
/resolution 720 def
/rotation 1 def
/xoffset 0 def
/yoffset 0 def

/roundpage true def
/useclippath true def
/pagebbox [0 0 612 792] def

/R  /Times-Roman def
/I  /Times-Italic def
/B  /Times-Bold def
/BI /Times-BoldItalic def
/H  /Helvetica def
/HI /Helvetica-Oblique def
/HB /Helvetica-Bold def
/HX /Helvetica-BoldOblique def
/CW /Courier def
/CO /Courier def
/CI /Courier-Oblique def
/CB /Courier-Bold def
/CX /Courier-BoldOblique def
/PA /Palatino-Roman def
/PI /Palatino-Italic def
/PB /Palatino-Bold def
/PX /Palatino-BoldItalic def
/Hr /Helvetica-Narrow def
/Hi /Helvetica-Narrow-Oblique def
/Hb /Helvetica-Narrow-Bold def
/Hx /Helvetica-Narrow-BoldOblique def
/KR /Bookman-Light def
/KI /Bookman-LightItalic def
/KB /Bookman-Demi def
/KX /Bookman-DemiItalic def
/AR /AvantGarde-Book def
/AI /AvantGarde-BookOblique def
/AB /AvantGarde-Demi def
/AX /AvantGarde-DemiOblique def
/NR /NewCenturySchlbk-Roman def
/NI /NewCenturySchlbk-Italic def
/NB /NewCenturySchlbk-Bold def
/NX /NewCenturySchlbk-BoldItalic def
/ZD /ZapfDingbats def
/ZI /ZapfChancery-MediumItalic def
/S  /S def
/S1 /S1 def
/GR /Symbol def

/inch {72 mul} bind def
/min {2 copy gt {exch} if pop} bind def

/setup {
	counttomark 2 idiv {def} repeat pop

	landscape {/orientation 90 orientation add def} if
	/scaling 72 resolution div def
	linewidth setlinewidth
	1 setlinecap

	pagedimensions
	xcenter ycenter translate
	orientation rotation mul rotate
	width 2 div neg height 2 div translate
	xoffset inch yoffset inch neg translate
	margin 2 div dup neg translate
	magnification dup aspectratio mul scale
	scaling scaling scale

	addmetrics
	0 0 moveto
} def

/pagedimensions {
	useclippath userdict /gotpagebbox known not and {
		/pagebbox [clippath pathbbox newpath] def
		roundpage currentdict /roundpagebbox known and {roundpagebbox} if
	} if
	pagebbox aload pop
	4 -1 roll exch 4 1 roll 4 copy
	landscape {4 2 roll} if
	sub /width exch def
	sub /height exch def
	add 2 div /xcenter exch def
	add 2 div /ycenter exch def
	userdict /gotpagebbox true put
} def

/addmetrics {
	/Symbol /S null Sdefs cf
	/Times-Roman /S1 StandardEncoding dup length array copy S1defs cf
} def

/pagesetup {
	/page exch def
	currentdict /pagedict known currentdict page known and {
		page load pagedict exch get cvx exec
	} if
} def

/decodingdefs [
	{counttomark 2 idiv {y moveto show} repeat}
	{neg /y exch def counttomark 2 idiv {y moveto show} repeat}
	{neg moveto {2 index stringwidth pop sub exch div 0 32 4 -1 roll widthshow} repeat}
	{neg moveto {spacewidth sub 0.0 32 4 -1 roll widthshow} repeat}
	{counttomark 2 idiv {y moveto show} repeat}
	{neg setfunnytext}
] def

/setdecoding {/t decodingdefs 3 -1 roll get bind def} bind def

/w {neg moveto show} bind def
/m {neg dup /y exch def moveto} bind def
/done {/lastpage where {pop lastpage} if} def

/f {
	dup /font exch def findfont exch
	dup /ptsize exch def scaling div dup /size exch def scalefont setfont
	linewidth ptsize mul scaling 10 mul div setlinewidth
	/spacewidth ( ) stringwidth pop def
} bind def

/changefont {
	/fontheight exch def
	/fontslant exch def
	currentfont [
		1 0
		fontheight ptsize div fontslant sin mul fontslant cos div
		fontheight ptsize div
		0 0
	] makefont setfont
} bind def

/sf {f} bind def

/cf {
	dup length 2 idiv
	/entries exch def
	/chtab exch def
	/newencoding exch def
	/newfont exch def

	findfont dup length 1 add dict
	/newdict exch def
	{1 index /FID ne {newdict 3 1 roll put}{pop pop} ifelse} forall

	newencoding type /arraytype eq {newdict /Encoding newencoding put} if

	newdict /Metrics entries dict put
	newdict /Metrics get
	begin
		chtab aload pop
		1 1 entries {pop def} for
		newfont newdict definefont pop
	end
} bind def

%
% A few arrays used to adjust reference points and character widths in some
% of the printer resident fonts. If square roots are too high try changing
% the lines describing /radical and /radicalex to,
%
%	/radical	[0 -75 550 0]
%	/radicalex	[-50 -75 500 0]
%
% Move braceleftbt a bit - default PostScript character is off a bit.
%

/Sdefs [
	/bracketlefttp		[201 500]
	/bracketleftbt		[201 500]
	/bracketrighttp		[-81 380]
	/bracketrightbt		[-83 380]
	/braceleftbt		[203 490]
	/bracketrightex		[220 -125 500 0]
	/radical		[0 0 550 0]
	/radicalex		[-50 0 500 0]
	/parenleftex		[-20 -170 0 0]
	/integral		[100 -50 500 0]
	/infinity		[10 -75 730 0]
] def

/S1defs [
	/underscore		[0 80 500 0]
	/endash			[7 90 650 0]
] def
%
% Tries to round clipping path dimensions, as stored in array pagebbox, so they
% match one of the known sizes in the papersizes array. Lower left coordinates
% are always set to 0.
%

/roundpagebbox {
    7 dict begin
	/papersizes [8.5 inch 11 inch 14 inch 17 inch] def

	/mappapersize {
		/val exch def
		/slop .5 inch def
		/diff slop def
		/j 0 def
		0 1 papersizes length 1 sub {
			/i exch def
			papersizes i get val sub abs
			dup diff le {/diff exch def /j i def} {pop} ifelse
		} for
		diff slop lt {papersizes j get} {val} ifelse
	} def

	pagebbox 0 0 put
	pagebbox 1 0 put
	pagebbox dup 2 get mappapersize 2 exch put
	pagebbox dup 3 get mappapersize 3 exch put
    end
} bind def

%%EndProlog
%%BeginSetup
mark
%
% Encoding vector and redefinition of findfont for the ISO Latin1 standard.
% The 18 characters missing from ROM based fonts on older printers are noted
% below.
%

/ISOLatin1Encoding [
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/space
	/exclam
	/quotedbl
	/numbersign
	/dollar
	/percent
	/ampersand
	/quoteright
	/parenleft
	/parenright
	/asterisk
	/plus
	/comma
	/minus
	/period
	/slash
	/zero
	/one
	/two
	/three
	/four
	/five
	/six
	/seven
	/eight
	/nine
	/colon
	/semicolon
	/less
	/equal
	/greater
	/question
	/at
	/A
	/B
	/C
	/D
	/E
	/F
	/G
	/H
	/I
	/J
	/K
	/L
	/M
	/N
	/O
	/P
	/Q
	/R
	/S
	/T
	/U
	/V
	/W
	/X
	/Y
	/Z
	/bracketleft
	/backslash
	/bracketright
	/asciicircum
	/underscore
	/quoteleft
	/a
	/b
	/c
	/d
	/e
	/f
	/g
	/h
	/i
	/j
	/k
	/l
	/m
	/n
	/o
	/p
	/q
	/r
	/s
	/t
	/u
	/v
	/w
	/x
	/y
	/z
	/braceleft
	/bar
	/braceright
	/asciitilde
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/.notdef
	/dotlessi
	/grave
	/acute
	/circumflex
	/tilde
	/macron
	/breve
	/dotaccent
	/dieresis
	/.notdef
	/ring
	/cedilla
	/.notdef
	/hungarumlaut
	/ogonek
	/caron
	/space
	/exclamdown
	/cent
	/sterling
	/currency
	/yen
	/brokenbar		% missing
	/section
	/dieresis
	/copyright
	/ordfeminine
	/guillemotleft
	/logicalnot
	/hyphen
	/registered
	/macron
	/degree			% missing
	/plusminus		% missing
	/twosuperior		% missing
	/threesuperior		% missing
	/acute
	/mu			% missing
	/paragraph
	/periodcentered
	/cedilla
	/onesuperior		% missing
	/ordmasculine
	/guillemotright
	/onequarter		% missing
	/onehalf		% missing
	/threequarters		% missing
	/questiondown
	/Agrave
	/Aacute
	/Acircumflex
	/Atilde
	/Adieresis
	/Aring
	/AE
	/Ccedilla
	/Egrave
	/Eacute
	/Ecircumflex
	/Edieresis
	/Igrave
	/Iacute
	/Icircumflex
	/Idieresis
	/Eth			% missing
	/Ntilde
	/Ograve
	/Oacute
	/Ocircumflex
	/Otilde
	/Odieresis
	/multiply		% missing
	/Oslash
	/Ugrave
	/Uacute
	/Ucircumflex
	/Udieresis
	/Yacute			% missing
	/Thorn			% missing
	/germandbls
	/agrave
	/aacute
	/acircumflex
	/atilde
	/adieresis
	/aring
	/ae
	/ccedilla
	/egrave
	/eacute
	/ecircumflex
	/edieresis
	/igrave
	/iacute
	/icircumflex
	/idieresis
	/eth			% missing
	/ntilde
	/ograve
	/oacute
	/ocircumflex
	/otilde
	/odieresis
	/divide			% missing
	/oslash
	/ugrave
	/uacute
	/ucircumflex
	/udieresis
	/yacute			% missing
	/thorn			% missing
	/ydieresis
] def

/NewFontDirectory FontDirectory maxlength dict def

%
% Apparently no guarantee findfont is defined in systemdict so the obvious
%
%	systemdict /findfont get exec
%
% can generate an error. So far the only exception is a VT600 (version 48.0).
%

userdict /@RealFindfont known not {
	userdict begin
		/@RealFindfont systemdict begin /findfont load end def
	end
} if

/findfont {
	dup NewFontDirectory exch known not {
		dup
		%dup systemdict /findfont get exec	% not always in systemdict
		dup userdict /@RealFindfont get exec
		dup /Encoding get StandardEncoding eq {
			dup length dict begin
				{1 index /FID ne {def}{pop pop} ifelse} forall
				/Encoding ISOLatin1Encoding def
				currentdict
			end
			/DummyFontName exch definefont
		} if
		NewFontDirectory 3 1 roll put
	} if
	NewFontDirectory exch get
} bind def

%%Patch from lp
%%EndPatch from lp

setup
%%EndSetup
%%Page: 1 1
/saveobj save def
mark
1 pagesetup
12 /LucidaSans-Demi f
(libgraphics) 2533 1220 w
10 /LucidaSans-Italic f
(Rodrigo G. L\363pez) 2469 1480 w
(rgl@antares-labs.eu) 2377 1760 w
10 /LucidaSansUnicode00 f
(Antares Telecom Laboratories) 2156 1960 w
(Albatera, Alicante) 2451 2100 w
10 /LucidaSans-Demi f
(1.) 720 2700 w
(Data Structures) 873 2700 w
(1.1.) 720 2940 w
(Camera) 962 2940 w
9 /LucidaTypewriter f
(struct) 920 3110 w
(Camera) 1375 3110 w
({) 1830 3110 w
(};) 920 3330 w
10 /LucidaSansUnicode00 f
(A camera) 970 3546 w
8 /S1 f
(__________________) 720 6980 w
8 /LucidaSansUnicode00 f
(ACHTUNG!) 720 7080 w
(this) 1163 7080 w
(is) 1333 7080 w
(a) 1423 7080 w
8 /LucidaSans-Demi f
(WORK) 1493 7080 w
(IN) 1769 7080 w
(PROGRESS) 1883 7080 w
cleartomark
showpage
saveobj restore
%%EndPage: 1 1
%%Trailer
done
%%DocumentFonts: S1 LucidaSansUnicode00 LucidaSans-Demi LucidaSans-Italic LucidaTypewriter
%%Pages: 1