| Search Locate Previous Next | Contents |
What is a page layout?
NewLeaf holds your page definitions in a 5-column APL matrix, where each page is composed of a set of objects, starting with a pg object to define the paper size and orientation. A typical layout, with a default frame, and a page number object, could look something like:
ÚÎÎÂÎÎÎÎÎÎÎÎÎÎÎÂÎÎÎÎÎÎÎÂÎÎÎÎÎÎÎÂÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÌ ÛpgÛPage LayoutÛ201 101Û595 842ÛÚÎÎÎÎÎÎÂÎÎÎÎÎÎÎÎÌÛ Û Û Û Û ÛÛPaper ÛA4 ÛÛ Û Û Û Û ÛÃÎÎÎÎÎÎÏÎÎÎÎÎÎÎÎÝÛ Û Û Û Û ÛÛOrientÛPortraitÛÛ Û Û Û Û ÛÀÎÎÎÎÎÎÁÎÎÎÎÎÎÎÎÙÛ ÃÎÎÏÎÎÎÎÎÎÎÎÎÎÎÏÎÎÎÎÎÎÎÏÎÎÎÎÎÎÎÏÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÝ ÛfrÛText Û36 74 Û516 732ÛÚÎÎÎÎÎÎÎÎÂÎÌ Û Û Û Û Û ÛÛAutoflowÛ1Û Û Û Û Û Û ÛÃÎÎÎÎÎÎÎÎÏÎÝ Û Û Û Û Û ÛÛClip Û1Û Û Û Û Û Û ÛÀÎÎÎÎÎÎÎÎÁÎÙ Û ÃÎÎÏÎÎÎÎÎÎÎÎÎÎÎÏÎÎÎÎÎÎÎÏÎÎÎÎÎÎÎÏÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÝ ÛtxÛPage # Û216 14 Û144 48 ÛÚÎÎÎÎÂÎÎÎÎÎÌ Û Û Û Û Û ÛÛFontÛti,14Û Û Û Û Û Û ÛÀÎÎÎÎÁÎÎÎÎÎÙ Û ÀÎÎÁÎÎÎÎÎÎÎÎÎÎÎÁÎÎÎÎÎÎÎÁÎÎÎÎÎÎÎÁÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÙ
All objects have data in the first four columns, giving the object type, caption/id, position (ignored for the paper!) and size. Values are measured in points (72 points = 1 inch), with the origin at the lower left corner of the paper. Any non-default properties you set for the objects are recorded in column-5 as a two-column matrix of property-value pairs.
To start the designer with a new layout ...
Layout.Design 'myrpt'
This will allow you to construct the various objects visually, and to check the appearance of your finished page by filling the frames with sample text. The completed layout will be saved in the APL variable myrpt. You can, of course, modify or copy this matrix using APL in the normal way:
newrptmyrpt Layout.Design 'newrpt'
... and so on. The Designer makes a quick check of your screen resolution and sets the scale of the layout to accommodate A4 paper (portrait) of A3 (landscape). If you need to work on a larger size you can override this setting with an optional left argument such as:
2 Layout.Design 'newrpt'
This will display the page at half the normal size and would allow you to work on A3 paper in portrait orientation.
The next few pages will walk you through the main components in the page designer, so that you are able to make simple reports quickly, and understand how to set about building a complex multi-column design with additional elements such as artworks and rules.