rsalz@uunet.UU.NET (Rich Salz) (11/09/87)
Submitted-by: Crispin Goswell <caag@vd.rl.ac.uk> Posting-number: Volume 12, Issue 63 Archive-name: postscript/part14 #! /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 14 (of 18)." PATH=/bin:/usr/bin:/usr/ucb ; export PATH if test -f 'postscript/fonts/Olde/italic.r' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'postscript/fonts/Olde/italic.r'\" else echo shar: Extracting \"'postscript/fonts/Olde/italic.r'\" \(18559 characters\) sed "s/^X//" >'postscript/fonts/Olde/italic.r' <<'END_OF_FILE' XCharStrings X/3301 X<C336 X4437 X4338 X4237 X4335 X4534 X4734 X4935 X4A36 X4B39 X4B3D X4A40 X4842 X4643 X4344 XC936 X4A39 X4A3E X4940 XC734 X4835 X4938 X493E X4841 X4643 XC644 X4947 XC544 X4948 XC344 X4849 X4F44 XD635 X5536 X5636 X5635 X5534 X5334 X5135 X5036 X4F38 X4F47 X5149 X5545 XD136 X5038 X5046 X5248 XD334 X5235 X5138 X5145 X5347 X> Xput XMetrics X/3301 X[0 X24] Xput XCharStrings X/3302 X<C23F X4240 X4341 X4541 X4740 X473D X463B X4438 X4436 X4634 XC63D X4439 XC541 X4640 X463E X443B X4339 X4337 X4435 X4634 X4934 X4B35 X4C36 X4D38 X4D40 X4C43 X4A45 XCB36 X4C38 X4C42 XC934 X4A35 X4B38 X4B43 X4A45 XCD37 X4E35 X5034 X5234 X5435 X5536 X5638 X5739 XD436 X5538 XD234 X5335 X5438 X5539 X5739 XD739 X4D3E XD43B X563D X5740 X5743 X5646 X5448 X5149 X4E49 X4B48 X4545 X4445 X4346 XD33C X543C X563E XD13C X543D X563F X5741 XCF48 X4D48 X4745 X4645 XD547 X5348 X5048 X4D47 X4945 X4644 X4444 X4346 X4348 X4449 X4548 X4447 X> Xput XMetrics X/3302 X[-1 X26] Xput XCharStrings X/3303 X<CC36 X4A34 X4834 X4635 X4438 X433C X4340 X4444 X4647 X4848 X4B49 X4E49 X5148 X5347 X5545 XC636 X4538 X443B X4440 X4544 X4747 X4A48 XC834 X4735 X4637 X453B X453F X4643 X4745 X4947 X4C48 X4F48 X5247 X5545 XCF34 X4C36 X4B37 X4A39 X4A3A X4B3C X4E3E X4F40 X4F42 XCB39 X4B3A X4F3E X4F3F XCB37 X4B38 X4C3A X4F3C X503E X5040 X4F42 X4D43 X4C43 X4A42 X4940 XCF34 X5035 X5236 X5436 XCF35 X5036 X5136 XCE35 X5037 X5237 X5436 X5535 X> Xput XMetrics X/3303 X[0 X24] Xput XCharStrings X/3304 X<C33A X4339 X4437 X4635 X4934 X4D34 X5035 X5236 X5438 X563B X573F X5743 X5646 X5448 X5149 X4E49 X4B48 X4545 X4445 X4346 XC636 X4835 X4D35 X5036 X5237 X5439 X563C XCF48 X4D48 X4745 X4645 XC339 X4537 X4836 X4D36 X5037 X5238 X543A X563D X5740 XD547 X5348 X5048 X4D47 X4945 X4644 X4444 X4346 X4348 X4449 X4548 X4447 XCB36 X4839 X473B X473D X4941 X4943 XC83C X483D X493F X4940 XC839 X483B X4A3F X4A41 X4943 X4844 X4644 X4543 X4542 X> Xput XMetrics X/3304 X[-1 X26] Xput XCharStrings X/3305 X<CC36 X4A34 X4834 X4635 X4438 X433C X4340 X4444 X4647 X4848 X4B49 X4E49 X5148 X5347 X5545 XC636 X4538 X443B X4440 X4544 X4747 X4A48 XC834 X4735 X4637 X453B X453F X4643 X4745 X4947 X4C48 X4F48 X5247 X5545 XCF34 X4C36 X4B37 X4A39 X4A3A X4B3C X4E3E X4F40 X4F42 XCB39 X4B3A X4F3E X4F3F XCB37 X4B38 X4C3A X4F3C X503E X5040 X4F42 X4D43 X4C43 X4A42 X4940 XCF34 X5035 X5236 X5436 XCF35 X5036 X5136 XCE35 X5037 X5237 X5436 X5535 XCF3C X5339 XD339 X543A X563A XD23A X533B X543B XD13B X523C X543C X563A X> Xput XMetrics X/3305 X[0 X24] Xput XCharStrings X/3306 X<C73C X453B X4439 X4437 X4535 X4834 X4B34 X4E35 X5237 XC536 X4735 X4C35 X4F36 XC439 X4537 X4736 X4C36 X5237 X5437 X5536 X5535 X5434 X5334 XCD36 X4C37 X4B39 X4B3B X4C3D X5041 X5144 X5147 X504A X4F4B X4D4C XCE3E X5141 X5244 X5247 X5149 XCB3B X4D3D X503F X5241 X5344 X5347 X5249 X504B X4D4C X494C X464B X454A X4448 X4445 X4642 X4640 X453F XC64A X4549 X4545 X4643 XC94C X474B X4649 X4645 X4742 X4740 X463F X443F X4340 X4341 XCF3E X533A XD33A X543B X563B XD23B X533C X543C XD13C X523D X543D X563B X> Xput XMetrics X/3306 X[0 X24] Xput XCharStrings X/3307 X<D038 X4F36 X4E35 X4C34 X4934 X4635 X4438 X433C X4340 X4443 X4545 X4747 X4948 X4C49 X4F49 X5248 X5447 X5645 X5742 X573F X563C X543A XC636 X4538 X443B X4440 X4543 X4645 XD545 X5643 X563F X553C X543B XC934 X4735 X4637 X453B X4540 X4644 X4746 X4948 XD248 X5446 X5543 X553F X543D X523B XD034 X4D36 X4B38 X4A3A X4A3B X4B3D X4E3F X4F41 X4F43 XCB3A X4B3B X4F3F X4F40 XCB38 X4B39 X4C3B X4F3D X503F X5041 X4F43 X4D44 X4C44 X4A43 X4941 XCF3D X543A X5538 XD734 X5538 XD435 X5837 XD734 X5635 X5435 X5536 X5538 X5637 X5837 X5736 X5734 X> Xput XMetrics X/3307 X[-1 X26] Xput XCharStrings X/3308 X<CC34 X4A35 X4837 X4739 X473B X483D X4A3F X4B41 X4B43 XC83A X483B X4B3F X4B40 XC837 X4839 X493B X4B3D X4C3F X4C41 X4B43 X4A44 X4845 X4645 X4444 X4343 X4241 X423F X433E X443F X4340 XCC34 X4E36 X5036 X5235 XCB35 X4D36 XCA35 X4B36 X4D37 X4F37 X5235 XCC3E X5339 XD339 X553C X563F X5642 X5545 X5347 X5048 X4C49 XD23A X543C X553F X5543 X5445 XD03B X513B X533D X5440 X5444 X5346 X5247 X5048 XD048 X4E48 X4C47 X4A47 X4848 X474A X484C X4A4D X4C4D X4E4C XCD48 X4B48 XCC49 X4A48 X4848 X> Xput XMetrics X/3308 X[0 X25] Xput XCharStrings X/3309 X<CA3E X483E X463D X453C X443A X4438 X4536 X4635 X4934 X4B34 X4E35 X5138 X5339 XC636 X4835 X4C35 X4E36 X4F37 XC438 X4537 X4736 X4B36 X4E37 X5038 X5339 X5539 X5638 X5636 X5535 X5335 XC446 X4547 X4448 X4347 X4345 X4444 X4644 X4845 X4A47 X4C4A X4E4C XC846 X4947 X4B4A X4C4B XC644 X4745 X4847 X4A4A X4B4B X4D4C X504C X524B X534A X5448 X5445 X5343 X5140 X503E X503D XD346 X5345 X5040 X503F XD24B X5349 X5347 X5245 X5042 X4F40 X4F3E X513C X533C X543D X543E X> Xput XMetrics X/3309 X[0 X25] Xput XCharStrings X/3310 X<CA3E X483E X463D X453C X443A X4438 X4536 X4635 X4934 X4B34 X4E35 X5138 X5339 XC636 X4835 X4C35 X4E36 X4F37 XC438 X4537 X4736 X4B36 X4E37 X5038 X5339 X5539 X5638 X5636 X5535 X5335 XC446 X4547 X4448 X4347 X4345 X4444 X4644 X4845 X4A47 X4C4A X4E4C XC846 X4947 X4B4A X4C4B XC644 X4745 X4847 X4A4A X4B4B X4D4C X504C X524B X534A X5448 X5445 X5343 X5140 X503E X503D XD346 X5345 X5040 X503F XD24B X5349 X5347 X5245 X5042 X4F40 X4F3E X513C X533C X543D X543E X> Xput XMetrics X/3310 X[0 X25] Xput XCharStrings X/3311 X<D639 X5537 X5335 X5034 X4D34 X4A35 X4837 X4739 X473C X483F X4B45 X4B47 X4949 XC83C X483D X4B43 X4B44 XC936 X4838 X483B X493D X4B41 X4C44 X4C46 X4B48 X4949 X4749 X4548 XC344 X4548 XC247 X4645 XC344 X4346 X4247 X4447 X4548 X4546 X4645 X4445 X4344 XC93D X493B X4A39 X4C38 X4F38 X5139 X533B X543B XD039 X523B XCD38 X4F39 X503A X513C XD43B X4B3F XD03D X5446 X5547 X5647 XCF3E X5346 X5548 XCE3E X5247 X5449 X5746 X> Xput XMetrics X/3311 X[-1 X26] Xput XCharStrings X/3312 X<D341 X5242 X4F42 X4E41 X4E3F X4F3D X513A X5238 X5236 XCF3F X4F3E X523A X5239 XD042 X4F41 X4F40 X503E X523C X533A X5338 X5236 X5135 X4E34 X4934 X4635 X4536 X4438 X443A X453C X473F X4841 X4842 X4744 XC539 X453A X483F X4840 XC536 X4538 X463A X483D X493F X4941 X4843 X4645 X4347 XC645 X4845 X4B47 X4E48 X5148 X5347 XC746 X4846 X4C48 X4D48 XC347 X4546 X4646 X4A48 X4D49 X4F49 X5248 X5347 X5445 X> Xput XMetrics X/3312 X[1 X23] Xput XCharStrings X/3313 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4934 X4B35 X4D37 X4E3A X4E40 X4D43 X4C45 X4A47 X4749 X4648 X4548 XCC37 X4D3A X4D40 X4C43 X4B45 XC848 X4747 X4647 XC934 X4B36 X4C39 X4C40 X4B44 X4A46 X4947 X4846 X4746 X4449 XCC35 X4E34 X5034 X5235 X5437 X553A X5540 X5443 X5345 X5147 X4F49 X4E48 X4D48 XD337 X543A X5440 X5344 XD048 X4F47 X4E47 XD034 X5236 X5339 X5341 X5245 X5147 X5046 X4F46 X4C49 XD336 X5435 X5634 X5834 X5A35 X5B36 X5C38 X5D39 XDA36 X5B38 XD834 X5935 X5A38 X5B39 X5D39 XDD39 X5A3B X593C X583F X5842 X5946 X5B49 X5E46 XDA3C X593E X5942 X5A45 X5C48 XDD39 X5B3B X5A3D X5A41 X5B45 X5D47 X> Xput XMetrics X/3313 X[-3 X32] Xput XCharStrings X/3314 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4A34 X4C35 X4E37 X4F3A X4F40 X4E43 X4D45 X4B47 X4849 X4748 X4548 X4349 XCD37 X4E39 X4E40 X4D43 X4C45 X4B46 XC948 X4747 X4547 XCA34 X4C36 X4D39 X4D40 X4C44 X4A47 X4846 X4646 X4349 XCE36 X4F35 X5134 X5334 X5535 X5636 X5738 X5839 XD536 X5638 XD334 X5435 X5538 X5639 X5839 XD839 X553B X543C X533F X5342 X5446 X5649 X5946 XD53C X543E X5442 X5545 X5748 XD839 X563B X553D X5541 X5645 X5847 X> Xput XMetrics X/3314 X[-2 X28] Xput XCharStrings X/3315 X<CC34 X4A35 X4837 X4739 X473B X493F X4941 XC83A X483B X493D X493E XC837 X4839 X4A3D X4A3F X4941 X4842 X4642 X4541 X4540 XCC34 X4D35 X5337 X5639 X573B X583E X5841 X5744 X5646 X5448 X5149 X4E49 X4B48 X4545 X4445 X4346 XCC35 X4D36 X5338 X5539 X563A XCC34 X4C36 X4D37 X5339 X553A X573C X583E XCF48 X4D48 X4745 X4645 XD547 X5348 X5048 X4D47 X4945 X4644 X4444 X4346 X4348 X4449 X4548 X4447 X> Xput XMetrics X/3315 X[-2 X28] Xput XCharStrings X/3316 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4A34 X4C35 X4D36 X4E38 X4E43 XCE45 X4E4A X4D4C X4B4D X484D X474C X474A X4849 X494A X484B XCC36 X4D38 X4D4A X4C4C XCA34 X4B35 X4C38 X4C43 XCC45 X4C4A X4B4C X4A4D XCE38 X5334 XD334 X5537 X5639 X573D X5740 X5643 X5446 X5149 XD235 X5539 X563C X563D XD136 X5338 X553B X563E X5641 X5544 X5446 XD247 X5044 X4E43 XCC43 X4A44 X4846 XD248 X5045 X4E44 X4B44 XD149 X4F46 X4E45 XCC45 X4A45 X4846 X> Xput XMetrics X/3316 X[-1 X27] Xput XCharStrings X/3317 X<CC34 X4A35 X4837 X4739 X473B X493F X4941 XC83A X483B X493D X493E XC837 X4839 X4A3D X4A3F X4941 X4842 X4642 X4541 X4540 XCC34 X4D35 X5337 X5639 X573B X583E X5841 X5744 X5646 XD448 X5149 X4E49 X4B48 X4545 X4445 X4346 XCC35 X4D36 X5338 X5539 X563A XCC34 X4C36 X4D37 X5339 X553A X573C X583E XCF48 X4D48 X4745 X4645 XD448 X5048 X4D47 X4945 X4644 X4444 X4346 X4348 X4449 X4548 X4447 XD046 X5244 X5444 X5848 X5948 XD345 X5445 X5748 XD145 X5245 X5649 X5849 X5A47 X> Xput XMetrics X/3317 X[-2 X28] Xput XCharStrings X/3318 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4A34 X4C35 X4D36 X4E38 X4E44 X4D46 X4B48 X4949 X4749 X4548 XCC36 X4D38 X4D44 X4C46 XCA34 X4B35 X4C38 X4C44 X4B47 X4949 XC344 X4548 XC247 X4645 XC344 X4346 X4247 X4447 X4548 X4546 X4645 X4445 X4344 XCE37 X4F35 X5134 X5334 X5535 X5636 X5738 X5839 XD536 X5638 XD334 X5435 X5538 X5639 X5839 XD839 X4E3E XD03D X5447 X5649 X5946 XD13D X5546 X5748 XD23C X5646 X5747 X5847 X> Xput XMetrics X/3318 X[-2 X28] Xput XCharStrings X/3319 X<D736 X5635 X5734 X5835 X5837 X5739 X5539 X5137 X4E36 X4A36 X4637 X4439 XD438 X5136 X4E35 X4A35 X4736 XD837 X5738 X5538 X5135 X4E34 X4A34 X4735 X4537 X4439 X433C X4340 X4443 X4545 X4747 X4948 X4C49 X5049 X5348 X5547 X5745 X5842 X583F X573D X553C X523C X503D X4E40 X4C41 X4A41 XC746 X4947 X4C48 X5048 X5447 XC443 X4645 X4846 X4B47 X5047 X5446 X5645 X5744 X5842 XD33D X523D X4E41 X4D41 XD83F X563D X543D X523E X5041 X4E42 X4C42 X4A41 X493F X493D X4A3B X4C3A X> Xput XMetrics X/3319 X[-1 X27] Xput XCharStrings X/3320 X<C63C X443B X4339 X4337 X4435 X4734 X4C34 X4F35 X5338 X5538 X5637 XC436 X4635 X4C35 X4F36 X5238 XC339 X4437 X4636 X4C36 X4F37 X5339 X5539 X5637 X5635 X5534 X5435 X5536 XCF37 X4C3A X4B3C X4B3E X4D42 X4D44 XCC3D X4C3E X4D40 X4D41 XCC3A X4C3C X4E40 X4E42 X4D44 X4C45 X4A45 X4944 X4942 XC447 X4548 X4449 X4348 X4346 X4444 X4644 X4945 X4D47 X5048 X5348 X5547 XC645 X4745 X4D48 X4F48 XC346 X4445 X4545 X4746 X4B48 X4E49 X5149 X5448 X5646 X> Xput XMetrics X/3320 X[0 X25] Xput XCharStrings X/3321 X<C336 X4436 X4537 X4545 X4346 XC435 X4636 X4646 X4948 XC237 X4534 X4736 X4745 X4947 X4B47 XC346 X4446 X4647 X4849 X4B47 X4F44 XCD36 X4E36 X4F37 X4F47 X5149 X5446 XCE35 X5036 X5047 X5248 XCC37 X4F34 X5236 X5137 X5146 X5247 X5347 X> Xput XMetrics X/3321 X[1 X22] Xput XCharStrings X/3322 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4A34 X4C35 X4D36 X4E38 X4E40 X4D43 X4B45 XCC36 X4D38 X4D42 XCA34 X4B35 X4C38 X4C43 X4B45 XCE37 X4F35 X5134 X5334 X5535 X5738 X5839 XD536 X5638 XD334 X5435 X5538 X5639 X5839 XD639 X5439 X533A X533C X543E X5740 X5842 XD43D X573F XD33B X543C X573E X5840 X5844 X5746 X5548 X5349 X4F49 X4C48 X4645 X4545 X4446 XD048 X4E48 X4845 X4745 XD647 X5448 X5148 X4E47 X4A45 X4744 X4544 X4446 X4448 X4549 X4648 X4547 X> Xput XMetrics X/3322 X[-2 X28] Xput XCharStrings X/3323 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4A34 X4C35 X4D36 X4E38 X4E3C X4D3F X4B42 X4944 XCC36 X4D38 X4D3D X4C40 XCA34 X4B35 X4C38 X4C3D X4B41 X4944 XCC35 X4E34 X5134 X5335 XD534 X5235 X5137 X513B X523E X5441 X5543 X5545 X5447 XD23B X523C X5541 X5542 XD534 X5335 X5237 X523A X533C X553F X5642 X5644 X5546 X5348 X5149 X4D49 X4B48 X4946 X4745 X4545 X4446 XCC48 X4945 X4845 XCF49 X4D48 X4A45 X4844 X4544 X4446 X4448 X4549 X4648 X4547 XD534 X5834 X5A35 X5C38 X5D39 XDA36 X5B38 XD834 X5935 X5A38 X5B39 X5D39 XDB39 X5939 X583A X583C X593E X5C40 X5D42 XD93D X5C3F XD83B X593C X5C3E X5D40 X5D45 X5C47 X5B48 X5949 X5649 X5348 XD748 X5648 X5447 XDC47 X5A48 X5848 X5647 X5546 X> Xput XMetrics X/3323 X[-3 X33] Xput XCharStrings X/3324 X<C536 X4736 X4937 X4A38 X4B3B X4B3D XCB3F X4B43 X4A46 X4749 X4548 X4349 XC848 X4647 X4547 XC947 X4847 X4646 X4349 XC735 X4A36 X4B37 X4C3A X4C43 X4D45 X4F47 X5148 XC337 X4834 X4A35 X4C37 X4D3A X4D3D XCD3F X4D42 X4E45 X4F46 X5147 X5347 XCB43 X4C46 X4E48 X5049 X5546 XCD3A X4E37 X5134 X5335 X5534 XD035 X5236 X5336 XCF36 X5036 X5237 X5534 XC541 X473D X4B3D XCD3D X513D X533B XC73E X513E XC541 X473F X4B3F XCD3F X513F X533B X> Xput XMetrics X/3324 X[0 X24] Xput XCharStrings X/3325 X<C33F X4340 X4441 X4641 X4840 X483D X473B X4538 X4536 X4734 XC73D X4539 XC641 X4740 X473E X453B X4439 X4437 X4535 X4734 X4A34 X4C35 X4D36 X4E38 X4E3D X4D40 X4C42 X4C43 X4E45 X4F45 XCC36 X4D38 X4D3E X4C41 X4B43 X4E46 XCA34 X4B35 X4C38 X4C3E X4B42 X4A44 X4D47 X5044 XCE38 X5634 XD435 X5448 X534B XD535 X5546 X5449 XD634 X5644 X5548 X544A X524C X4F4D X4B4D X484C X464A X4548 X4647 X4748 X4649 X> Xput XMetrics X/3325 X[-1 X26] Xput XCharStrings X/3326 X<C837 X4935 X4B34 X4E34 X5035 X5136 X5238 X523B X513D X503E X4E3F XCB3F X493E X483C XD036 X5137 X513C X503D XCE34 X4F35 X5037 X503C X4F3E X4E3F XC743 X4841 X4940 X4B3F X4E3F X5140 X5342 X5444 X5448 X534A X514C X4E4D X4A4D X484C X4548 X4447 XD242 X5344 X5348 X524A XCE3F X5141 X5243 X5249 X514B X504C X4E4D XC94C X484B X4648 X4547 XCC4D X4A4C X494B X4748 X4647 X4347 X4248 X424A X434B X444B X> Xput XMetrics X/3326 X[0 X24] Xput XCharStrings X/3401 X<CA3B X473C X453D X443E X4341 X4344 X4447 X4549 X4B46 XC444 X4547 X4648 XC73C X453E X4441 X4443 X4546 X4748 XC83C X493D X4B3E X4B47 X4D49 X5046 XC93C X4C3E X4C46 X4E48 XCA3B X4B3C X4D3D X4E3D XCD3E X4E3D XCD3E X4D46 X4E47 X4F47 X> Xput XMetrics X/3401 X[-3 X17] Xput XCharStrings X/3402 X<C236 X4337 X4439 XCA34 X4735 X4537 X4439 X4446 X4347 XC637 X4539 X4546 X4848 XCA34 X4835 X4736 X4639 X4646 X4847 X4948 XC347 X4447 X4648 X4749 X4A48 XC63E X4C3B X4D3D X4E40 X4E43 X4D46 X4C47 X4A48 XCB3C X4C3D X4D3F XCA3C X4C3E X4D41 X4D43 X4C46 X4A48 X> Xput XMetrics X/3402 X[4 X17] Xput XCharStrings X/3403 X<C73C X493E X4B3D X493B X473C X443E X4340 X4345 X4447 X4649 X4A47 XC83C X4A3D XC53E X4440 X4445 X4547 X4648 XC63D X453F X4544 X4646 X4848 X> Xput XMetrics X/3403 X[-2 X13] Xput XCharStrings X/3404 X<C734 X4437 X4439 X453A X493C X4C3E X4D40 X4D43 X4C46 X4A48 XC538 X4539 X493B X4C3D X4D3E XC536 X4537 X4638 X4B3B X4D3D X4E40 X4E43 X4D46 X4A48 X4749 XC83C X443E X4446 X4347 XC53E X4546 X4848 XC63D X4646 X4847 X4948 XC347 X4447 X4648 X4749 X> Xput XMetrics X/3404 X[4 X17] Xput XCharStrings X/3405 X<C543 X4B3F X483B X443E X4340 X4345 X4447 X4649 X4A47 XCA3F X473C XC53E X4440 X4445 X4547 X4648 XC940 X473D X463D X453F X4544 X4646 X4848 X> Xput XMetrics X/3405 X[-2 X13] Xput XCharStrings X/3406 X<CC34 X4B35 X4935 X4734 X4534 X4436 X443B X433D X423E XCA36 X4836 X4635 X4535 XCC34 X4B36 X4A37 X4837 X4636 X4536 X4437 XC439 X453B X463C X483D X4A3D X4A3E XC23E X443E XC63E X4A3E XC43E X4442 X454E XC73D X443D X453C X4549 XC63E X4642 X454E X> Xput XMetrics X/3406 X[6 X13] Xput XCharStrings X/3407 X<CA3B X473C X453D X443E X4341 X4344 X4447 X4549 X4B46 XC445 X4547 X4648 XC73C X453E X4441 X4443 X4546 X4748 XC83C X493D X4B3E X4B46 X4C49 X4C4B X4B4D XC93C X4C3E X4C48 XCA3B X4B3C X4D3D X4E3D XCD3E X4E3D XCD3E X4D4A X4C4C X4B4D X494E X464E X444D X434C X434B X444B X444C X> Xput XMetrics X/3407 X[-3 X17] Xput XCharStrings X/3408 X<C236 X4337 X4439 XCA34 X4735 X4537 X4439 X4446 X4347 XC637 X4539 X4547 X4648 XCA34 X4835 X4736 X4639 X4646 X4747 X4847 XC347 X4548 X4649 X4946 XC63E X4C3B X4D3D X4E41 X4E45 X4D48 X4C4A X4A4C X474E XCB3C X4C3D X4D40 XCA3C X4C3F X4D42 X4D45 X4C49 X4A4C X> Xput XMetrics X/3408 X[4 X17] Xput XCharStrings X/3409 X<C534 X4435 X4436 X4537 X4636 X4635 X4534 XC435 X4636 XC436 X4635 XC23D X433D X443E X4447 X4649 X4946 XC33C X453D X4546 X4748 XC13E X443B X453C X473D XC63E X473D XC63E X4646 X4747 X4847 X> Xput XMetrics X/3409 X[7 X10] Xput XCharStrings X/3410 X<C534 X4435 X4436 X4537 X4636 X4635 X4534 XC435 X4636 XC436 X4635 XC23D X433D X443E X4449 X434C X424D X404E XC33C X453D X4549 X444B XC13E X443B X453C X473D XC63E X473D XC63E X4649 X454B X434D X404E XC649 X474B X484C X> Xput XMetrics X/3410 X[7 X10] Xput XCharStrings X/3411 X<C336 X4437 X4539 XCA34 X4835 X4637 X4539 X453B X443D X433E XC53E X4546 X4447 XC737 X4639 X463B XC63D X453D X463B X4646 X4848 XCA34 X4836 X4739 X473D XC73E X4746 X4847 X4947 XC447 X4648 X4749 X4A46 XC73A X4B37 X4C38 X4C3A X4A3C X483D XCA38 X4B39 X4B3A X4A3C XC73D X4C3D X4C3E XC33E X453E XC73E X4C3E X> Xput XMetrics X/3411 X[5 X14] Xput XCharStrings X/3412 X<C236 X4337 X4439 XCA34 X4735 X4537 X4439 X4446 X4347 XC637 X4539 X4547 X4748 XCA34 X4835 X4736 X4639 X4646 X4747 X4847 XC347 X4548 X4649 X4946 X> Xput XMetrics X/3412 X[7 X10] Xput XCharStrings X/3413 X<C23D X433D X443E X4446 X4347 X4549 XC33C X453E X4546 X4447 X4548 X4647 X4546 XC13E X443B X463D X4646 X4747 X4549 XC93C X4B3D X4C3F X4C46 X4B47 X4D49 XCB3C X4C3D X4D3F X4D46 X4C47 X4D48 X4E47 X4D46 XC63E X493C X4B3B X4D3C X4E3E X4E46 X4F47 X4D49 XD13C X523D X543E X5447 X5649 X5946 XD23C X553E X5546 X5748 XCE3E X513C X533B X543C X563D X573D XD63E X573D XD63E X5646 X5747 X5847 X> Xput XMetrics X/3413 X[-1 X26] Xput XCharStrings X/3414 X<C23D X433D X443E X4446 X4347 X4549 XC33C X453E X4546 X4447 X4548 X4647 X4546 XC13E X443B X463D X4646 X4747 X4549 XC93C X4A3D X4C3E X4C47 X4E49 X5146 XCA3C X4D3E X4D46 X4F48 XC63E X493C X4B3B X4C3C X4E3D X4F3D XCE3E X4F3D XCE3E X4E46 X4F47 X5047 X> Xput XMetrics X/3414 X[-1 X18] Xput XCharStrings X/3415 X<C43E X4446 X4347 XC53E X4546 X4848 XC73D X463E X4646 X4847 X4948 XC347 X4447 X4648 X4749 X4A48 XC43E X473D X4C3B X4D3D X4E40 X4E43 X4D46 X4C47 X4A48 XCB3C X4C3D X4D3F XCA3C X4C3E X4D41 X4D43 X4C46 X4A48 X> Xput XMetrics X/3415 X[-3 X17] Xput XCharStrings X/3416 X<C538 X433A X433C X443F X4446 X4248 XC447 X454E XC43B X443C X453F X4549 XC439 X443A X453C X463F X4646 X4746 X4947 X4A48 XC647 X454E XC948 X4747 XCA48 X4849 X4647 XC447 X4248 XC63E X4C3B X4D3D X4E40 X4E43 X4D46 X4C47 X4A48 XCB3C X4C3D X4D3F XCA3C X4C3E X4D41 X4D43 X4C46 X4A48 X> Xput XMetrics X/3416 X[0 X17] Xput XCharStrings X/3417 X<CA3B X473C X453D X443E X4341 X4344 X4447 X4549 X4B46 XC445 X4547 X4648 XC73C X453E X4441 X4443 X4546 X4748 XC83C X493D X4B3E X4B46 X4C4E XC93C X4C3E X4C49 XCA3B X4B3C X4D3D X4E3D XCD3E X4E3D XCD3E X4D46 X4C4E X> Xput XMetrics X/3417 X[-3 X17] Xput XCharStrings X/3418 X<C33D X443D X453E X4546 X4447 XC43C X463E X4647 X4848 XC23E X453B X473D X4746 X4847 X4947 XC447 X4648 X4749 X4A46 XC93C X4A3E X4C3D X4B3B X473D XCA3C X4B3D X> Xput XMetrics X/3418 X[-2 X14] Xput XCharStrings X/3419 X<CC34 X4B35 X4935 X4734 X4534 X4436 X443B X433D X423E XCA36 X4836 X4635 X4535 XCC34 X4B36 X4A37 X4837 X4636 X4536 X4437 XC439 X463E XC43E X4442 X454E XC53D X443D X453C X4549 XC63E X4642 X454E XC23E X443E X> Xput XMetrics X/3419 X[6 X11] Xput XCharStrings X/3420 X<C737 X463A X453C X443D X423E XC737 X473D X4A3D X4A3E XC23E X453E XC73E X4A3E XC53E X4546 X4447 XC63D X453D X463B X4646 X4848 XC73E X4746 X4847 X4947 XC447 X4648 X4749 X4A46 X> Xput XMetrics X/3420 X[3 X12] Xput XCharStrings X/3421 X<C23D X433D X443E X4446 X4347 XC33C X453E X4546 X4748 XC13E X443B X463D X4646 X4847 X4948 XC347 X4447 X4648 X4749 X4948 X4C46 XCD3B X4B3D X4C3E X4C47 X4E49 X5146 XCD3E X4E3D X4D3C X4C3D X4D3E X4D46 X4F48 XCD3B X4F3D X4E3E X4E46 X4F47 X5047 X> Xput XMetrics X/3421 X[-1 X18] Xput XCharStrings X/3422 X<C539 X433B X433D X4440 X4446 X4347 XC43C X443D X4540 X4546 X4848 XC43A X443B X453D X4640 X4646 X4847 X4948 XC347 X4447 X4648 X4749 X4A48 XC63E X4C3B X4D3D X4E40 X4E43 X4D46 X4C47 X4A48 XCB3C X4C3D X4D3F XCA3C X4C3E X4D41 X4D43 X4C46 X4A48 X> Xput XMetrics X/3422 X[-1 X17] Xput XCharStrings X/3423 X<C539 X433B X433D X4440 X4446 X4347 X4549 XC43C X443D X4540 X4546 X4447 X4548 X4647 X4546 XC43A X443B X453D X4640 X4646 X4747 X4549 XC93C X4B3D X4C3F X4C46 X4B47 XCB3C X4C3D X4D3F X4D46 X5048 XC63E X493C X4B3B X4D3C X4E3E X4E46 X5047 X5148 XCB47 X4C47 X4E48 X4F49 X5248 XCE3E X543B X553D X5640 X5642 X5546 X5447 X5248 XD33C X543D X553F XD23C X543E X5541 X5543 X5446 X5248 X> Xput XMetrics X/3423 X[-3 X25] Xput XCharStrings X/3424 X<C43D X453D X463E X4646 X4546 X4347 X4249 X424B X434D X454E X484E X4B4D X4B4C X4A4C X4A4D XC53C X473E X4746 X4A48 XC33E X463B X483D X4846 X4A47 X4B48 XCD47 X4949 X4848 X4647 X4447 X4249 XCA3C X4B3E X4D3D X4C3B X483D XCB3C X4C3D X> Xput XMetrics X/3424 X[-2 X15] Xput XCharStrings X/3425 X<C539 X433B X433D X4440 X4446 X4347 XC43C X443D X4540 X4547 X4748 XC43A X443B X453D X4640 X4646 X4747 X4847 XC347 X4548 X4649 X4946 XC63E X4C3B X4D3D X4E41 X4E45 X4D48 X4C4A X4A4C X474E XCB3C X4C3D X4D40 XCA3C X4C3F X4D42 X4D45 X4C49 X4A4C X> Xput XMetrics X/3425 X[-1 X17] Xput XCharStrings X/3426 X<C33E X483B X4A3C X4B3E X4B40 X4A42 X4644 XC83C X4A3D XC73C X493D X4A3F X4A40 X4942 X4843 XC843 X4A45 X4B47 X4B4B X4A4D X484E X464E X444D X434B X4349 X4447 X4646 X4C44 XC744 X4945 X4A47 XC644 X4946 X4A48 X4A4B X494D X484E X> Xput XMetrics X/3426 X[-2 X14] Xput XCharStrings X/3427 X<C83B X463C X433E X4340 X4443 XC43E X4440 X4542 XC63C X453D X4540 X4642 XC63C X483D X4A3D X4C3C X4D3B X4D39 X4C38 X4A38 XC73C X493C XC83B X4A3C X4C3C XC443 X4C40 X4D43 X4D45 X4C47 X4849 XCB41 X4C43 X4C46 X4B47 XCA41 X4B43 X4B46 X4A48 XCA48 X4847 X4547 X4249 XC948 X4748 XC849 X4648 X4448 X4249 X> Xput XMetrics X/3427 X[0 X16] Xput XCharStrings X/3428 X<CC34 X4B35 X4935 X4734 X4534 X4436 X443B X433D X423E XCA36 X4836 X4635 X4535 XCC34 X4B36 X4A37 X4837 X4636 X4536 X4437 XC439 X463E XC43E X4442 X454E XC53D X443D X453C X4549 XC63E X4642 X454E XC23E X443E XC63E X4B3B X4D3C X4E3E X4E40 X4D42 X4944 XCB3C X4D3D XCA3C X4C3D X4D3F X4D40 X4C42 X4B43 XCB43 X4D44 X4E46 X4E49 X4D4B X4B4D X484E XCB44 X4D45 XC944 X4A44 X4C45 X4D47 X4D4A X4C4C X> Xput XMetrics X/3428 X[4 X17] Xput XCharStrings X/3429 X<C637 X453A X443C X433D X413E XC637 X4646 X4747 X4549 XC53D X443D X453C X4546 X4447 X4548 X4647 X4546 XC13E X443E X4446 X4347 X4549 XC63E X4B3B X4D3C X4E3E X4E40 X4D42 X4944 XCB3C X4D3D XCA3C X4C3D X4D3F X4D40 X4C42 X4B43 XCB43 X4D44 X4E46 X4E49 X4D4B X4B4D X484E XCB44 X4D45 XC944 X4A44 X4C45 X4D47 X4D4A X4C4C X> Xput XMetrics X/3429 X[1 X17] Xput END_OF_FILE if test 18559 -ne `wc -c <'postscript/fonts/Olde/italic.r'`; then echo shar: \"'postscript/fonts/Olde/italic.r'\" unpacked with wrong size! fi # end of 'postscript/fonts/Olde/italic.r' fi if test -f 'source/file.c' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'source/file.c'\" else echo shar: Extracting \"'source/file.c'\" \(17713 characters\) sed "s/^X//" >'source/file.c' <<'END_OF_FILE' X/* X * Copyright (C) Rutherford Appleton Laboratory 1987 X * X * This source may be copied, distributed, altered or used, but not sold for profit X * or incorporated into a product except under licence from the author. X * It is not in the public domain. X * This notice should remain in the source unaltered, and any changes to the source X * made by persons other than the author should be marked as such. X * X * Crispin Goswell @ Rutherford Appleton Laboratory caag@uk.ac.rl.vd X */ X#include <sgtty.h> X X#include "main.h" X X#define MAXFILENAME 1000 X X/* X * This file implements the input/output calls in PostScript. X * X * A PostScript file corresponds reasonably closely to a Unix file, so this is not X * too hard. X * X * The file operator itself can generate three major file types: X * X * Regular filing system files X * Standard I/O channels (called %stdin, %stdout and %stderr) X * Peculiar temporary files called %lineedit and %statementedit X * X * %lineedit and %statementedit are files generated by the file operator, rather X * than merely opened for reading or writing. X * X * %lineedit generates a temporary file containing the text that the user types X * in on the %stdin stream for one line only. X * The %stdin is required to be edited while this is going on, which means that it X * must be in cooked mode (-cbreak). %stdin is normally in cbreak mode. X * X * %statementedit is similar to %lineedit (in that it generates a temporary file), X * but the input process continues until PostScript sees a complete expression, with X * "(" matching ")" and "{" matching "}". "[" is not required to match "]", as these X * are not actually parsed differently from operators (except for their delimiting X * properties). X * X * There are essentially two ways of implementing these temporary files: X * X * o We could use real files, and copy user input into them, allowing the X * PostScript interpreter to just read from them. X * o We could provide some kind of cache using a buffer in main memory. X * X * The second alternative is likely to reduce certain overheads and, since the code X * for parsing from strings is needed anyway (token is defined to parse from strings), X * there is little extra effort in doing things this way. X * X * For this reason, files under this implementation are typed. We have: X * X * StreamFiles which are conventional stdio FILE *s. X * StringFiles which are pointers in strings. X * X * StringFiles are used internally by token to parse from strings, to avoid duplicating X * the entire parser. These file types are defined with an enumerated type. X * X * It is defined that closing the %stdin file have no effect other than resetting an X * end-of-file flag. It is not defined whether the output files are required to be X * similarly permanent. We assume they are, and introduce a feature of files which is X * that they may be PERMANENT. This is a flag. It is also not clear if Readable and X * Writeable access to files is an Access Restriction, as such. We assume so. X * X */ X Xextern int errno; X Xstatic Object StdIn, Terminal, StdOut, StdErr, LineEdit; XObject StatementEdit, Fstdin, Fterminal, Fstdout, Fstderr; X XFILE *popen (); X Xstatic int Token (), Eq (); X Xstatic int PFile (), PCloseFile (), PRead (), PReadHexString (), PReadLine (), PReadString (); Xstatic int PBytesAvailable (), PWrite (), PWriteHexString (), PWriteString (), PFlush (); Xstatic int PFlushFile (), PStatus (), PCurFile (), PPrint (), PEcho (); X Xint ExecFile (); X XInitFile () X { X TypeInstallOp (File, "token", Token, 1, 2, 0, 0, File); X TypeInstallOp (File, "exec", ExecFile, 1, 0, 0, 0, File); X TypeInstallOp (File, "eq", Eq, 2, 1, 0, 0, File, File); X X Fstdin = ReadOnly (FileFrom (stdin)); Fstdin.flags |= PERMANENT; X Fterminal = FileFrom (fopen ("/dev/tty", "r")); Fterminal.flags |= PERMANENT; X Fstdout = WriteOnly (FileFrom (stdout)); Fstdout.flags |= PERMANENT; X Fstderr = WriteOnly (FileFrom (stderr)); Fstderr.flags |= PERMANENT; X X StdIn = StringFrom ("%stdin"); X StdOut = StringFrom ("%stdout"); X StdErr = StringFrom ("%stderr"); X Terminal = StringFrom ("%terminal"); X StatementEdit = StringFrom ("%statementedit"); X LineEdit = StringFrom ("%lineedit"); X X InstallOp ("file", PFile, 2, 1, 0, 0, String, String); X InstallOp ("closefile", PCloseFile, 1, 0, 0, 0, File); X InstallOp ("read", PRead, 1, 1, 0, 0, File); X InstallOp ("readhexstring", PReadHexString, 2, 1, 0, 0, File, String); X InstallOp ("readline", PReadLine, 2, 1, 0, 0, File, String); X InstallOp ("readstring", PReadString, 2, 1, 0, 0, File, String); X InstallOp ("bytesavailable", PBytesAvailable,1, 1, 0, 0, File); X InstallOp ("write", PWrite, 2, 0, 0, 0, File, Integer); X InstallOp ("writehexstring", PWriteHexString,2, 0, 0, 0, File, String); X InstallOp ("writestring", PWriteString, 2, 0, 0, 0, File, String); X InstallOp ("flush", PFlush, 0, 0, 0, 0); X InstallOp ("flushfile", PFlushFile, 1, 0, 0, 0, File); X InstallOp ("status", PStatus, 1, 1, 0, 0, File); X InstallOp ("currentfile", PCurFile, 0, 1, 0, 0); X InstallOp ("print", PPrint, 1, 0, 0, 0, String); X InstallOp ("echo", PEcho, 1, 0, 0, 0, Boolean); X X Cbreak (TRUE); X } X Xstatic int Token (f) Object f; X { X Object res; X res = Parse (f); X if (TypeOf (res) == Condition) X return Error (PSyntaxError); X else if (TypeOf (res) == Boolean) X VOID Push (OpStack, False); X else if (TypeOf (res) != Null) X { X VOID Push (OpStack, res); X VOID Push (OpStack, True); X } X else X return Error (PUnResult); X return TRUE; X } X Xstatic struct file_struct *Body (item) Object item; X { X return item.u.File; X } X Xint getchbuf; X X#ifdef notdef Xstruct file_struct *BodyFile (item) Object item; X { X return item.u.File; X } X Xstatic int Getc (fp) FILE *fp; X { X int c; X X for (;;) X { X errno = 0; X if ((c = getc (fp)) != EOF) X return c; X/* if (errno == 0 || Interrupted ())*/ X return EOF; X } X } X#endif X X#define Getc(a) getc(a) X Xstatic int Getchar () X { X return Getc (stdin); X } X X#define Getchar getchar X Xstatic int Status (file) Object file; X { X return Body (file)->available; X } X X#define Status(f) (Body(f)->available) X Xstatic int Eq (a, b) Object a, b; X { X return Push (OpStack, MakeBoolean (Body (a) == Body (b))); X } X X/* X * FileFrom generates a file object from an existing file pointer X */ XObject FileFrom (fp) FILE *fp; X { X Object res; X struct file_struct *f; X X res = MakeObject (File); X f = res.u.File = (struct file_struct *) Malloc (sizeof (struct file_struct)); X f->file_type = StreamFile; X f->f.f_ptr = fp; X f->available = 1; X X return res; X } X X/* X * FileString is used to generate a file-like object which actually X * reads from a string. This is used by "file" and "token" when parsing X * strings. X */ XObject FileString (o) Object o; X { X Object res; X struct file_struct *f; X X res = MakeObject (File); X f = res.u.File = (struct file_struct *) Malloc (sizeof (struct file_struct)); X f->file_type = StringFile; X f->f.c_ptr = BodyString (o); X f->available = lengthString (o); X X return res; X } X Xint GeneralGetch (file) Object file; X { X int c; X X if (!Status (file)) X return EOF; X switch (Body (file)->file_type) X { X default: X PanicIf (TRUE, "unknown file type in Getch\n"); X return 0; /* shuts lint up */ X X case StreamFile: X c = Getc (Body (file)->f.f_ptr); X if (c == EOF) X { X Body (file)->available = 0; X Close (file); X } X return c; X X case StringFile: X if (Body (file)->available == 0) X return EOF; X --Body (file)->available; X c = *Body (file)->f.c_ptr++; X return c; X } X } X XUngetch (o, c) Object o; char c; X { X struct file_struct *f = Body (o); X X ++f->available; X switch (f->file_type) X { X case StringFile: f->f.c_ptr--; break; X case StreamFile: VOID ungetc (c, f->f.f_ptr); break; X X default: X Panic ("Don't know how to Ungetch to this file\n"); X } X } X Xint ExecFile (item) Object item; X { X Object res; X res = Parse (item); X if (TypeOf (res) == Boolean) X { X if (BodyBoolean (res)) X return Error (PSyntaxError); X } X else if (TypeOf (res) == Condition) X return Error (PSyntaxError); X else if (TypeOf (res) == Null) X return Error (PUnResult); X else if (TypeOf (res) == Name && xCheck (res)) X { X /*Object binding; X X binding = Load (res); X X if (TypeOf (binding) == Operator) X res = binding;*/ X VOID Push (ExecStack, item); X VOID Push (ExecStack, res); X } X else X { X VOID Push (ExecStack, item); X VOID Push (/*TypeOf (res) == Name ? ExecStack : */OpStack, res); X } X return TRUE; X } X XCleanup () X { X Echo (TRUE); X Cbreak (FALSE); X } X Xstatic cbreak = FALSE, echoing = TRUE; X X/*ARGSUSED*/ XCbreak (cond) int cond; X { X/* struct sgttyb s; X X if (cond == cbreak) X return; X ioctl (0, TIOCGETP, &s); X cbreak = cond; X if (cbreak) X s.sg_flags |= CBREAK; X else X s.sg_flags &= ~CBREAK; X ioctl (0, TIOCSETP, &s); X*/ } X Xstatic Echo (cond) int cond; X { X struct sgttyb s; X X if (cond == echoing) X return; X ioctl (0, TIOCGETP, &s); X echoing = cond; X if (echoing) X s.sg_flags |= ECHO; X else X s.sg_flags &= ~ECHO; X ioctl (0, TIOCSETP, &s); X } X Xstatic FILE *open_pipes [32];/* ICK! */ Xstatic int n_open_pipes = 0; X XFILE *Fopen (name, mode) char *name, *mode; X { X if (name[0] == '|') X { X FILE *fp = popen (name + 1, mode); X int i; X X for (i = 0; i < n_open_pipes && open_pipes [i] != NULL; i++) X ; X open_pipes [i] = fp; X if (i == n_open_pipes) X ++n_open_pipes; X return fp; X } X else X return fopen (name, mode); X } X Xvoid Fclose (fp) FILE *fp; X { X int i; X X for (i = 0; i < n_open_pipes; i++) X if (open_pipes [i] == fp) X { X pclose (fp); X open_pipes [i] = NULL; X } X fclose (fp); X } X Xstatic int PFile (string1, string2) Object string1, string2; X { X int mode; X X if (lengthString (string1) == 0 X || lengthString (string2) != 1 X || (mode = getString (string2, 0)) != 'r' && mode != 'w') X return Error (PInvFileAccess); X else if (getString (string1, 0) == '%') X return PseudoFile (string1, mode); X else if (lengthString (string1) > MAXFILENAME) X return Error (PUnFilename); X else X { X char name[MAXFILENAME+1], modes[2]; X FILE *fp; X X modes [0] = mode; modes [1] = '\0'; X VOID Bcopy (name, BodyString (string1), lengthString (string1)); X name [lengthString (string1)] = '\0'; X if (fp = Fopen (name, modes)) X return Push (OpStack, mode == 'r' ? ReadOnly (FileFrom (fp)) : WriteOnly (FileFrom (fp))); X return Error (PUnFilename); X } X } X Xstatic int PseudoFile (string1, mode) Object string1; int mode; X { X if (EqString (string1, StdIn)) return mode == 'r' ? Push (OpStack, Fstdin) : Error (PInvFileAccess); X else if (EqString (string1, Terminal)) return Push (OpStack, Fterminal); X else if (EqString (string1, StdOut)) return mode == 'w' ? Push (OpStack, Fstdout) : Error (PInvFileAccess); X else if (EqString (string1, StdErr)) return mode == 'w' ? Push (OpStack, Fstderr) : Error (PInvFileAccess); X else if (EqString (string1, StatementEdit)) return mode == 'r' ? EditStatement () : Error (PInvFileAccess); X else if (EqString (string1, LineEdit)) return mode == 'r' ? EditLine () : Error (PInvFileAccess); X else X return Error (PUnFilename); X } X Xstatic int EditLine () X { X unsigned char buf [BUFSIZE]; X int c, length = 0; X X Cbreak (FALSE); X do { X if (length >= BUFSIZE) X { X Cbreak (TRUE); X return Error (PLimitCheck); X } X if ((c = Getchar ()) == EOF) X break; X buf [length++] = c; X if (Interrupted ()) X { X Cbreak (TRUE); X return FALSE; X } X } while (buf [length - 1] != '\n'); X Cbreak (TRUE); X return Push (OpStack, X ReadOnly (FileString (MakeString (Bcopy (Malloc ((unsigned) length), buf, length), X length)))); X } X Xstatic int EditStatement () X { X char buf[BUFSIZE]; X int c, length = 0, slevel = 0, blevel = 0, escaped = FALSE; X X Cbreak (FALSE); X do { X if (length >= BUFSIZE) X { X Cbreak (TRUE); X return Error (PLimitCheck); X } X if ((c = Getchar ()) == EOF) X break; X buf [length++] = c; X if (Interrupted ()) X { X Cbreak (TRUE); X return FALSE; X } X if (slevel != 0) X if (escaped) X escaped = FALSE; X else if (c == '(') X ++slevel; X else if (c == ')') X --slevel; X else if (c == '\\') X escaped = TRUE; X else X ; X else X { X if (blevel == 0 && c == '}' || c == ')') X { X Cbreak (TRUE); X return Error (PSyntaxError); X } X else if (c == '{') X ++blevel; X else if (c == '}') X --blevel; X else if (c == '(') X ++slevel; X } X } while (!(slevel == 0 && blevel == 0 && buf [length - 1] == '\n')); X Cbreak (TRUE); X return Push (OpStack, X ReadOnly (FileString (MakeString (Bcopy (Malloc ((unsigned) length), buf, length), X length)))); X } X Xstatic int PCloseFile (file) Object file; X { X if (Status (file)) X Close (file); X return TRUE; X } X Xint Close (file) Object file; X { X if (file.flags & PERMANENT) X return TRUE; X switch (Body (file)->file_type) X { X default: X Panic ("Unknown file type in closefile\n"); X X case StringFile: X Body (file)->available = 0; X Body (file)->f.c_ptr = NULL; X return TRUE; X X case StreamFile: X Body (file)->available = 0; X if (Body (file)->f.f_ptr) X Fclose (Body (file)->f.f_ptr), X Body (file)->f.f_ptr = NULL; X return TRUE; X } X } X Xstatic int PRead (file) Object file; X { X int c = Getch (file); X X if (c != EOF) X return Push (OpStack, MakeInteger (c)), Push (OpStack, True); X else X return Push (OpStack, False); X } X Xstatic int PReadHexString (file, string) Object file, string; X { X int cc = 0, i, odd = FALSE, l = lengthString (string); X X for (i = 0; i < l; ) X { X int c = Getch (file); X X if (c == EOF) X break; X else if (c >= '0' && c <= '9') X c -= '0'; X else if (c >= 'a' && c <= 'f') X c -= 'a' - 10; X else if (c >= 'A' && c <= 'F') X c -= 'A' - 10; X else X continue; X if (odd) X putString (string, i++, (cc << 4) | c); X else X cc = c; X odd = !odd; X } X VOID Push (OpStack, getIString (string, 0, i)); X VOID Push (OpStack, MakeBoolean (Status (file))); X X return TRUE; X } X Xstatic int PReadLine (file, string) Object file, string; X { X int i, c = 0, l = lengthString (string); X X for (i = 0; (c = Getch (file)) != EOF && i < l && c != '\n'; i++) X putString (string, i, c); X if (c != '\n' && c != EOF) X return Error (PRangeCheck); X VOID Push (OpStack, getIString (string, 0, i)); X VOID Push (OpStack, MakeBoolean (c != EOF)); X X return TRUE; X } X Xstatic int PReadString (file, string) Object file, string; X { X int i, c, l = lengthString (string); X X for (i = 0; i < l && (c = Getch (file)) != EOF; i++) X putString (string, i, c); X VOID Push (OpStack, getIString (string, 0, i)); X VOID Push (OpStack, MakeBoolean (c != EOF)); X X return TRUE; X } X X/*ARGSUSED*/ Xstatic int PBytesAvailable (file) Object file; X { X return Push (OpStack, MakeInteger (-1)); X } X Xstatic int PWrite (file, integer) Object file, integer; X { X if (!Status (file)) X return Error (PIOError); X switch (Body (file)->file_type) X { X default: X Panic ("unknown file type in write\n"); X X case StringFile: X return Error (PInvFileAccess); X X case StreamFile: X if (Body (file)->f.f_ptr) X { X VOID fputc (BodyInteger (integer), Body (file)->f.f_ptr); X return TRUE; X } X return Error (PIOError); X } X } X Xstatic int PWriteHexString (file, string) Object file, string; X { X FILE *fp; X unsigned char *p = BodyString (string); X int l = lengthString (string); X X if (!Status (file)) X return Error (PIOError); X switch (Body (file)->file_type) X { X default: X Panic ("unknown file type in writestring\n"); X X case StringFile: X return Error (PInvFileAccess); X X case StreamFile: X fp = Body (file)->f.f_ptr; X while (l--) X { X int c = *p++; X static char hex[] = "0123456789abcdef"; X X fprintf (fp, "%c%c", hex[c >> 4], hex[c & 0xF]); X } X return TRUE; X } X } X Xstatic int PWriteString (file, string) Object file, string; X { X if (!Status (file) || !wCheck (file)) X return Error (PIOError); X switch (Body (file)->file_type) X { X default: X Panic ("unknown file type in writestring\n"); X X case StringFile: X return Error (PInvFileAccess); X X case StreamFile: X fprintf (Body (file)->f.f_ptr, X "%.*s", X lengthString (string), X BodyString (string)); X return TRUE; X } X } X Xstatic int PFlush () /* --- */ X { X VOID fflush (stdout); X HardUpdate (); /* yes, well ... you didn't see this... */ X return TRUE; X } X Xstatic int PFlushFile (file) Object file; X { X if (!Status (file)) X return Error (PIOError); X else if (wCheck (file)) X switch (Body (file)->file_type) X { X default: X Panic ("unknown file type in flushfile\n"); X return FALSE; /* shuts lint up */ X X case StringFile: break; X X case StreamFile: X if (Body (file)->f.f_ptr) X VOID fflush (Body (file)->f.f_ptr); X break; X } X else if (rCheck (file)) X while (Getch (file) != EOF) X ; X return TRUE; X } X Xstatic int PStatus (file) Object file; X { X return Push (OpStack, MakeBoolean (Status (file))); X } X Xstatic int PCurFile () /* --- file */ X { X int c = CountTo (File, ExecStack); X Object f; X X PanicIf (c < 0, "currentfile finds no run context"); X f = ExecStack->stack_body[Height (ExecStack) - c - 1]; X return Push (OpStack, Cvlit (f)); X } X Xstatic int PPrint (string) Object string; X { X int i, l = lengthString (string); X unsigned char *s = BodyString (string); X X for (i = 0; i < l; i++) X putchar (*s++); X /* PRINTF BUG: printf ("%.*s", lengthString (string), BodyString (string));*/ X return TRUE; X } X Xstatic int PEcho (res) Object res; X { X Echo (BodyBoolean (res)); X return TRUE; X } END_OF_FILE if test 17713 -ne `wc -c <'source/file.c'`; then echo shar: \"'source/file.c'\" unpacked with wrong size! fi # end of 'source/file.c' fi echo shar: End of archive 14 \(of 18\). cp /dev/null ark14isdone MISSING="" for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 ; do if test ! -f ark${I}isdone ; then MISSING="${MISSING} ${I}" fi done if test "${MISSING}" = "" ; then echo You have unpacked all 18 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