Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!sdd.hp.com!uakari.primate.wisc.edu!aplcen!boingo.med.jhu.edu!haven!umd5!zben From: zben@umd5.umd.edu (Ben Cranston) Newsgroups: comp.sys.mac.programmer Subject: LaserWriter printing from DBase running under SoftPC Message-ID: <8313@umd5.umd.edu> Date: 22 Mar 91 21:18:03 GMT Organization: University of Maryland, College Park Lines: 44 Well, I've found the source of those "dictionary full" errors we were getting when we tried to do Laserwriter output from DBase under Soft-PC. The standard Apple prep file creates a PostScript dictionary called "md", this is normally done in such a way as to be permanently installed in the printer, but I've modified this for my diversion stuff so md is created and destroyed for each print file. When Soft-PC does "PostScript" printing the data produced is embedded in a standard Apple print wrapper. At the point in the wrapper where Soft-PC's data is inserted, the topmost dictionary in the "dictionary stack" is md. The topmost dictionary in the dictionary stack is where "def" puts the keyword and value being set. When DBase outputs through Soft-PC the first "embedded" data is DBase's own prep file, which defines yet ANOTHER set of primitives that will later be used by the DBase data proper. These defines are made with the "def" operator and so go into md. Now, here's the rub: the standard Apple prep defines md with a maximum size of 270. The standard Apple prep then proceeds to use 229 of those slots with Apple-specific prep stuff. The DBase prep attempts to use 96 more of these slots to define DBase-specific stuff. Unfortunately 229+96 = 325 > 270 so one of DBase's "def" calls dies with a dictionary-full error. Changing the prep file slightly to set md's size to 400 instead of 270 makes the test file print OK, and it's a really small change compared with all the other evil I've done to Apple's prep. So it looks like a trivial change may allow us to support Laserwriter output from DBase under Soft-PC. We will try to test this next week. Another interesting correlary is that it would at least theoretically be possible to find the string "/md 270 dict def md begin" in the standard Apple "LaserPrep" file and patch it to "/md 400 dict def md begin" instead. This would make DBase LaserWriter output under SoftPC work under a normal (i.e. non-UOM-diverted) printing setup. Ben Cranston Network Infrastructures Group University of Maryland at College Park -- Ben Cranston A determined iconoclast, it would be better to assume the opinion expressed above is the diametric OPPOSITE to that of the Warm and Fuzzy Network Group of Egregious State University...