Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!news.unit0.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Michael Unger Newsgroups: comp.lang.postscript Subject: Re: getting system information from a PS program Date: Mon, 23 Jan 2012 17:26:55 +0100 Organization: not that I'm aware of ... Lines: 47 Message-ID: <9o5gj7Fg78U2@mid.individual.net> References: <9nr4ecF33kU1@mid.individual.net> Reply-To: 2012Q1.usenet.michaelunger@spamgourmet.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-Trace: individual.net J9D78Nh27jup0KqD6HfTAgfuwzQUyz8QdiVvMXfD1MziVyiTm2 Cancel-Lock: sha1:gpk6qJ0XV2os+UME+/51ASaeZp8= User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.24) Gecko/20100228 SeaMonkey/1.1.19 In-Reply-To: Xref: x330-a1.tempe.blueboxinc.net comp.lang.postscript:581 On 2012-01-19 20:05, "SaGS" wrote: > On Jan 19, 8:01 pm, Michael Unger > wrote: >=20 > [...] >=20 >> (3) An array filled with file names, the full path and a template for >> the file names are known; "filenameforall" doesn't help much because >> there are many parameters depending on parts of the file name and a >> specific order has to be observed as well. >=20 > Do a =91filenameforall=92 then post-process the file list you obtain. F= or > example you can use string operators on the filenames to examine them > and do supplemental filtering (if a filenameforall template does not > exactly suit what you want to select), or sort the list. I'll have to read the PLRM carefully ... Will it be sufficient to process the string object written to the "scratch" object by "filenameforall", saving it to an array or a dictionary for example? (PLRM, 3rd ed, page 588) >> ... >> (4) Getting an array sorted (ASCII, ascending). I didn't find any >> PostScript operator related to this issue at all. >=20 > There is no such operator, but you can write a procedure to do the > job :) > See, for example, http://en.wikibooks.org/wiki/PostScript_FAQ#How_to_so= rt_an_array.3F >=20 >> ... There obviously is an optimized bi-directional version of "bubble sort" called "shaker sort" or "coctail sort" according to Wikipedia [1]. Michael [1] --=20 Real names enhance the probability of getting real answers. My e-mail account at DECUS Munich is no longer valid.