I have two master page templates and i'd like them to inherit some common properties from a 3rd master. Can this be done? Below is an example of what i'm attempting.
<fo:layout-master-set>
<fo:simple-page-master master-name="page" page-width="8.5in"
page-height="11in" margin=".5in 1in 0in 1in"/>
<fo:simple-page-master master-name="first" master-reference="page">
<fo:region-before region-name="header" extent=".75in"/>
<fo:region-body region-name="body" margin-top=".5in" margin-bottom=".75in"/>
<fo:region-after region-name="footer" extent=".75in"/>
</fo:simple-page-master>
<fo:simple-page-master master-name="rest" master-reference="page">
<fo:region-body region-name="body" margin-top=".5in" margin-bottom=".75in"/>
<fo:region-after region-name="footer" extent=".75in"/>
</fo:simple-page-master>
</fo:layout开发者_Go百科-master-set>
I'm attempting to inherit the page dimensions from the "page" master.
No, it is not possible to "inherit" like that. A fo:simple-page-master
element does not take a master-reference
attribute (and it cannot be empty).
If you use XSLT to generate your XSL-FO, you might want to use named attribute-sets (reusable collections of attributes; XSLT 2.0, XSLT 1.0).
精彩评论