10.07.2015 Views

Download - Multivac!

Download - Multivac!

Download - Multivac!

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Fig. 7.28 Fitting an image into a box subject to various fit methodsGenerated output Option list for PDF_fit_image( )a) boxsize={70 45} position=centerb) boxsize={35 45} position=centerc) boxsize={70 45} position=center fitmethod=meetd) boxsize={35 45} position=center fitmethod=meete) boxsize={70 45} position=center fitmethod=entiref) boxsize={30 30} position=center fitmethod=clipg) boxsize={30 30} position={right top} fitmethod=clipAdjusting an object to the page. Adjusting an object to a given page size can easily beaccomplished by choosing the page as target box for placing the object. The followingstatement uses an A4-sized page with dimensions 595 x 842:p.fit_image(image, 0, 0, "boxsize={595 842} position={left bottom} fitmethod=slice");In this code fragment a box is placed at the lower left corner of the page. The size of thebox equals the size of an A4 page. The object is placed in the lower left corner of the boxand scaled proportionally until it fully covers the box and therefore the page. If the objectexceeds the box it will be cropped. Note that fitmethod=slice results in the object beingscaled (as opposed to fitmethod=clip which doesn’t scale the object). Of course theposition and fitmethod options could also be varied in this example.7.3.4 Orientating an ObjectPlacing an image with orientation. In our next example we orientate an image towardswestern direction (orientate=west). This means that the image is rotated by 90˚counterclockwise and then the lower left corner of the rotated object is translated to thereference point (0, 0). The object will be rotated in itself (see Figure 7.31a). Since we have160 Chapter 7: Formatting Features

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!