Re: fit to page using inline postscript
- To: mathgroup at smc.vnet.net
- Subject: [mg32033] Re: fit to page using inline postscript
- From: pbrandani at ucdavis.edu (pbrandani)
- Date: Wed, 19 Dec 2001 04:29:20 -0500 (EST)
- References: <9vche3$3ma$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
pbrandani at ucdavis.edu (pbrandani) wrote in message news:<9vche3$3ma$1 at smc.vnet.net>... > Is there a way to insert page breaks at set intervals to delimit > sections of a large notebook output (mixed text/graphics)? > > and then use inline postscript instructions to have these individual > sections fit a single page of output on a printer? > > Is the outlined scheme feasible? what combination of mathematica and > postscript code should be used? HERE IS A SOLUTION SUGGESTED BY Paul Hinton OF Wofram Research: <<<<<<<<<< A safer route is to probably separate discrete units of output into individual cells. This isn't too hard to implement with a couple of utility functions: evaluateToOutputCell[input_] := Cell[BoxData[ToBoxes[input]], "Output"] evaluateToGraphicsCell[input_] := Cell[GraphicsData["PostScript", DisplayString[input]], "Graphics", CellLabel -> StringJoin["From In[", ToString[$Line], "]="]] /; MatchQ[input, _Graphics | _Graphics3D | _SurfaceGraphics | _ContourGraphics | _DensityGraphics] You then use these functions as wrappers to your inputs that generate outputs. Here is what they would look like for relatively simple inputs. evaluateToOuputCell[Integrate[x, x]] evaluateToGraphicsCell[Plot3D[Sin[x] Cos[y], {x, 0, 2 Pi}, {y, 0, 2 Pi}]] If you want to specify that a page break be added, after a cell, you can edit the functions above to include the option PageBreakBelow -> <boolean> where <boolean> may be True or False. >>>>>>>>>> e.g. CellPrint[Cell["**--**", PageBreakAbove -> True]]