17.05.2014 Views

PDFlib 8 Windows COM/.NET Tutorial

PDFlib 8 Windows COM/.NET Tutorial

PDFlib 8 Windows COM/.NET Tutorial

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

can be used. In Figure 8.5h the text is placed at the bottom left of a box which is not<br />

broad enough. The text will be clipped on the right.<br />

Fig. 8.5 Fitting text into a box on the page subject to various options<br />

Generated output Option list for fit_textline( )<br />

Kraxi Systems<br />

a) boxsize={100 35} position=center fontsize=12<br />

Kraxi Systems<br />

b) boxsize={50 35} position=center fontsize=12<br />

c)<br />

Kraxi Systems<br />

boxsize={100 35} position=center fontsize=12<br />

fitmethod=auto<br />

d)<br />

Kraxi Systems<br />

boxsize={58 35} position=center fontsize=12<br />

fitmethod=auto<br />

e)<br />

Kraxi Systems<br />

boxsize={30 35} position=center fontsize=12<br />

fitmethod=auto<br />

f)<br />

Kraxi Systems<br />

boxsize={100 35} position=center fontsize=12<br />

fitmethod=meet<br />

g)<br />

Kraxi Systems<br />

boxsize={100 35} position=center fontsize=12<br />

fitmethod=entire<br />

h)<br />

Kraxi Sys<br />

boxsize={50 35} position={left center}<br />

fontsize=12 fitmethod=clip<br />

Vertically centering text. The text height in fit_textline( ) is the capheight, i.e. the<br />

height of the capital letter H, by default. If the text is positioned in the center of a box it<br />

will be vertically centered according to its capheight (see Figure 8.6a).<br />

To specify another height for the text box we can use the Matchbox feature (see also<br />

Section 8.4, »Matchboxes«, page 243). The matchbox option of fit_textline( ) define the<br />

height of a Textline which is the capheight of the given font size, by default. The height<br />

of the matchbox is calculated according to its boxheight suboption. The boxheight suboption<br />

determines the extent of the text above and below the baseline.<br />

matchbox={boxheight={capheight none}} is the default setting, i.e. the top border of the<br />

matchbox will touch the capheight above the baseline, and the bottom border of the<br />

matchbox will not extend below the baseline.<br />

202 Chapter 8: Text and Table Formatting (Edition for <strong>COM</strong>, .<strong>NET</strong>, and REALbasic)

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

Saved successfully!

Ooh no, something went wrong!