Thread View: comp.lang.postscript
1 messages
1 total messages
Started by The Dougster
Wed, 28 Oct 1992 16:19
How to modify kshow
Author: The Dougster
Date: Wed, 28 Oct 1992 16:19
Date: Wed, 28 Oct 1992 16:19
46 lines
1880 bytes
1880 bytes
All of our *show commands need to be intercepted and rewritten.
ashow is now modAShow. show is now modShow. kshow needs to be
modKShow. Here's the dirt:
kshow syntax is
proc string kshow.
We need to execute kshow a total of four times each time kshow
appears in the postscript stream. The postscript stream comes from
various word processing programs capable of producing postscript,
therefore we don't ever know how large the procedure is, nor what
makes up the string.
We've worked this out so far, and we need to know if there are any
holes in it. (The part in question is determining the size of
the procedure):
---
To make multiple copies of kshow:
1) When kshow is found, count the stack and define C1 = count.
2) Save the stack to disk.
3) Execute kshow.
4) Count the stack again, and define C2 = count.
5) Clear the stack and restore it from disk.
6) C3 = C1 - C2 is the size of the procedure.
7) copy C3 + 1 items (add one for the string which wasn't
counted) to the top of the stack, and execute kshow. Repeat
(7) until the correct number of kshows has been done.
---
This is not elegant, but it should work. Is there an elegant way
to count the number of elements in a kshow procedure? Particularly,
are the braces `{' and `}' placed on the stack as delimiters?
Help.
Douglas DoD#1961 BMWMOA Renting:N56136
[Life is for learning.]
Reply-To: gdls!parker@ilium.troy.msen.com
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads