Explain how to control the metadata settings in the template pages. What exactly do I have to do to change the default behaviour?
Print layout is controlled through metadata settings whose default values are defined on various template pages in the Site group. Tip 00017 described how this works and gave a few illustrative examples. It explained how an author can control printed behaviour in 3 complementary ways:
This tip looks at the first option, per page customisation, in more detail. Let us use an example to illustrate exactly how to over-ride the default print layout settings, as defined on the Site template pages. Suppose we want to change 3 of the default settings:
|Metadata name||Value options||Meaning|
|colorlinks||check on||checkbox with default off|
|imagesize||*regular;small;sidecaps|side captions;rotate|allow rotation||radio buttons with default regular|
|floathere||figures;tables;cfloats|custom floats;on|all floats;*off||radio buttons with default off|
We wish to generate a PDF of the page with coloured hyperlink text, side captions on images, and float tables “here” if they will fit. Example of per-page metadata shows how to do this.
(:typeset-page colorlinks=on imagesize=sidecaps floathere=tables:)
PDF settings (show)
The imagesize template entry reads “sidecaps|side captions” — this needs an explanation. It tells the wikiforms processor to use “sidecaps” as the radio button value and “side captions” as the display text for that button. So we need to set the value in our typeset directive.
Once we have set the values for the page, a reader cannot over-ride them. Press the PDF options button and notice that these 3 values are fixed and cannot be changed.