v04i077: xpic -- pic previewer for X11, Part12/15

Dan Heller argv at island.uu.net
Sat Jul 22 17:41:53 AEST 1989


Submitted-by: Mark Moraes <moraes at ai.toronto.edu>
Posting-number: Volume 4, Issue 77
Archive-name: xpic/part12



#! /bin/sh
# This is a shell archive.  Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file".  To overwrite existing
# files, type "sh file -c".  You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g..  If this archive is complete, you
# will see the following message at the end:
#		"End of archive 12 (of 15)."
# Contents:  xpic/doc/van.x xpic/test/van.x xpic/x2ps.c
# Wrapped by moraes at neat.ai on Thu Jul 13 22:36:11 1989
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'xpic/doc/van.x' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'xpic/doc/van.x'\"
else
echo shar: Extracting \"'xpic/doc/van.x'\" \(17693 characters\)
sed "s/^X//" >'xpic/doc/van.x' <<'END_OF_FILE'
X5 48 880 621 8
X6 902 392 592 568 609 4000 0
X480 592 25 0 4
XODU - Operand Decode Unit
X6 886 138 584 159 597 4000 0
X148 584 4 0 2
Xind2
X6 887 306 580 327 593 4000 0
X316 580 4 0 2
Xind1
X6 843 45 544 83 557 4000 0
X64 544 8 0 2
Xind2.set
X1 876 148 492 148 508 0 1
X2
X 148 492 148 508
X1 877 140 508 156 508 0 1
X2
X 140 508 156 508
X1 878 308 492 324 508 0 1
X4
X 316 492 316 508 308 508 324 508
X1 879 308 508 324 524 0 1
X3
X 308 508 316 524 324 508
X1 880 140 508 156 524 0 1
X3
X 140 508 148 524 156 508
X4 881 144 525 150 531 0 1
X147 528 3
X4 882 313 521 319 527 0 1
X316 524 3
X1 883 316 528 316 540 20 1
X2
X 316 528 316 540
X1 884 148 532 148 544 20 1
X2
X 148 532 148 544
X1 885 292 540 340 556 0 1
X5
X 296 540 340 540 332 556 300 556
X 292 540
X1 888 124 548 172 564 0 1
X7
X 128 548 172 548 164 564 136 564
X 140 564 132 564 124 548
X1 889 316 556 316 576 20 1
X2
X 316 556 316 576
X1 890 148 564 148 584 20 1
X2
X 148 564 148 584
X1 891 96 532 136 548 20 1
X3
X 96 532 136 532 136 548
X1 892 276 524 300 540 20 1
X3
X 276 524 300 524 300 540
X1 893 276 548 296 548 20 1
X2
X 276 548 296 548
X1 894 92 556 128 556 20 1
X2
X 92 556 128 556
X6 895 41 524 79 537 4000 0
X60 524 8 0 2
Xind2.val
X6 896 233 540 271 553 4000 0
X252 540 8 0 2
Xind1.set
X6 897 229 516 267 529 4000 0
X248 516 8 0 2
Xind1.val
X6 898 324 484 356 497 4000 0
X340 484 5 0 2
XQA(7)
X6 899 108 484 140 497 4000 0
X124 484 5 0 2
XQA(6)
X2 740 304 392 320 408 0 1
X5
X 304 408 304 400 312 392 320 400
X 320 408
X2 741 304 408 320 408 0 1
X2
X 304 408 320 408
X4 731 282 321 286 325 0 1
X284 323 2
X1 729 272 288 276 288 20 1
X2
X 272 288 276 288
X1 728 268 332 276 332 20 1
X2
X 268 332 276 332
X1 727 300 268 324 268 0 1
X2
X 300 268 324 268
X1 726 300 224 404 292 0 1
X4
X 404 224 300 224 300 292 320 292
X1 725 268 276 320 288 0 1
X4
X 268 288 288 288 288 276 320 276
X1 724 272 288 284 324 0 1
X3
X 272 288 272 324 284 324
X1 723 272 332 288 332 0 1
X2
X 272 332 288 332
X1 722 304 300 320 328 0 1
X4
X 304 328 312 328 312 300 320 300
X1 718 336 296 400 320 20 1
X4
X 336 296 360 296 360 320 400 320
X1 717 336 272 400 304 20 1
X4
X 336 272 368 272 368 304 400 304
X1 716 376 240 400 288 20 1
X4
X 400 240 376 240 376 288 400 288
X1 712 384 256 400 336 20 1
X4
X 400 256 384 256 384 336 400 336
X3 702 400 280 480 344 0 1
X6 703 412 328 453 342 4000 0
X432 328 5 0 3
XIBASE
X6 704 440 305 472 319 0 0
X456 312 3 0 3
XROM
X6 705 437 289 476 303 0 0
X456 296 6 0 3
X4X5bit
X6 706 409 313 424 327 0 0
X416 320 2 0 3
XSP
X6 707 408 297 424 311 0 0
X416 304 2 0 3
XFP
X6 708 408 281 425 295 0 0
X416 288 2 0 3
XPC
X2 690 112 264 128 280 0 1
X5
X 112 280 112 272 120 264 128 272
X 128 280
X2 691 112 280 128 280 0 1
X2
X 112 280 128 280
X2 684 320 264 336 280 0 1
X5
X 320 264 328 264 336 272 328 280
X 320 280
X1 654 400 256 408 256 20 1
X2
X 408 256 400 256
X1 651 400 240 408 240 20 1
X2
X 408 240 400 240
X1 650 400 224 408 224 20 1
X2
X 408 224 400 224
X1 649 780 264 788 268 0 1
X2
X 788 264 780 268
X1 648 624 172 628 180 0 1
X2
X 628 172 624 180
X1 647 620 324 628 332 0 1
X2
X 628 324 620 332
X1 646 620 236 628 244 0 1
X2
X 628 236 620 244
X1 645 772 204 784 212 0 1
X2
X 772 212 784 204
X1 644 776 208 780 208 0 1
X2
X 776 208 780 208
X1 643 788 208 796 216 0 1
X2
X 788 216 796 208
X6 641 715 148 750 161 4000 0
X732 148 7 0 2
X(FP/SP)
X6 185 416 232 456 246 4000 0
X436 232 6 0 3
XPC.ena
X6 184 418 216 462 230 4000 0
X440 216 7 0 3
Xop2.ena
X1 638 676 336 680 336 20 1
X2
X 676 336 680 336
X6 637 660 324 676 337 4000 0
X668 324 3 0 2
Xbcc
X6 636 797 216 803 229 4000 0
X800 216 1 0 2
X5
X6 635 765 216 771 229 4000 0
X768 216 1 0 2
X5
X1 604 672 204 680 204 0 1
X2
X 672 204 680 204
X1 375 664 152 664 160 20 1
X2
X 664 152 664 160
X1 583 692 216 692 248 0 1
X3
X 692 248 692 216 692 216
X1 625 832 304 840 304 20 1
X2
X 840 304 832 304
X1 566 592 144 616 144 0 1
X2
X 592 144 616 144
X2 565 592 144 616 160 0 1
X6
X 592 144 592 152 600 160 608 160
X 616 152 616 144
X1 601 600 136 600 144 20 1
X2
X 600 136 600 144
X1 623 828 144 836 144 20 1
X2
X 836 144 828 144
X1 309 808 336 816 352 0 1
X2
X 816 336 808 352
X1 341 792 192 792 240 20 1
X2
X 792 192 792 240
X6 364 776 176 808 190 4000 0
X792 176 3 0 3
XROM
X1 622 720 304 728 304 20 1
X2
X 720 304 728 304
X1 614 728 304 740 304 0 1
X2
X 740 304 728 304
X6 619 692 304 717 317 4000 0
X704 304 5 0 2
X(Bf1)
X6 618 838 288 875 301 4000 0
X856 288 7 0 2
XBf1.ena
X6 615 688 288 720 301 4000 0
X704 288 5 0 2
XQA(7)
X1 613 740 288 740 304 0 1
X2
X 740 288 740 304
X1 612 748 288 748 304 0 1
X2
X 748 304 748 288
X1 611 748 304 832 304 0 1
X2
X 832 304 748 304
X2 610 736 268 752 288 0 1
X5
X 736 288 736 280 744 268 752 280
X 752 288
X1 609 736 288 752 288 0 1
X2
X 736 288 752 288
X1 608 744 248 744 272 0 1
X3
X 744 248 744 272 744 272
X1 607 756 248 767 249 0 1
X2
X 756 249 767 248
X1 606 656 112 712 336 0 1
X9
X 696 112 696 208 712 208 712 264
X 680 264 680 320 656 320 656 336
X 680 336
X6 605 718 232 747 245 4000 0
X732 232 6 0 2
XB1.sel
X1 576 672 200 672 216 0 1
X2
X 672 200 672 216
X1 603 760 248 760 248 20 1
X2
X 760 248 760 248
X6 361 752 160 768 174 4000 0
X760 160 2 0 3
XFP
X1 366 712 104 744 168 0 1
X4
X 744 168 736 168 712 168 712 104
X1 595 600 128 600 144 0 1
X2
X 600 128 600 144
X6 263 549 112 588 125 4000 0
X568 112 8 0 2
XCall.ena
X1 596 576 128 600 128 0 1
X2
X 600 128 576 128
X1 594 604 176 608 176 0 1
X2
X 604 176 608 176
X1 593 604 160 604 176 0 1
X2
X 604 160 604 176
X4 592 692 248 692 248 0 1
X692 248 0
X4 591 693 248 693 248 0 1
X693 248 0
X4 590 693 247 693 247 0 1
X693 247 0
X4 589 693 247 693 247 0 1
X693 247 0
X4 588 670 210 676 216 0 1
X673 213 3
X1 453 608 128 824 128 0 1
X2
X 824 128 608 128
X6 363 773 160 812 174 4000 0
X792 160 6 0 3
X2X5bit
X6 385 709 184 715 197 4000 0
X712 184 1 0 2
X5
X1 585 676 212 692 212 0 1
X2
X 692 212 676 212
X1 584 692 212 692 216 0 1
X3
X 692 212 692 216 692 216
X1 458 640 248 760 272 0 1
X5
X 760 248 672 248 672 272 640 272
X 640 264
X1 449 824 128 832 128 20 1
X2
X 832 128 824 128
X1 579 680 144 832 208 0 1
X3
X 832 144 680 144 680 208
X1 372 696 104 696 112 20 1
X2
X 696 104 696 112
X1 577 640 200 656 208 20 1
X3
X 656 208 640 208 640 200
X2 575 656 200 672 216 0 1
X5
X 672 200 664 200 656 208 664 216
X 672 216
X1 571 732 184 736 184 0 1
X2
X 736 184 732 184
X4 570 727 183 731 187 0 1
X729 185 2
X1 569 720 184 728 192 0 1
X2
X 720 192 728 184
X1 568 720 180 728 184 0 1
X2
X 720 180 728 184
X1 567 720 180 720 192 0 1
X2
X 720 180 720 192
X6 509 563 512 599 526 4000 0
X581 512 7 0 3
Xrti.ena
X1 461 180 76 188 80 0 1
X2
X 180 80 188 76
X1 460 300 72 308 80 0 1
X2
X 300 80 308 72
X1 459 640 264 640 272 20 1
X2
X 640 272 640 264
X1 334 760 240 768 256 0 1
X2
X 768 256 760 240
X1 454 608 128 608 144 0 1
X2
X 608 128 608 144
X6 76 836 136 877 150 4000 0
X856 136 7 0 3
Xopl.ena
X6 75 836 120 877 134 4000 0
X856 120 6 0 3
XCC.ena
X6 443 683 608 853 621 4000 0
X768 608 31 0 2
XSEB=SignExtender+Bufferr output
X6 421 563 488 605 502 4000 0
X584 488 7 0 3
Xsop.ena
X6 422 826 512 871 526 4000 0
X848 512 8 0 3
Xpull.ena
X1 423 632 488 680 536 0 1
X2
X 680 536 632 488
X1 424 760 488 808 536 0 1
X2
X 760 536 808 488
X1 425 680 536 760 536 0 1
X2
X 680 536 760 536
X1 426 776 472 776 488 20 1
X2
X 776 472 776 488
X1 427 744 472 744 488 20 1
X2
X 744 472 744 488
X1 428 712 472 712 488 20 1
X2
X 712 472 712 488
X1 429 664 472 664 488 20 1
X2
X 664 472 664 488
X1 430 632 488 808 488 0 1
X2
X 632 488 808 488
X6 431 655 488 674 502 4000 0
X664 488 3 0 3
Xsop
X6 432 706 488 719 502 4000 0
X712 488 3 0 3
Xrti
X6 433 733 488 755 502 4000 0
X744 488 4 0 3
Xpull
X6 434 763 488 789 502 4000 0
X776 488 4 0 3
Xpush
X6 435 640 456 689 470 4000 0
X664 456 7 0 3
XQA(7:6)
X6 436 699 456 726 470 4000 0
X712 456 4 0 3
X'+1'
X6 437 737 456 752 470 4000 0
X744 456 3 0 3
X'0'
X6 438 767 456 786 470 4000 0
X776 456 4 0 3
X'-2'
X1 439 608 496 640 496 20 1
X2
X 608 496 640 496
X1 440 608 520 664 520 20 1
X2
X 608 520 664 520
X1 441 800 496 824 496 20 1
X2
X 824 496 800 496
X1 442 776 520 824 520 20 1
X2
X 824 520 776 520
X1 389 704 88 704 96 20 1
X2
X 704 88 704 96
X1 388 704 88 704 104 0 1
X2
X 704 88 704 104
X1 384 704 96 776 240 20 1
X4
X 704 96 704 200 776 200 776 240
X1 370 712 96 712 104 20 1
X2
X 712 96 712 104
X1 373 712 168 720 184 0 1
X3
X 720 184 712 184 712 168
X6 377 653 152 659 165 4000 0
X656 152 1 0 2
X4
X6 376 625 136 672 149 4000 0
X648 136 8 0 2
XQA(11:8)
X1 374 736 184 744 184 0 1
X2
X 744 184 736 184
X6 369 717 88 755 101 4000 0
X736 88 6 0 2
XQA(12)
X6 362 753 176 768 190 4000 0
X760 176 2 0 3
XSP
X3 365 744 160 816 192 0 1
X6 73 796 336 804 350 4000 0
X800 336 1 0 3
XF
X1 311 776 352 808 352 0 1
X2
X 776 352 808 352
X1 308 816 128 824 344 20 1
X3
X 824 128 824 344 816 344
X6 283 658 224 670 237 4000 0
X664 224 3 0 2
X'0'
X1 282 648 240 664 240 20 1
X2
X 664 240 648 240
X1 281 648 152 664 168 0 1
X3
X 648 168 664 168 664 152
X6 280 601 384 648 397 4000 0
X624 384 10 0 2
X0ffset1(5)
X6 279 613 296 619 309 4000 0
X616 296 1 0 2
X5
X6 278 621 312 627 325 4000 0
X624 312 1 0 2
X5
X6 277 621 224 627 237 4000 0
X624 224 1 0 2
X5
X6 276 621 160 627 173 4000 0
X624 160 1 0 2
X4
X1 271 640 288 640 304 20 1
X2
X 640 288 640 304
X1 270 608 176 608 376 20 1
X2
X 608 176 608 376
X1 268 608 328 632 328 20 1
X2
X 632 328 608 328
X1 267 608 240 632 240 20 1
X2
X 632 240 608 240
X1 266 608 176 632 176 20 1
X2
X 632 176 608 176
X6 262 725 536 731 549 4000 0
X728 536 1 0 2
X2
X6 227 147 48 206 61 4000 0
X176 48 9 0 2
XQA <17:0>
X6 226 252 48 309 61 4000 0
X280 48 9 0 2
XQB <17:0>
X6 186 416 248 481 262 4000 0
X448 248 9 0 3
XJBASE.ena
X6 182 233 440 263 454 4000 0
X248 440 5 0 3
X(Bf2)
X6 181 229 416 267 430 4000 0
X248 416 5 0 3
XQA(6)
X6 180 239 384 274 398 4000 0
X256 384 6 0 3
XB2.sel
X6 177 229 312 267 326 4000 0
X248 312 5 0 3
XQA(4)
X6 176 235 296 261 310 4000 0
X248 296 4 0 3
X(FP)
X6 175 229 280 267 294 4000 0
X248 280 5 0 3
XQA(5)
X6 170 5 288 43 302 4000 0
X24 288 5 0 3
XQA(3)
X6 169 5 304 43 318 4000 0
X24 304 5 0 3
XQA(4)
X6 168 5 320 43 334 4000 0
X24 320 5 0 3
XQA(5)
X6 119 153 96 167 110 4000 0
X160 96 2 0 3
X10
X1 145 184 64 184 96 0 1
X2
X 184 64 184 96
X6 123 209 96 223 110 4000 0
X216 96 2 0 3
X13
X6 124 261 96 268 110 4000 0
X264 96 1 0 3
X7
X1 115 40 96 312 232 0 1
X3
X 312 96 40 96 40 232
X6 2 140 113 165 127 0 0
X152 120 3 0 3
XSEB
X3 9 136 112 168 128 0 1
X6 132 153 136 167 150 4000 0
X160 136 2 0 3
X30
X1 93 152 128 152 160 20 1
X2
X 152 128 152 160
X6 141 129 240 143 254 4000 0
X136 240 2 0 3
X30
X1 104 128 232 152 232 20 1
X2
X 128 232 152 232
X1 105 120 120 136 120 20 1
X2
X 120 120 136 120
X6 23 116 241 125 255 0 0
X120 248 1 0 3
XB
X6 22 116 225 125 239 0 0
X120 232 1 0 3
XE
X3 27 112 208 128 256 0 1
X6 21 117 209 124 223 0 0
X120 216 1 0 3
XS
X6 160 19 336 45 350 4000 0
X32 336 4 0 3
X(FP)
X1 91 304 96 304 112 20 1
X2
X 304 96 304 112
X6 125 305 96 319 110 4000 0
X312 96 2 0 3
X12
X6 156 361 152 440 166 4000 0
X400 152 12 0 3
Xoffset<17:0>
X6 155 313 72 327 86 4000 0
X320 72 2 0 3
X18
X1 152 304 64 352 112 0 1
X4
X 304 64 304 88 352 88 352 112
X6 148 337 96 351 110 4000 0
X344 96 2 0 3
X18
X6 146 193 72 207 86 4000 0
X200 72 2 0 3
X18
X6 140 129 344 143 358 4000 0
X136 344 2 0 3
X30
X6 139 138 384 199 398 4000 0
X168 384 11 0 3
Xoffset2(30)
X6 138 161 368 175 382 4000 0
X168 368 2 0 3
X30
X1 137 280 120 288 120 20 1
X2
X 280 120 288 120
X1 136 232 120 240 120 20 1
X2
X 232 120 240 120
X1 135 176 120 184 120 20 1
X2
X 176 120 184 120
X6 128 353 136 367 150 4000 0
X360 136 2 0 3
X18
X6 129 305 136 319 150 4000 0
X312 136 2 0 3
X12
X6 131 201 136 215 150 4000 0
X208 136 2 0 3
X30
X6 130 257 136 271 150 4000 0
X264 136 2 0 3
X12
X6 127 382 112 434 126 4000 0
X408 112 9 0 3
X36bit.ena
X1 106 368 120 384 120 20 1
X2
X 384 120 368 120
X1 103 128 336 152 336 20 1
X2
X 128 336 152 336
X1 102 152 160 352 384 20 1
X3
X 352 160 152 160 152 384
X1 101 352 128 352 160 20 1
X2
X 352 128 352 160
X1 100 304 128 304 160 20 1
X2
X 304 128 304 160
X1 95 256 128 256 160 20 1
X2
X 256 128 256 160
X1 94 200 128 200 160 20 1
X2
X 200 128 200 160
X1 90 256 96 256 112 20 1
X2
X 256 96 256 112
X1 89 200 96 200 112 20 1
X2
X 200 96 200 112
X1 88 152 96 152 112 20 1
X2
X 152 96 152 112
X1 87 232 48 232 64 0 1
X2
X 232 48 232 64
X6 66 628 280 669 294 4000 0
X648 280 6 0 3
XCC.ena
X3 81 632 216 648 264 0 1
X3 80 632 152 648 200 0 1
X6 74 783 376 834 390 4000 0
X808 376 8 0 3
XBreq1(5)
X6 68 635 320 646 334 4000 0
X640 320 1 0 3
XU
X6 67 636 304 645 318 4000 0
X640 304 1 0 3
XB
X6 65 636 248 644 262 4000 0
X640 248 1 0 3
XF
X6 64 635 232 646 246 4000 0
X640 232 1 0 3
XU
X6 63 636 216 645 230 4000 0
X640 216 1 0 3
XB
X6 62 636 184 645 198 4000 0
X640 184 1 0 3
XB
X6 61 636 168 645 182 4000 0
X640 168 1 0 3
XE
X6 60 637 152 644 166 4000 0
X640 152 1 0 3
XS
X3 28 112 312 128 360 0 1
X6 26 116 345 124 359 0 0
X120 352 1 0 3
XF
X6 25 115 329 126 343 0 0
X120 336 1 0 3
XU
X6 24 116 313 125 327 0 0
X120 320 1 0 3
XB
X6 20 264 145 297 159 0 0
X280 152 6 0 3
Xoff.30
X6 19 216 145 249 159 0 0
X232 152 6 0 3
Xoff.25
X6 18 160 145 193 159 0 0
X176 152 6 0 3
Xoff.13
X1 17 280 120 288 144 0 1
X3
X 288 120 280 120 280 144
X1 16 232 120 240 144 0 1
X3
X 240 120 232 120 232 144
X1 15 176 120 184 144 0 1
X4
X 184 120 176 120 176 120 176 144
X3 14 336 112 368 128 0 1
X3 13 288 112 320 128 0 1
X3 12 240 112 272 128 0 1
X3 11 184 112 216 128 0 1
X3 10 184 112 184 120 0 1
X3 8 128 48 328 64 0 1
X6 5 292 113 317 127 0 0
X304 120 3 0 3
XSEB
X6 6 338 113 366 127 0 0
X352 120 3 0 3
XBUF
X6 4 244 113 269 127 0 0
X256 120 3 0 3
XSEB
X6 3 188 113 213 127 0 0
X200 120 3 0 3
XSEB
X6 243 754 576 862 590 4000 0
X808 576 21 0 3
Xbefore SP is updated
X6 242 763 560 854 574 4000 0
X808 560 17 0 3
X+1 will be added
X6 241 710 560 746 574 4000 0
X728 560 6 0 3
Xsop(2)
X3 82 632 304 648 352 0 1
X3 315 680 328 752 360 0 1
X6 314 690 344 734 358 4000 0
X712 344 7 0 3
X8X8bits
X6 313 683 328 742 342 4000 0
X712 328 7 0 3
XBCC ROM
X6 143 49 216 112 230 4000 0
X80 216 7 0 3
XQA<3:0>
X6 323 824 472 873 486 4000 0
X848 472 8 0 3
Xpush.ena
X1 332 800 240 808 256 0 1
X2
X 808 240 800 256
X1 333 768 256 800 256 0 1
X2
X 800 256 768 256
X1 331 760 240 808 240 0 1
X2
X 760 240 808 240
X6 339 773 240 780 254 4000 0
X776 240 1 0 3
X1
X6 340 789 240 796 254 4000 0
X792 240 1 0 3
X0
X1 342 784 256 800 336 20 1
X4
X 784 256 784 280 800 280 800 336
X1 316 768 336 816 336 0 1
X2
X 768 336 816 336
X6 346 780 336 789 350 4000 0
X784 336 1 0 3
XT
X1 310 768 336 776 352 0 1
X2
X 768 336 776 352
X1 349 736 320 784 376 20 1
X8
X 736 360 736 376 760 376 760 320
X 784 320 776 320 784 320 784 336
X1 351 792 352 792 376 20 1
X2
X 792 352 792 376
X6 352 749 360 755 373 4000 0
X752 360 1 0 2
X4
X6 353 789 264 795 277 4000 0
X792 264 1 0 2
X5
X6 69 636 336 644 350 4000 0
X640 336 1 0 3
XF
X6 354 685 360 691 373 4000 0
X688 360 1 0 2
X4
X1 356 648 344 696 376 20 1
X5
X 696 360 696 376 664 376 664 344
X 648 344
X6 358 646 88 699 101 4000 0
X672 88 9 0 2
XQA(12:10)
X6 359 697 72 744 85 4000 0
X720 72 8 0 2
XQA(12:8)
X1 419 720 536 720 560 20 1
X2
X 720 536 720 560
X1 683 288 320 288 336 0 1
X2
X 288 320 288 336
X2 682 288 320 304 336 0 1
X5
X 288 320 296 320 304 328 296 336
X 288 336
X2 686 320 288 336 304 0 1
X5
X 320 288 328 288 336 296 328 304
X 320 304
X2 693 60 396 84 412 0 1
X6
X 60 396 60 404 68 412 76 412
X 84 404 84 396
X1 692 60 396 84 396 0 1
X2
X 60 396 84 396
X1 687 320 288 320 304 0 1
X2
X 320 288 320 304
X1 685 320 264 320 280 0 1
X2
X 320 264 320 280
X1 745 472 376 480 400 0 1
X2
X 480 376 472 400
X1 744 400 376 408 400 0 1
X2
X 400 376 408 400
X1 743 408 400 472 400 0 1
X2
X 408 400 472 400
X1 742 400 376 480 376 0 1
X2
X 400 376 480 376
X1 746 288 360 424 376 20 1
X3
X 288 360 424 360 424 376
X1 747 448 344 448 376 20 1
X2
X 448 344 448 376
X1 748 288 384 400 384 20 1
X2
X 288 384 400 384
X1 749 440 400 440 432 20 1
X2
X 440 400 440 432
X1 750 312 384 312 392 0 1
X2
X 312 392 312 384
X1 751 272 408 308 424 0 1
X3
X 272 424 308 424 308 408
X1 756 316 408 336 424 0 1
X3
X 316 408 316 424 336 424
X1 757 120 256 120 264 0 1
X2
X 120 264 120 256
X1 759 116 304 148 304 0 1
X2
X 116 304 148 304
X1 760 124 280 148 292 0 1
X3
X 124 280 124 292 148 292
X1 762 116 288 116 312 0 1
X2
X 116 312 116 288
X1 763 40 232 112 232 0 1
X2
X 40 232 112 232
X4 764 114 281 120 287 0 1
X117 284 3
X4 765 62 389 68 395 0 1
X65 392 3
X4 768 78 390 84 396 0 1
X81 393 3
X1 769 336 424 344 424 20 1
X2
X 344 424 336 424
X1 770 272 424 280 424 20 1
X2
X 272 424 280 424
X1 771 288 384 296 384 20 1
X2
X 288 384 296 384
X1 772 288 360 296 360 20 1
X2
X 288 360 296 360
X1 773 72 416 72 432 20 1
X2
X 72 416 72 432
X1 774 48 296 56 296 20 1
X2
X 48 296 56 296
X1 780 48 312 56 312 20 1
X2
X 48 312 56 312
X1 781 40 232 80 352 20 1
X6
X 40 232 40 280 56 280 56 352
X 80 352 80 320
X6 171 97 320 112 334 4000 0
X104 320 3 0 3
X'0'
X1 786 80 272 80 320 0 1
X2
X 80 272 80 320
X1 787 96 280 96 312 0 1
X2
X 96 312 96 280
X1 788 80 272 96 280 0 1
X2
X 80 272 96 280
X1 789 56 296 80 296 20 1
X2
X 56 296 80 296
X1 783 80 312 96 320 0 1
X2
X 80 320 96 312
X1 776 44 328 56 328 20 1
X2
X 44 328 56 328
X1 117 104 336 112 336 20 1
X2
X 104 336 112 336
X6 142 61 240 68 254 4000 0
X64 240 1 0 3
X4
X1 790 56 312 80 312 20 1
X2
X 56 312 80 312
X1 792 64 312 64 392 0 1
X2
X 64 312 64 392
X1 793 72 352 80 392 0 1
X4
X 72 352 72 384 80 384 80 392
X6 794 85 280 91 293 4000 0
X88 280 1 0 2
X0
X6 795 85 304 91 317 4000 0
X88 304 1 0 2
X1
X6 796 41 432 104 445 4000 0
X72 432 12 0 2
Ximmediate(1)
X6 173 170 280 214 294 4000 0
X192 280 7 0 3
Xop2.ena
X6 174 167 304 202 318 4000 0
X184 304 6 0 3
XB2.sel
X1 800 160 292 168 292 20 1
X2
X 168 292 160 292
X1 801 156 304 168 304 20 1
X2
X 168 304 156 304
X6 183 415 436 466 450 4000 0
X440 436 8 0 3
XBreq2(5)
X6 167 80 112 113 126 4000 0
X96 112 6 0 3
Xoff.10
X6 819 417 384 423 397 4000 0
X420 384 1 0 2
X1
X6 820 449 384 455 397 4000 0
X452 384 1 0 2
X0
X6 821 445 408 451 421 4000 0
X448 408 1 0 2
X5
X6 822 453 356 459 369 4000 0
X456 356 1 0 2
X5
X6 178 232 328 265 342 4000 0
X248 328 6 0 3
X(SP/i)
X6 823 405 364 411 377 4000 0
X408 364 1 0 2
X5
X1 791 96 232 104 296 0 1
X3
X 96 296 104 296 104 232
X6 179 232 356 281 370 4000 0
X256 356 7 0 3
XQA(4:0)
X6 825 97 248 103 261 4000 0
X100 248 1 0 2
X5
X6 826 86 348 98 361 4000 0
X92 348 2 0 2
XFP
X1 833 16 448 512 464 0 1
X7
X 16 448 24 456 248 456 248 464
X 256 456 504 456 512 448
X1 834 560 392 880 408 0 1
X7
X 560 392 568 400 712 400 720 408
X 728 400 872 400 880 392
X6 835 701 408 740 421 4000 0
X720 408 6 0 2
XFIELD1
X6 836 229 464 268 477 4000 0
X248 464 7 0 2
XFIELD 2
X1 837 576 352 576 384 20 1
X2
X 576 352 576 384
X1 838 496 416 496 440 20 1
X2
X 496 416 496 440
X6 839 566 336 587 349 4000 0
X576 336 4 0 2
Xind1
X6 840 486 400 507 413 4000 0
X496 400 4 0 2
Xind2
END_OF_FILE
if test 17693 -ne `wc -c <'xpic/doc/van.x'`; then
    echo shar: \"'xpic/doc/van.x'\" unpacked with wrong size!
fi
# end of 'xpic/doc/van.x'
fi
if test -f 'xpic/test/van.x' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'xpic/test/van.x'\"
else
echo shar: Extracting \"'xpic/test/van.x'\" \(17693 characters\)
sed "s/^X//" >'xpic/test/van.x' <<'END_OF_FILE'
X5 48 880 621 8
X6 902 392 592 568 609 4000 0
X480 592 25 0 4
XODU - Operand Decode Unit
X6 886 138 584 159 597 4000 0
X148 584 4 0 2
Xind2
X6 887 306 580 327 593 4000 0
X316 580 4 0 2
Xind1
X6 843 45 544 83 557 4000 0
X64 544 8 0 2
Xind2.set
X1 876 148 492 148 508 0 1
X2
X 148 492 148 508
X1 877 140 508 156 508 0 1
X2
X 140 508 156 508
X1 878 308 492 324 508 0 1
X4
X 316 492 316 508 308 508 324 508
X1 879 308 508 324 524 0 1
X3
X 308 508 316 524 324 508
X1 880 140 508 156 524 0 1
X3
X 140 508 148 524 156 508
X4 881 144 525 150 531 0 1
X147 528 3
X4 882 313 521 319 527 0 1
X316 524 3
X1 883 316 528 316 540 20 1
X2
X 316 528 316 540
X1 884 148 532 148 544 20 1
X2
X 148 532 148 544
X1 885 292 540 340 556 0 1
X5
X 296 540 340 540 332 556 300 556
X 292 540
X1 888 124 548 172 564 0 1
X7
X 128 548 172 548 164 564 136 564
X 140 564 132 564 124 548
X1 889 316 556 316 576 20 1
X2
X 316 556 316 576
X1 890 148 564 148 584 20 1
X2
X 148 564 148 584
X1 891 96 532 136 548 20 1
X3
X 96 532 136 532 136 548
X1 892 276 524 300 540 20 1
X3
X 276 524 300 524 300 540
X1 893 276 548 296 548 20 1
X2
X 276 548 296 548
X1 894 92 556 128 556 20 1
X2
X 92 556 128 556
X6 895 41 524 79 537 4000 0
X60 524 8 0 2
Xind2.val
X6 896 233 540 271 553 4000 0
X252 540 8 0 2
Xind1.set
X6 897 229 516 267 529 4000 0
X248 516 8 0 2
Xind1.val
X6 898 324 484 356 497 4000 0
X340 484 5 0 2
XQA(7)
X6 899 108 484 140 497 4000 0
X124 484 5 0 2
XQA(6)
X2 740 304 392 320 408 0 1
X5
X 304 408 304 400 312 392 320 400
X 320 408
X2 741 304 408 320 408 0 1
X2
X 304 408 320 408
X4 731 282 321 286 325 0 1
X284 323 2
X1 729 272 288 276 288 20 1
X2
X 272 288 276 288
X1 728 268 332 276 332 20 1
X2
X 268 332 276 332
X1 727 300 268 324 268 0 1
X2
X 300 268 324 268
X1 726 300 224 404 292 0 1
X4
X 404 224 300 224 300 292 320 292
X1 725 268 276 320 288 0 1
X4
X 268 288 288 288 288 276 320 276
X1 724 272 288 284 324 0 1
X3
X 272 288 272 324 284 324
X1 723 272 332 288 332 0 1
X2
X 272 332 288 332
X1 722 304 300 320 328 0 1
X4
X 304 328 312 328 312 300 320 300
X1 718 336 296 400 320 20 1
X4
X 336 296 360 296 360 320 400 320
X1 717 336 272 400 304 20 1
X4
X 336 272 368 272 368 304 400 304
X1 716 376 240 400 288 20 1
X4
X 400 240 376 240 376 288 400 288
X1 712 384 256 400 336 20 1
X4
X 400 256 384 256 384 336 400 336
X3 702 400 280 480 344 0 1
X6 703 412 328 453 342 4000 0
X432 328 5 0 3
XIBASE
X6 704 440 305 472 319 0 0
X456 312 3 0 3
XROM
X6 705 437 289 476 303 0 0
X456 296 6 0 3
X4X5bit
X6 706 409 313 424 327 0 0
X416 320 2 0 3
XSP
X6 707 408 297 424 311 0 0
X416 304 2 0 3
XFP
X6 708 408 281 425 295 0 0
X416 288 2 0 3
XPC
X2 690 112 264 128 280 0 1
X5
X 112 280 112 272 120 264 128 272
X 128 280
X2 691 112 280 128 280 0 1
X2
X 112 280 128 280
X2 684 320 264 336 280 0 1
X5
X 320 264 328 264 336 272 328 280
X 320 280
X1 654 400 256 408 256 20 1
X2
X 408 256 400 256
X1 651 400 240 408 240 20 1
X2
X 408 240 400 240
X1 650 400 224 408 224 20 1
X2
X 408 224 400 224
X1 649 780 264 788 268 0 1
X2
X 788 264 780 268
X1 648 624 172 628 180 0 1
X2
X 628 172 624 180
X1 647 620 324 628 332 0 1
X2
X 628 324 620 332
X1 646 620 236 628 244 0 1
X2
X 628 236 620 244
X1 645 772 204 784 212 0 1
X2
X 772 212 784 204
X1 644 776 208 780 208 0 1
X2
X 776 208 780 208
X1 643 788 208 796 216 0 1
X2
X 788 216 796 208
X6 641 715 148 750 161 4000 0
X732 148 7 0 2
X(FP/SP)
X6 185 416 232 456 246 4000 0
X436 232 6 0 3
XPC.ena
X6 184 418 216 462 230 4000 0
X440 216 7 0 3
Xop2.ena
X1 638 676 336 680 336 20 1
X2
X 676 336 680 336
X6 637 660 324 676 337 4000 0
X668 324 3 0 2
Xbcc
X6 636 797 216 803 229 4000 0
X800 216 1 0 2
X5
X6 635 765 216 771 229 4000 0
X768 216 1 0 2
X5
X1 604 672 204 680 204 0 1
X2
X 672 204 680 204
X1 375 664 152 664 160 20 1
X2
X 664 152 664 160
X1 583 692 216 692 248 0 1
X3
X 692 248 692 216 692 216
X1 625 832 304 840 304 20 1
X2
X 840 304 832 304
X1 566 592 144 616 144 0 1
X2
X 592 144 616 144
X2 565 592 144 616 160 0 1
X6
X 592 144 592 152 600 160 608 160
X 616 152 616 144
X1 601 600 136 600 144 20 1
X2
X 600 136 600 144
X1 623 828 144 836 144 20 1
X2
X 836 144 828 144
X1 309 808 336 816 352 0 1
X2
X 816 336 808 352
X1 341 792 192 792 240 20 1
X2
X 792 192 792 240
X6 364 776 176 808 190 4000 0
X792 176 3 0 3
XROM
X1 622 720 304 728 304 20 1
X2
X 720 304 728 304
X1 614 728 304 740 304 0 1
X2
X 740 304 728 304
X6 619 692 304 717 317 4000 0
X704 304 5 0 2
X(Bf1)
X6 618 838 288 875 301 4000 0
X856 288 7 0 2
XBf1.ena
X6 615 688 288 720 301 4000 0
X704 288 5 0 2
XQA(7)
X1 613 740 288 740 304 0 1
X2
X 740 288 740 304
X1 612 748 288 748 304 0 1
X2
X 748 304 748 288
X1 611 748 304 832 304 0 1
X2
X 832 304 748 304
X2 610 736 268 752 288 0 1
X5
X 736 288 736 280 744 268 752 280
X 752 288
X1 609 736 288 752 288 0 1
X2
X 736 288 752 288
X1 608 744 248 744 272 0 1
X3
X 744 248 744 272 744 272
X1 607 756 248 767 249 0 1
X2
X 756 249 767 248
X1 606 656 112 712 336 0 1
X9
X 696 112 696 208 712 208 712 264
X 680 264 680 320 656 320 656 336
X 680 336
X6 605 718 232 747 245 4000 0
X732 232 6 0 2
XB1.sel
X1 576 672 200 672 216 0 1
X2
X 672 200 672 216
X1 603 760 248 760 248 20 1
X2
X 760 248 760 248
X6 361 752 160 768 174 4000 0
X760 160 2 0 3
XFP
X1 366 712 104 744 168 0 1
X4
X 744 168 736 168 712 168 712 104
X1 595 600 128 600 144 0 1
X2
X 600 128 600 144
X6 263 549 112 588 125 4000 0
X568 112 8 0 2
XCall.ena
X1 596 576 128 600 128 0 1
X2
X 600 128 576 128
X1 594 604 176 608 176 0 1
X2
X 604 176 608 176
X1 593 604 160 604 176 0 1
X2
X 604 160 604 176
X4 592 692 248 692 248 0 1
X692 248 0
X4 591 693 248 693 248 0 1
X693 248 0
X4 590 693 247 693 247 0 1
X693 247 0
X4 589 693 247 693 247 0 1
X693 247 0
X4 588 670 210 676 216 0 1
X673 213 3
X1 453 608 128 824 128 0 1
X2
X 824 128 608 128
X6 363 773 160 812 174 4000 0
X792 160 6 0 3
X2X5bit
X6 385 709 184 715 197 4000 0
X712 184 1 0 2
X5
X1 585 676 212 692 212 0 1
X2
X 692 212 676 212
X1 584 692 212 692 216 0 1
X3
X 692 212 692 216 692 216
X1 458 640 248 760 272 0 1
X5
X 760 248 672 248 672 272 640 272
X 640 264
X1 449 824 128 832 128 20 1
X2
X 832 128 824 128
X1 579 680 144 832 208 0 1
X3
X 832 144 680 144 680 208
X1 372 696 104 696 112 20 1
X2
X 696 104 696 112
X1 577 640 200 656 208 20 1
X3
X 656 208 640 208 640 200
X2 575 656 200 672 216 0 1
X5
X 672 200 664 200 656 208 664 216
X 672 216
X1 571 732 184 736 184 0 1
X2
X 736 184 732 184
X4 570 727 183 731 187 0 1
X729 185 2
X1 569 720 184 728 192 0 1
X2
X 720 192 728 184
X1 568 720 180 728 184 0 1
X2
X 720 180 728 184
X1 567 720 180 720 192 0 1
X2
X 720 180 720 192
X6 509 563 512 599 526 4000 0
X581 512 7 0 3
Xrti.ena
X1 461 180 76 188 80 0 1
X2
X 180 80 188 76
X1 460 300 72 308 80 0 1
X2
X 300 80 308 72
X1 459 640 264 640 272 20 1
X2
X 640 272 640 264
X1 334 760 240 768 256 0 1
X2
X 768 256 760 240
X1 454 608 128 608 144 0 1
X2
X 608 128 608 144
X6 76 836 136 877 150 4000 0
X856 136 7 0 3
Xopl.ena
X6 75 836 120 877 134 4000 0
X856 120 6 0 3
XCC.ena
X6 443 683 608 853 621 4000 0
X768 608 31 0 2
XSEB=SignExtender+Bufferr output
X6 421 563 488 605 502 4000 0
X584 488 7 0 3
Xsop.ena
X6 422 826 512 871 526 4000 0
X848 512 8 0 3
Xpull.ena
X1 423 632 488 680 536 0 1
X2
X 680 536 632 488
X1 424 760 488 808 536 0 1
X2
X 760 536 808 488
X1 425 680 536 760 536 0 1
X2
X 680 536 760 536
X1 426 776 472 776 488 20 1
X2
X 776 472 776 488
X1 427 744 472 744 488 20 1
X2
X 744 472 744 488
X1 428 712 472 712 488 20 1
X2
X 712 472 712 488
X1 429 664 472 664 488 20 1
X2
X 664 472 664 488
X1 430 632 488 808 488 0 1
X2
X 632 488 808 488
X6 431 655 488 674 502 4000 0
X664 488 3 0 3
Xsop
X6 432 706 488 719 502 4000 0
X712 488 3 0 3
Xrti
X6 433 733 488 755 502 4000 0
X744 488 4 0 3
Xpull
X6 434 763 488 789 502 4000 0
X776 488 4 0 3
Xpush
X6 435 640 456 689 470 4000 0
X664 456 7 0 3
XQA(7:6)
X6 436 699 456 726 470 4000 0
X712 456 4 0 3
X'+1'
X6 437 737 456 752 470 4000 0
X744 456 3 0 3
X'0'
X6 438 767 456 786 470 4000 0
X776 456 4 0 3
X'-2'
X1 439 608 496 640 496 20 1
X2
X 608 496 640 496
X1 440 608 520 664 520 20 1
X2
X 608 520 664 520
X1 441 800 496 824 496 20 1
X2
X 824 496 800 496
X1 442 776 520 824 520 20 1
X2
X 824 520 776 520
X1 389 704 88 704 96 20 1
X2
X 704 88 704 96
X1 388 704 88 704 104 0 1
X2
X 704 88 704 104
X1 384 704 96 776 240 20 1
X4
X 704 96 704 200 776 200 776 240
X1 370 712 96 712 104 20 1
X2
X 712 96 712 104
X1 373 712 168 720 184 0 1
X3
X 720 184 712 184 712 168
X6 377 653 152 659 165 4000 0
X656 152 1 0 2
X4
X6 376 625 136 672 149 4000 0
X648 136 8 0 2
XQA(11:8)
X1 374 736 184 744 184 0 1
X2
X 744 184 736 184
X6 369 717 88 755 101 4000 0
X736 88 6 0 2
XQA(12)
X6 362 753 176 768 190 4000 0
X760 176 2 0 3
XSP
X3 365 744 160 816 192 0 1
X6 73 796 336 804 350 4000 0
X800 336 1 0 3
XF
X1 311 776 352 808 352 0 1
X2
X 776 352 808 352
X1 308 816 128 824 344 20 1
X3
X 824 128 824 344 816 344
X6 283 658 224 670 237 4000 0
X664 224 3 0 2
X'0'
X1 282 648 240 664 240 20 1
X2
X 664 240 648 240
X1 281 648 152 664 168 0 1
X3
X 648 168 664 168 664 152
X6 280 601 384 648 397 4000 0
X624 384 10 0 2
X0ffset1(5)
X6 279 613 296 619 309 4000 0
X616 296 1 0 2
X5
X6 278 621 312 627 325 4000 0
X624 312 1 0 2
X5
X6 277 621 224 627 237 4000 0
X624 224 1 0 2
X5
X6 276 621 160 627 173 4000 0
X624 160 1 0 2
X4
X1 271 640 288 640 304 20 1
X2
X 640 288 640 304
X1 270 608 176 608 376 20 1
X2
X 608 176 608 376
X1 268 608 328 632 328 20 1
X2
X 632 328 608 328
X1 267 608 240 632 240 20 1
X2
X 632 240 608 240
X1 266 608 176 632 176 20 1
X2
X 632 176 608 176
X6 262 725 536 731 549 4000 0
X728 536 1 0 2
X2
X6 227 147 48 206 61 4000 0
X176 48 9 0 2
XQA <17:0>
X6 226 252 48 309 61 4000 0
X280 48 9 0 2
XQB <17:0>
X6 186 416 248 481 262 4000 0
X448 248 9 0 3
XJBASE.ena
X6 182 233 440 263 454 4000 0
X248 440 5 0 3
X(Bf2)
X6 181 229 416 267 430 4000 0
X248 416 5 0 3
XQA(6)
X6 180 239 384 274 398 4000 0
X256 384 6 0 3
XB2.sel
X6 177 229 312 267 326 4000 0
X248 312 5 0 3
XQA(4)
X6 176 235 296 261 310 4000 0
X248 296 4 0 3
X(FP)
X6 175 229 280 267 294 4000 0
X248 280 5 0 3
XQA(5)
X6 170 5 288 43 302 4000 0
X24 288 5 0 3
XQA(3)
X6 169 5 304 43 318 4000 0
X24 304 5 0 3
XQA(4)
X6 168 5 320 43 334 4000 0
X24 320 5 0 3
XQA(5)
X6 119 153 96 167 110 4000 0
X160 96 2 0 3
X10
X1 145 184 64 184 96 0 1
X2
X 184 64 184 96
X6 123 209 96 223 110 4000 0
X216 96 2 0 3
X13
X6 124 261 96 268 110 4000 0
X264 96 1 0 3
X7
X1 115 40 96 312 232 0 1
X3
X 312 96 40 96 40 232
X6 2 140 113 165 127 0 0
X152 120 3 0 3
XSEB
X3 9 136 112 168 128 0 1
X6 132 153 136 167 150 4000 0
X160 136 2 0 3
X30
X1 93 152 128 152 160 20 1
X2
X 152 128 152 160
X6 141 129 240 143 254 4000 0
X136 240 2 0 3
X30
X1 104 128 232 152 232 20 1
X2
X 128 232 152 232
X1 105 120 120 136 120 20 1
X2
X 120 120 136 120
X6 23 116 241 125 255 0 0
X120 248 1 0 3
XB
X6 22 116 225 125 239 0 0
X120 232 1 0 3
XE
X3 27 112 208 128 256 0 1
X6 21 117 209 124 223 0 0
X120 216 1 0 3
XS
X6 160 19 336 45 350 4000 0
X32 336 4 0 3
X(FP)
X1 91 304 96 304 112 20 1
X2
X 304 96 304 112
X6 125 305 96 319 110 4000 0
X312 96 2 0 3
X12
X6 156 361 152 440 166 4000 0
X400 152 12 0 3
Xoffset<17:0>
X6 155 313 72 327 86 4000 0
X320 72 2 0 3
X18
X1 152 304 64 352 112 0 1
X4
X 304 64 304 88 352 88 352 112
X6 148 337 96 351 110 4000 0
X344 96 2 0 3
X18
X6 146 193 72 207 86 4000 0
X200 72 2 0 3
X18
X6 140 129 344 143 358 4000 0
X136 344 2 0 3
X30
X6 139 138 384 199 398 4000 0
X168 384 11 0 3
Xoffset2(30)
X6 138 161 368 175 382 4000 0
X168 368 2 0 3
X30
X1 137 280 120 288 120 20 1
X2
X 280 120 288 120
X1 136 232 120 240 120 20 1
X2
X 232 120 240 120
X1 135 176 120 184 120 20 1
X2
X 176 120 184 120
X6 128 353 136 367 150 4000 0
X360 136 2 0 3
X18
X6 129 305 136 319 150 4000 0
X312 136 2 0 3
X12
X6 131 201 136 215 150 4000 0
X208 136 2 0 3
X30
X6 130 257 136 271 150 4000 0
X264 136 2 0 3
X12
X6 127 382 112 434 126 4000 0
X408 112 9 0 3
X36bit.ena
X1 106 368 120 384 120 20 1
X2
X 384 120 368 120
X1 103 128 336 152 336 20 1
X2
X 128 336 152 336
X1 102 152 160 352 384 20 1
X3
X 352 160 152 160 152 384
X1 101 352 128 352 160 20 1
X2
X 352 128 352 160
X1 100 304 128 304 160 20 1
X2
X 304 128 304 160
X1 95 256 128 256 160 20 1
X2
X 256 128 256 160
X1 94 200 128 200 160 20 1
X2
X 200 128 200 160
X1 90 256 96 256 112 20 1
X2
X 256 96 256 112
X1 89 200 96 200 112 20 1
X2
X 200 96 200 112
X1 88 152 96 152 112 20 1
X2
X 152 96 152 112
X1 87 232 48 232 64 0 1
X2
X 232 48 232 64
X6 66 628 280 669 294 4000 0
X648 280 6 0 3
XCC.ena
X3 81 632 216 648 264 0 1
X3 80 632 152 648 200 0 1
X6 74 783 376 834 390 4000 0
X808 376 8 0 3
XBreq1(5)
X6 68 635 320 646 334 4000 0
X640 320 1 0 3
XU
X6 67 636 304 645 318 4000 0
X640 304 1 0 3
XB
X6 65 636 248 644 262 4000 0
X640 248 1 0 3
XF
X6 64 635 232 646 246 4000 0
X640 232 1 0 3
XU
X6 63 636 216 645 230 4000 0
X640 216 1 0 3
XB
X6 62 636 184 645 198 4000 0
X640 184 1 0 3
XB
X6 61 636 168 645 182 4000 0
X640 168 1 0 3
XE
X6 60 637 152 644 166 4000 0
X640 152 1 0 3
XS
X3 28 112 312 128 360 0 1
X6 26 116 345 124 359 0 0
X120 352 1 0 3
XF
X6 25 115 329 126 343 0 0
X120 336 1 0 3
XU
X6 24 116 313 125 327 0 0
X120 320 1 0 3
XB
X6 20 264 145 297 159 0 0
X280 152 6 0 3
Xoff.30
X6 19 216 145 249 159 0 0
X232 152 6 0 3
Xoff.25
X6 18 160 145 193 159 0 0
X176 152 6 0 3
Xoff.13
X1 17 280 120 288 144 0 1
X3
X 288 120 280 120 280 144
X1 16 232 120 240 144 0 1
X3
X 240 120 232 120 232 144
X1 15 176 120 184 144 0 1
X4
X 184 120 176 120 176 120 176 144
X3 14 336 112 368 128 0 1
X3 13 288 112 320 128 0 1
X3 12 240 112 272 128 0 1
X3 11 184 112 216 128 0 1
X3 10 184 112 184 120 0 1
X3 8 128 48 328 64 0 1
X6 5 292 113 317 127 0 0
X304 120 3 0 3
XSEB
X6 6 338 113 366 127 0 0
X352 120 3 0 3
XBUF
X6 4 244 113 269 127 0 0
X256 120 3 0 3
XSEB
X6 3 188 113 213 127 0 0
X200 120 3 0 3
XSEB
X6 243 754 576 862 590 4000 0
X808 576 21 0 3
Xbefore SP is updated
X6 242 763 560 854 574 4000 0
X808 560 17 0 3
X+1 will be added
X6 241 710 560 746 574 4000 0
X728 560 6 0 3
Xsop(2)
X3 82 632 304 648 352 0 1
X3 315 680 328 752 360 0 1
X6 314 690 344 734 358 4000 0
X712 344 7 0 3
X8X8bits
X6 313 683 328 742 342 4000 0
X712 328 7 0 3
XBCC ROM
X6 143 49 216 112 230 4000 0
X80 216 7 0 3
XQA<3:0>
X6 323 824 472 873 486 4000 0
X848 472 8 0 3
Xpush.ena
X1 332 800 240 808 256 0 1
X2
X 808 240 800 256
X1 333 768 256 800 256 0 1
X2
X 800 256 768 256
X1 331 760 240 808 240 0 1
X2
X 760 240 808 240
X6 339 773 240 780 254 4000 0
X776 240 1 0 3
X1
X6 340 789 240 796 254 4000 0
X792 240 1 0 3
X0
X1 342 784 256 800 336 20 1
X4
X 784 256 784 280 800 280 800 336
X1 316 768 336 816 336 0 1
X2
X 768 336 816 336
X6 346 780 336 789 350 4000 0
X784 336 1 0 3
XT
X1 310 768 336 776 352 0 1
X2
X 768 336 776 352
X1 349 736 320 784 376 20 1
X8
X 736 360 736 376 760 376 760 320
X 784 320 776 320 784 320 784 336
X1 351 792 352 792 376 20 1
X2
X 792 352 792 376
X6 352 749 360 755 373 4000 0
X752 360 1 0 2
X4
X6 353 789 264 795 277 4000 0
X792 264 1 0 2
X5
X6 69 636 336 644 350 4000 0
X640 336 1 0 3
XF
X6 354 685 360 691 373 4000 0
X688 360 1 0 2
X4
X1 356 648 344 696 376 20 1
X5
X 696 360 696 376 664 376 664 344
X 648 344
X6 358 646 88 699 101 4000 0
X672 88 9 0 2
XQA(12:10)
X6 359 697 72 744 85 4000 0
X720 72 8 0 2
XQA(12:8)
X1 419 720 536 720 560 20 1
X2
X 720 536 720 560
X1 683 288 320 288 336 0 1
X2
X 288 320 288 336
X2 682 288 320 304 336 0 1
X5
X 288 320 296 320 304 328 296 336
X 288 336
X2 686 320 288 336 304 0 1
X5
X 320 288 328 288 336 296 328 304
X 320 304
X2 693 60 396 84 412 0 1
X6
X 60 396 60 404 68 412 76 412
X 84 404 84 396
X1 692 60 396 84 396 0 1
X2
X 60 396 84 396
X1 687 320 288 320 304 0 1
X2
X 320 288 320 304
X1 685 320 264 320 280 0 1
X2
X 320 264 320 280
X1 745 472 376 480 400 0 1
X2
X 480 376 472 400
X1 744 400 376 408 400 0 1
X2
X 400 376 408 400
X1 743 408 400 472 400 0 1
X2
X 408 400 472 400
X1 742 400 376 480 376 0 1
X2
X 400 376 480 376
X1 746 288 360 424 376 20 1
X3
X 288 360 424 360 424 376
X1 747 448 344 448 376 20 1
X2
X 448 344 448 376
X1 748 288 384 400 384 20 1
X2
X 288 384 400 384
X1 749 440 400 440 432 20 1
X2
X 440 400 440 432
X1 750 312 384 312 392 0 1
X2
X 312 392 312 384
X1 751 272 408 308 424 0 1
X3
X 272 424 308 424 308 408
X1 756 316 408 336 424 0 1
X3
X 316 408 316 424 336 424
X1 757 120 256 120 264 0 1
X2
X 120 264 120 256
X1 759 116 304 148 304 0 1
X2
X 116 304 148 304
X1 760 124 280 148 292 0 1
X3
X 124 280 124 292 148 292
X1 762 116 288 116 312 0 1
X2
X 116 312 116 288
X1 763 40 232 112 232 0 1
X2
X 40 232 112 232
X4 764 114 281 120 287 0 1
X117 284 3
X4 765 62 389 68 395 0 1
X65 392 3
X4 768 78 390 84 396 0 1
X81 393 3
X1 769 336 424 344 424 20 1
X2
X 344 424 336 424
X1 770 272 424 280 424 20 1
X2
X 272 424 280 424
X1 771 288 384 296 384 20 1
X2
X 288 384 296 384
X1 772 288 360 296 360 20 1
X2
X 288 360 296 360
X1 773 72 416 72 432 20 1
X2
X 72 416 72 432
X1 774 48 296 56 296 20 1
X2
X 48 296 56 296
X1 780 48 312 56 312 20 1
X2
X 48 312 56 312
X1 781 40 232 80 352 20 1
X6
X 40 232 40 280 56 280 56 352
X 80 352 80 320
X6 171 97 320 112 334 4000 0
X104 320 3 0 3
X'0'
X1 786 80 272 80 320 0 1
X2
X 80 272 80 320
X1 787 96 280 96 312 0 1
X2
X 96 312 96 280
X1 788 80 272 96 280 0 1
X2
X 80 272 96 280
X1 789 56 296 80 296 20 1
X2
X 56 296 80 296
X1 783 80 312 96 320 0 1
X2
X 80 320 96 312
X1 776 44 328 56 328 20 1
X2
X 44 328 56 328
X1 117 104 336 112 336 20 1
X2
X 104 336 112 336
X6 142 61 240 68 254 4000 0
X64 240 1 0 3
X4
X1 790 56 312 80 312 20 1
X2
X 56 312 80 312
X1 792 64 312 64 392 0 1
X2
X 64 312 64 392
X1 793 72 352 80 392 0 1
X4
X 72 352 72 384 80 384 80 392
X6 794 85 280 91 293 4000 0
X88 280 1 0 2
X0
X6 795 85 304 91 317 4000 0
X88 304 1 0 2
X1
X6 796 41 432 104 445 4000 0
X72 432 12 0 2
Ximmediate(1)
X6 173 170 280 214 294 4000 0
X192 280 7 0 3
Xop2.ena
X6 174 167 304 202 318 4000 0
X184 304 6 0 3
XB2.sel
X1 800 160 292 168 292 20 1
X2
X 168 292 160 292
X1 801 156 304 168 304 20 1
X2
X 168 304 156 304
X6 183 415 436 466 450 4000 0
X440 436 8 0 3
XBreq2(5)
X6 167 80 112 113 126 4000 0
X96 112 6 0 3
Xoff.10
X6 819 417 384 423 397 4000 0
X420 384 1 0 2
X1
X6 820 449 384 455 397 4000 0
X452 384 1 0 2
X0
X6 821 445 408 451 421 4000 0
X448 408 1 0 2
X5
X6 822 453 356 459 369 4000 0
X456 356 1 0 2
X5
X6 178 232 328 265 342 4000 0
X248 328 6 0 3
X(SP/i)
X6 823 405 364 411 377 4000 0
X408 364 1 0 2
X5
X1 791 96 232 104 296 0 1
X3
X 96 296 104 296 104 232
X6 179 232 356 281 370 4000 0
X256 356 7 0 3
XQA(4:0)
X6 825 97 248 103 261 4000 0
X100 248 1 0 2
X5
X6 826 86 348 98 361 4000 0
X92 348 2 0 2
XFP
X1 833 16 448 512 464 0 1
X7
X 16 448 24 456 248 456 248 464
X 256 456 504 456 512 448
X1 834 560 392 880 408 0 1
X7
X 560 392 568 400 712 400 720 408
X 728 400 872 400 880 392
X6 835 701 408 740 421 4000 0
X720 408 6 0 2
XFIELD1
X6 836 229 464 268 477 4000 0
X248 464 7 0 2
XFIELD 2
X1 837 576 352 576 384 20 1
X2
X 576 352 576 384
X1 838 496 416 496 440 20 1
X2
X 496 416 496 440
X6 839 566 336 587 349 4000 0
X576 336 4 0 2
Xind1
X6 840 486 400 507 413 4000 0
X496 400 4 0 2
Xind2
END_OF_FILE
if test 17693 -ne `wc -c <'xpic/test/van.x'`; then
    echo shar: \"'xpic/test/van.x'\" unpacked with wrong size!
fi
# end of 'xpic/test/van.x'
fi
if test -f 'xpic/x2ps.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'xpic/x2ps.c'\"
else
echo shar: Extracting \"'xpic/x2ps.c'\" \(17849 characters\)
sed "s/^X//" >'xpic/x2ps.c' <<'END_OF_FILE'
X/* $Header: x2ps.c,v 1.7 89/04/21 03:31:57 xwindows Exp $ */
X#include <X11/Xos.h>
X#include <stdio.h>
X#include <pwd.h>
X#include <ctype.h>
X#include <sys/param.h>
X#include "defs.h"
X#include "tune.h"
X/*
X *  This simply reads in xpic format, and emits it (slightly massaged)
X *  with a tagged on PostScript prolog that does most of the work. The
X *  only real work done by this program is for splines which are
X *  converted to bezier curves by some gory math, and arrows which are
X *  computed here by essentially the same algorithm used by xpic
X */
X#define MAXFONTS 127
X#define FONTDESCFILE "x2ps"
X
X#ifndef MAXHOSTNAMELEN
X#define MAXHOSTNAMELEN 64
X#endif
X
X#define PROLOGUE	"x2ps.pro"
X#define TRAILER		"x2ps.tra"
X
X/* PostScript (well, typesetting) constant. Should it be 72.27? */
X#define PPI		72.0	/* 72 (big) points per inch */
X
X#define xtransform(x)	((x) - orgX)
X#define ytransform(y)	((orgY - (y)))
X
Xextern char *malloc();
X
Xstatic int orgX, orgY, picWidth, picHeight;
X
Xstatic int x, y;
X
Xstatic char *halign_words[] = {
X	"ce", "lj", "rj"
X};
X
Xstatic char *progname;
Xstatic int arrow_type = -1;
Xstatic int curStyle = -1;
Xstatic char *curFont = NULL;
Xstatic int curSize = -1;
Xstatic int curWidth = -1;
Xstatic int halign, valign;
Xstatic int showPage = TRUE;
Xstatic int flipcoordinates = FALSE;
Xstatic double hoffset = 0;
Xstatic double voffset = 0;
X#ifdef DEBUG
Xstatic char *prologueFile = PROLOGUE;
Xstatic char *trailerFile = TRAILER;
X#else DEBUG
Xstatic char *prologueFile = NULL;
Xstatic char *trailerFile = NULL;
X#endif DEBUG
X
XFILE *outFile;
XFILE *inFile;
X
Xextern int optind;
Xextern char *optarg;
X
Xstatic void ChangeThickness(t)
X{
X	if (curWidth != t) {
X		curWidth = t;
X		if (curWidth == 0)
X			(void) fprintf(outFile, "0.5 W\n");
X		else
X			(void) fprintf(outFile, "%d W\n", curWidth);
X	}
X}
X
X	
Xstatic void ChangeStyle(style)
X{
X	if ((style < 0) || (style >= NSTYLES)) {
X		(void) fprintf(stderr, "Unknown style - %d\n", style);
X		style = 0;
X	}
X	if (style != curStyle) {
X		(void) fprintf(outFile, "%d D\n", style);
X		curStyle = style;
X	}
X}
X
Xstatic void ChangeFont(font)
Xchar *font;
X{
X	extern char *HashSearch();
X	char *psfont = HashSearch(font);
X	if (psfont == NULL) {
X		(void) fprintf(stderr, "Unavailable font %s\n", font);
X		return;
X	}
X	if (psfont != curFont) {
X		(void) fprintf(outFile, "/%s F\n", psfont);
X		curFont = psfont;
X	}
X}
X
Xstatic void ScaleFont(size)
X{
X	if (size <= 0) {
X		(void) fprintf(stderr, "Incorrect font size %d\n", size);
X		size = 10;
X	}
X	if (size != curSize) {
X		(void) fprintf(outFile, "%d S\n", size);
X		curSize = size;
X	}
X}
X
X
Xstatic void MakeBox(x1, y1, x2, y2, attr)
X{
X	ChangeStyle(getlinestyle(attr));
X	x = xtransform(x1);
X	y = ytransform(y1);
X	(void) fprintf(outFile, "%d %d ", x, y);
X	x = xtransform(x2);
X	y = ytransform(y2);
X	(void) fprintf(outFile, "%d %d b\n", x, y);
X}
X
X
Xstatic void MakeEllipse(xc, yc, xr, yr, attr)
X{
X	ChangeStyle(getlinestyle(attr));
X	x = xtransform(xc);
X	y = ytransform(yc);
X	(void) fprintf(outFile, "%d %d %d %d e\n", xr, yr, x, y);
X}
X
X
X/*
X *  print out a string, escaping '(' and ')' with a \ - we don't escape \, to
X *  give people a mechanism for sending strange numbers to the lw
X */
Xstatic void PrintText(s)
Xchar *s;
X{
X	register char *cp = s;
X
X	for(; *cp != 0; cp++) {
X		if (isascii(*cp) && isprint(*cp)) {
X 			if (*cp != '(' && *cp != ')')
X		 		(void) fputc(*cp, outFile);
X			else
X				(void) fprintf(outFile, "\\%c", *cp);
X		} else {
X			/* Ok - but we're only printing the lower byte! */
X			(void) fprintf(outFile, "\\%o", *cp & 0xff);
X		} 
X	}
X}
X			
X/*ARGSUSED*/
Xstatic void MakeText(s, len, font, size, attr, xc, yc)
Xchar *s;
Xchar *font;
X{
X	ChangeFont(font);
X	ScaleFont(size);
X	halign = gettext_halign(attr);
X	valign = gettext_valign(attr);
X	if ((valign < 0) || (valign >= 3)) {
X		(void) fprintf(stderr, "Incorrect vert alignment %d\n", valign);
X		valign = 0;
X	}
X	if ((halign < 0) || (halign >= 3)) {
X		(void) fprintf(stderr, "Incorrect horiz alignment %d\n", halign);
X		halign = 0;
X	}
X	x = xtransform(xc);
X	y = ytransform(yc);
X	(void) fprintf(outFile, "%d %d m\n(", x, y);
X	PrintText(s);
X	(void) fprintf(outFile, ") %s %d t\n", halign_words[halign], valign);
X}
X	
X
X#define PI 			3.14159265358979323846264338327950288419716939937511
X#define ARROWSIZE	10.
X#define ARROWANGLE	0.46
X
X#define round(x)	((int) ((x) + 0.5))
X
X/*
X *  Draws an arrowhead on the end of the line going from x1, y1 to x2, y2.
X *  It calculates the direction, and draws two lines ARROWSIZE long at
X *  angles of ARROWANGLE to the line.
X */
Xstatic void DrawArrow (x1, y1, x2, y2) 
Xint x1, y1, x2, y2; 
X{
X	double dir, dx, dy, atan2(), cos(), sin();
X
X	dx = (double) (x2 - x1);
X	dy = (double) (y2 - y1);
X	if (dx == 0. && dy == 0.) 
X		return;
X	dir = atan2(dy, dx) + PI;
X
X	/* Arrows should be solid lines, say the critics */
X	(void) fprintf(outFile, "0 D\n");
X	x = x2 + round(ARROWSIZE * cos (dir - ARROWANGLE));
X	y = y2 + round(ARROWSIZE * sin (dir - ARROWANGLE));
X	(void) fprintf(outFile, "%d %d m\n", x, y);
X	(void) fprintf(outFile, "%d %d l\n", x2, y2);
X	x = x2 + round(ARROWSIZE * cos (dir + ARROWANGLE));
X	y = y2 + round(ARROWSIZE * sin (dir + ARROWANGLE));
X	(void) fprintf(outFile, "%d %d l\n", x, y);
X	(void) fprintf(outFile, "%d D\n", curStyle);
X	(void) fprintf(outFile, "%d %d m\n", x2, y2);
X}
X
Xstatic int oldX, oldY;
Xstatic int lastX, lastY;
Xstatic BOOL firstpoint = FALSE;
X
X/*ARGSUSED*/
Xstatic void StartLine(xc, yc, n, attr)
X{
X	int x, y;
X	
X	arrow_type = getlinearrow(attr);
X	if ((arrow_type < 0) || (arrow_type >= 4)) {
X		(void) fprintf(stderr, "Unknown arrow type %d\n", arrow_type);
X		arrow_type = 0;
X	}
X	ChangeStyle(getlinestyle(attr));
X	x = xtransform(xc);
X	y = ytransform(yc);
X	(void) fprintf(outFile, "%d %d m\n", x, y);
X	firstpoint=TRUE;
X	oldX = lastX = x;
X	oldY = lastY = y;
X}
X
X
Xstatic void NextLinePointAt(xc, yc)
X{
X	int x, y;
X	
X	x = xtransform(xc);
X	y = ytransform(yc);
X	if (firstpoint) {
X		if (arrow_type & 0x1) DrawArrow(x, y, oldX, oldY);
X		firstpoint = FALSE;
X	}
X	(void) fprintf(outFile, "%d %d l\n", x, y);
X	oldX = lastX;
X	oldY = lastY;
X	lastX = x;
X	lastY = y;
X}
X
X
Xstatic void EndLine()
X{
X	if (arrow_type & 0x2) DrawArrow(oldX, oldY, lastX, lastY);
X	(void) fprintf(outFile, "x\n");
X}
X
X/*
X *  This takes a set of points for a quadratic B-Spline (passing thru'
X *  all the points and lying within their convex hull, and produces a
X *  PostScript curve using Bezier segments. Mark Moraes, 1987.
X */
X/*ARGSUSED*/
XStartSpline(xc, yc, n, attr)
X{
X	arrow_type = getlinearrow(attr);
X	if ((arrow_type < 0) || (arrow_type >= 4)) {
X		(void) fprintf(stderr, "Unknown arrow type %d\n", arrow_type);
X		arrow_type = 0;
X	}
X	ChangeStyle(getlinestyle(attr));
X	x = xtransform(xc);
X	y = ytransform(yc);
X	(void) fprintf(outFile, "%d %d m\n", x, y);
X	firstpoint=TRUE;
X	oldX = lastX = x;
X	oldY = lastY = y;
X}
X
X
Xstatic void NextSplinePointAt(xc, yc, lastpoint)
X{
X	int x, y;
X	double dX, dY, dX2, dY2;
X	
X	x = xtransform(xc);
X	y = ytransform(yc);
X	if (firstpoint) {
X		if (arrow_type & 0x1) DrawArrow(x, y, oldX, oldY);
X		firstpoint = FALSE;
X	}
X	dX = x - oldX;
X	dY = y - oldY;
X	if (lastpoint) {
X		dX += x - lastX;
X		dY += y - lastY;
X	}
X	dX2 = lastX - oldX;
X	dY2 = lastY - oldY;
X	(void) fprintf(outFile, "%g %g ", dX2 / 3., dY2 / 3.);
X	(void) fprintf(outFile, "%g %g ", (2. * dX2 + dX) / 6.,
X	 (2. * dY2 + dY)/ 6.);
X	(void) fprintf(outFile, "%g %g s\n", dX / 2., dY / 2.);
X	oldX = lastX;
X	oldY = lastY;
X	lastX = x;
X	lastY = y;
X}
X
X
Xvoid EndSpline()
X{
X	if (arrow_type & 0x2) DrawArrow(oldX, oldY, lastX, lastY);
X	(void) fprintf(outFile, "x\n");
X}
X
X	 
X/*
X *  Puts a PostScript prologue from the file 'prologue' to stdout
X *  preceded by a header comment according to Adobe's Structuring
X *  Conventions. 'filename' is the name of the xpic file, and the four
X *  values denote the bounding box of the figure
X */
XWritePrologue(prologue, filename, llx, lly, urx, ury)
Xchar *prologue;
Xchar *filename;
Xdouble llx, lly, urx, ury;
X{
X	FILE *f;
X	char hostname[MAXHOSTNAMELEN];
X	struct passwd *pw;
X	extern time_t time();
X	time_t clock = time((time_t *) 0);
X	char s[BUFSIZ];
X
X	if ((f = fopen(prologue, "r")) == NULL) {
X		(void) fprintf(stderr, "Cannot open prologue file %s\n", prologue);
X		exit(-1);
X	}
X
X	/* The comments section - according to Appendix C in the Red Book */
X	(void) fprintf(outFile, "%%!\n");
X	(void) gethostname(hostname, sizeof(hostname));
X	if ((pw = getpwuid(getuid())) == NULL) 
X		(void) fprintf(stderr, "Cannot get passwd info!");
X	else
X		(void) fprintf(outFile, "%%%%Creator: %s@%s (%s)\n", pw->pw_name,
X 		 hostname, pw->pw_gecos);
X	if (filename != NULL)
X		(void) fprintf(outFile, "%%%%Title: %s (xpic)\n", filename);
X	(void) fprintf(outFile, "%%%%CreationDate: %s", ctime(&clock));
X	/* Only one page pictures allowed */
X	(void) fprintf(outFile, "%%%%Pages: 1\n");
X#if 0
X	/* !! Ouch. */
X	(void) fprintf(outFile, "%%%%DocumentFonts: (atend)\n");
X#endif
X	(void) fprintf(outFile, "%%%%BoundingBox: %g %g %g %g\n", llx, lly,
X	 urx, ury);
X	(void) fprintf(outFile, "%%\t(in inches) at %g %g, width %g, height %g\n",
X	 llx / PPI, lly / PPI, (urx - llx) / PPI, (ury - lly) / PPI);
X	(void) fprintf(outFile, "%%%%EndComments\n");
X
X	/* Now copy the prologue - stdio should be fast enough */
X	while(fgets(s, sizeof(s), f) != NULL)
X		fputs(s, outFile);
X
X	(void) fclose(f);
X
X	(void) fprintf(outFile, "%%%%EndProlog\n");
X}
X
X/*
X *  Put a PostScript trailer on stdout from the file 'trailer' as per
X *  the Structuring Conventions. 
X */
XWriteTrailer(trailer, showpage)
Xchar *trailer;
X{
X	FILE *f;
X	char s[BUFSIZ];
X
X	if ((f = fopen(trailer, "r")) == NULL) {
X		(void) fprintf(stderr, "Cannot open trailer file %s\n", trailer);
X		exit(-1);
X	}
X
X	(void) fprintf(outFile, "%%%%Trailer\n");
X	if (showpage)
X		(void) fprintf(outFile, "showpage\n");
X
X	/* Now copy the trailer - stdio should be fast enough */
X	while(fgets(s, sizeof(s), f) != NULL)
X		fputs(s, outFile);
X
X	(void) fclose(f);
X}
X
X
X
X/*
X *  Read in a file output by xpic, and emit the appropriate PostScript text
X */
Xstatic void convert(land, scale, infilename)
Xdouble scale;
Xchar *infilename;
X{
X	int type;
X	int xc, yc, xr, yr, len, attr;
X	int size;
X	int x1, y1, x2, y2;
X	char *s;
X	char font[MAXSTR];
X	int c, i, n;
X	int err, nf, gs;
X	int num, thickness;
X	int xoff, yoff;
X	double xscale = scale;	/* Allow for grid spacing as well */
X
X#define INPERR 2
X#define INPEOF 3
X
X	err = 0;
X#ifdef MAGIC
X	/* Check for the magic header that the new xpic puts out */
X	if ((c = fgetc(inFile)) == EOF) {
X		(void) fprintf(stderr, "Incorrect input format");
X		return;
X	}
X	(void) ungetc(c, inFile);
X	if (c == '#') {
X		/* Magic header - ignore */
X		(void) fscanf(inFile, "%*[^\n]");
X	}
X#endif MAGIC
X	/* Read in (and ignore) the gel bounding box */
X	(void) fscanf(inFile, " %d %d %d %d %d", &x1, &y1, &x2, &y2, &gs);
X	/* Set up constants for scaling, translation etc. */
X	orgX = x1;
X	/* Take advantage of the already mirrored coordinates if rotating */
X	orgY = (land) ? y1 : y2;
X	picWidth = x2 - x1;
X	picHeight = y2 - y1;
X	/* Convert x and y offsets to xpic units */
X	xoff = hoffset * 10.0 * gs;
X	yoff = voffset * 10.0 * gs;
X	orgX -= xoff;
X	orgY += yoff;
X	/*
X	 *  We need to tell psfig the correct bounding box in points (72
X	 *  points = 1 inch) and xpic has gridspacing * 10 pixels per
X	 *  inch, hence the xscale bit. We also have a possibly
X	 *  user-specified scale to deal with. The actual scaling is
X	 *  done in PostScript - we need to calculate this here only for
X	 *  the bounding box.
X	 */
X	xscale *= PPI / (double) (gs * 10.0);
X	if (land) {
X		WritePrologue(prologueFile, infilename,
X 		 (double) (hoffset * PPI), (double) (voffset * PPI),
X		 (double) (xscale * picHeight), (double) (xscale * picWidth));
X		(void) fprintf(outFile, "land\n");
X	} else {
X		WritePrologue(prologueFile, infilename,
X 		 (double) (hoffset * PPI), (double) (voffset * PPI),
X		 (double) (xscale * picWidth), (double) (xscale * picHeight));
X	}
X	if ((int) scale != 1)
X		(void) fprintf(outFile, "%lg %lg scale\n", scale, scale);
X	(void) fprintf(outFile, "%d ss\n", gs*10);
X	if (flipcoordinates) {
X		/*
X		 * Usually, we move the picture so that the lower left corner
X		 * of the bounding box is at the PostScript page origin (lower
X		 * left corner). If the user specifies the flipcoordinates
X		 * (-w) option, they want the picture as it appeared on the
X		 * screen, so we get PostScript to perform the flip since it
X		 * knows the real pagesize. So we translate the picture to teh
X		 * origin in x2ps, and PostScript translates it back if this
X		 * option is set.
X		 */
X		(void) fprintf(outFile, "getpagesize %d %d flip\n", x1, y2);
X	}
X	/* Read in the actual picture */
X	do {
X		if ((nf = fscanf(inFile, " %d", &type)) != 1) {
X			err = INPEOF;
X			break;
X		}
X		nf = fscanf(inFile, " %d %d %d %d %d %x %d", &num, &x1, &y1, 
X		 &x2, &y2, &attr, &thickness);
X		if (nf != 7) {
X			err = INPERR;
X			break;
X		}
X		ChangeThickness(thickness);
X		switch (type) {
X		case BOX:
X			MakeBox(x1, y1,x2, y2, attr);
X			break;
X		case ELLIPSE:
X			nf = fscanf(inFile, " %d %d %d %d", &xc, &yc, &xr, &yr) ;
X			if (nf != 4) {
X				err = INPERR;
X				break;
X			}
X			MakeEllipse(xc, yc, xr, yr, attr);
X			break;
X		case CIRCLE:
X			nf = fscanf(inFile, " %d %d %d", &xc, &yc, &xr);
X			if (nf != 3) {
X				err = INPERR;
X				break;
X			}
X			MakeEllipse(xc, yc, xr, xr, attr);
X			break;
X		case TEXT:
X			nf = fscanf(inFile, " %d %d %d %s %d", &xc, &yc, &len, font, 
X			 &size);
X			if (nf != 5) {
X				err = INPERR;
X				break;
X			}
X			/*
X			 *  For backward compatibility with the bad old days. The
X			 *  old convention of storing font information was really
X			 *  ugly - a font number from 0-3, (corresponding to Roman,
X			 *  Bolld, Italic, Special) and a size from 0-9
X			 *  (corresponding to point sizes 6 - 24)
X			 */
X			if (font[1] == '\0') {
X				int oldfontconvention = TRUE;
X				
X				switch (font[0]) {
X				case '0':
X					(void) strcpy(font, "Roman");
X					break;
X				case '1':
X					(void) strcpy(font, "Bold");
X					break;
X				case '2':
X					(void) strcpy(font, "Italic");
X					break;
X				case '3':
X					(void) strcpy(font, "Special");
X					break;
X				default:
X					/* Must a new font with a one letter name. Eeep! */
X					oldfontconvention = FALSE;
X				}
X				if (oldfontconvention)
X					/* Convert to pointsize */
X					size = size * 2 + 6;
X			}
X			/* Go to the next line */
X			while ((c = fgetc(inFile)) != '\n' && c != EOF)
X				;
X			if (c == EOF) {
X				err = INPERR;
X				break;
X			}
X			if (( s = malloc((unsigned) (len + 2))) == NULL) {
X				(void) fprintf(stderr, "No more memory for text string");
X				break;
X			}
X			if (fgets(s, len + 1, inFile) == NULL) {
X				free(s);
X				err = INPERR;
X				break;
X			}
X			s[len] = '\0';
X			MakeText(s, len, font, size, attr, xc, yc);
X			free(s);
X			break;
X		case LINE:
X			if (fscanf(inFile, " %d %d %d", &n, &xc, &yc) != 3) {
X				err = INPERR;
X				break;
X			}
X			StartLine(xc, yc, n, attr);
X			for (i = 1; i < n; i++) {
X				if (fscanf(inFile, " %d %d", &xc, &yc) != 2) {
X					err = INPERR;
X					break;
X				}
X				NextLinePointAt(xc, yc);
X			}
X			if (err != INPERR)
X				EndLine();
X			break;
X		case SPLINE:
X			if (fscanf(inFile, " %d %d %d", &n, &xc, &yc) != 3) {
X				err = INPERR;
X				break;
X			}
X			StartSpline(xc, yc, n, attr);
X			for (i = 1; i < n; i++) {
X				if (fscanf(inFile, " %d %d", &xc, &yc) != 2) {
X					err = INPERR;
X					break;
X				}
X				NextSplinePointAt(xc, yc, (i == n - 1));
X			}
X			if (err != INPERR)
X				EndSpline();
X			break;
X		}
X	} while (err == 0);
X	WriteTrailer(trailerFile, showPage);
X	if (err == INPERR)
X		(void) fprintf(stderr, "Incorrect input format");
X
X	return;
X
X#undef INPEOF
X#undef INPERR
X}
X
Xusage(s)
Xchar *s;
X{
X	(void) fprintf(stderr, "\
XUsage: %s [-w] [-r] [-s scale] [-p prologuefile] [-t trailerfile] \n\
X	[-h hoffset] [-v voffset] [-x] [-f maxfonts] [filename]\n", s);
X	exit(-1);
X}
X
X
X/* Font tables are of the form
X	xpic-font-name	PostScript-font-name
X */
Xreadfonttable(file)
Xchar *file;
X{
X	FILE *fp;
X	char xfontname[MAXSTR], psfontname[MAXSTR];
X	char *s1, *s2;
X	extern char *strsave();
X	
X	if ((fp = fopen(file, "r")) == NULL)
X		return;
X	while(fscanf(fp, " %s %s", xfontname, psfontname) == 2) {
X		if ((s1 = strsave(xfontname)) && (s2 = strsave(psfontname)))
X			HashInsert(s1, s2);
X		else {
X			(void) fprintf(stderr, "Out of memory\n");
X			exit(-1);
X		}
X	}
X	(void) fclose(fp);
X}
X
X
Xmain(argc, argv)
Xint argc;
Xchar **argv;
X{
X	int land = FALSE;
X	double scale = 1.0;
X	double atof();
X	int c;
X	int nfonts = MAXFONTS;
X	char fontfile[MAXSTR];
X	char *hdir;
X	char *getenv();
X	
X	progname = argv[0];
X	inFile = stdin;
X	outFile = stdout;
X	while((c = getopt(argc, argv, "wrs:t:p:xf:h:v:")) != EOF) {
X		switch (c) {
X		case 'w':
X			flipcoordinates = TRUE;
X			break;
X		case 'r':
X			land = TRUE;
X			break;
X		case 's':
X			scale = atof(optarg);
X			break;
X		case 'p':
X			prologueFile = optarg;
X			break;
X		case 't':
X			trailerFile = optarg;
X			break;
X		case 'x':
X			/* Pronounce this 'Ech' to rhyme with TeX! */
X			showPage = !showPage;
X			break;
X		case 'f':
X			nfonts = atoi(optarg);
X			break;
X		case 'h':
X			hoffset = atof(optarg);
X			break;
X		case 'v':
X			voffset = atof(optarg);
X			break;
X		case '?':
X			usage(progname);
X			break;
X		}
X	}
X
X	HashInit(nfonts);
X	(void) sprintf(fontfile, "%s/fontdesc/%s", LIBDIR, FONTDESCFILE);
X	readfonttable(fontfile);
X	if (hdir = getenv("HOME")) {
X		(void) sprintf(fontfile, "%s/.%s", hdir, FONTDESCFILE);
X		readfonttable(fontfile);
X	}
X	if (!prologueFile) {
X		prologueFile = malloc(sizeof(PROLOGUE) + sizeof(LIBDIR));
X		(void) sprintf(prologueFile, "%s/%s", LIBDIR, PROLOGUE);
X	}
X
X	if (!trailerFile) {
X		trailerFile = malloc(sizeof(TRAILER) + sizeof(LIBDIR));
X		(void) sprintf(trailerFile, "%s/%s", LIBDIR, TRAILER);
X	}
X
X	/* Must have some files */
X	if (optind >= argc) {
X		convert(land, scale, "stdin");
X	} else {
X		while (optind < argc) {
X			if ((inFile = fopen(argv[optind], "r")) == NULL) {
X				(void) fprintf(stderr, "Can't open %s for reading\n", 
X				 argv[optind]);
X				break;
X			}
X			outFile = stdout;
X			convert(land, scale, argv[optind]);
X			optind++;
X		}
X	}
X}
END_OF_FILE
if test 17849 -ne `wc -c <'xpic/x2ps.c'`; then
    echo shar: \"'xpic/x2ps.c'\" unpacked with wrong size!
fi
# end of 'xpic/x2ps.c'
fi
echo shar: End of archive 12 \(of 15\).
cp /dev/null ark12isdone
MISSING=""
for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ; do
    if test ! -f ark${I}isdone ; then
	MISSING="${MISSING} ${I}"
    fi
done
if test "${MISSING}" = "" ; then
    echo You have unpacked all 15 archives.
    rm -f ark[1-9]isdone ark[1-9][0-9]isdone
else
    echo You still need to unpack the following archives:
    echo "        " ${MISSING}
fi
##  End of shell archive.
exit 0



More information about the Comp.sources.x mailing list