Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.postscript > #3501

browse-dict -- Thinking in Postscript Example 10.9 on page 128

Newsgroups comp.lang.postscript
Date 2020-03-23 07:03 -0700
Message-ID <4a78ff2b-36d9-4608-9228-6d217805d17d@googlegroups.com> (permalink)
Subject browse-dict -- Thinking in Postscript Example 10.9 on page 128
From douglas.mcallaster@gmail.com

Show all headers | View raw


Folks,

Below does not work as shown in subject text.
Can someone fix or offer a better solution?

Thx, Doug
======snip=============
/browse-dict % dictionary browse-dict -
{ %def
{ %forall
exch (key: ) print ==
dup type
dup /dicttype eq { %ifelse
(subdictionary: ) print
browse-dict % recursively browse dictionary
}{
(value: ) print ==
} ifelse
} forall
} bind def

/testDict1	<<
	/a 1
	/b [ 1 2 3 ]
	/c	<<
		/key1 4
		/key2 5
		/key3 6
	>>
>> def

testDict1
browse-dict

Back to comp.lang.postscript | Previous | NextNext in thread | Find similar


Thread

browse-dict -- Thinking in Postscript Example 10.9 on page 128 douglas.mcallaster@gmail.com - 2020-03-23 07:03 -0700
  Re: browse-dict -- Thinking in Postscript Example 10.9 on page 128 luser droog <luser.droog@gmail.com> - 2020-03-23 07:26 -0700

csiph-web