XML-Technologien / XSL-FO / Referenz / Antenna House Formatter XSL Extensions / Properties / base-uri
(Auszug aus "XSL-FO ― Die Referenz" von Manuel Montero Pineda & Steffen Herkert, 2016, dpunkt.verlag)
A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z
Category URI and Link
The axf:base-uri specifies the location which becomes the base of relative URI.
Value: | <uri-specification> |
Initial: | empty string |
Applies to: | all formatting objects |
Inherited: | yes |
Percentages: | N/A |
The axf:base-uri is applied to all relative URI in a document. When making links using fo:basic-link and specify relative URI, the location that is specified using axf:base-uri is interpreted to be base URI. If this property is omitted or this has empty string, the base location is interpreted as current XML file.
In the case of the following example, it links to: "http://www.antennahouse.co.jp/xsl-info/Thai/THAI-BangKokNationalMuseum.pdf".
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:axf="http://www.antennahouse.com/names/XSL/Extensions" axf:base-uri="http://www.antennahouse.co.jp/xsl-info/"> : : <fo:basic-link external-destination="Thai/THAI-BangKokNationalMuseum.pdf"> ... </fo:basic-link>
XSL-FO sample:
<fo:root axf:base-uri="http://www.antenna.co.jp/AHF/ahf_samples/ja/" writing-mode="lr-tb" hyphenate="true" text-align="start" xml:lang="ja" font-family="Arial, 'MS ゴシック', sans-serif" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:cpfo="http://www.compart.net/xmlns/cpfo" xmlns:svg="http://www.w3.org/2000/svg" xmlns:axf="http://www.antennahouse.com/names/XSL/Extensions">
<fo:layout-master-set>
<fo:simple-page-master page-height="257mm" page-width="182mm" margin-top="6.36mm" margin-left="12.7mm" margin-right="6.36mm" margin-bottom="6.36mm" master-name="OddPage">
<fo:region-before region-name="OddPageHeader" extent="3.55mm" background-color="pink"/>
<fo:region-after region-name="OddPageFooter" extent="4.45mm" background-color="yellow"/>
<fo:region-start extent="0mm"/>
<fo:region-end extent="0mm"/>
<fo:region-body margin-top="3.55mm" margin-left="0mm" margin-right="0mm" margin-bottom="4.45mm"/>
</fo:simple-page-master>
<fo:simple-page-master page-height="257mm" page-width="182mm" margin-top="6.36mm" margin-left="6.36mm" margin-right="12.7mm" margin-bottom="6.36mm" master-name="EvenPage">
<fo:region-before region-name="EvenPageHeader" extent="3.55mm" background-color="pink"/>
<fo:region-after region-name="EvenPageFooter" extent="4.45mm" background-color="yellow"/>
<fo:region-start extent="0mm"/>
<fo:region-end extent="0mm"/>
<fo:region-body margin-top="3.55mm" margin-left="0mm" margin-right="0mm" margin-bottom="4.45mm"/>
</fo:simple-page-master>
<fo:page-sequence-master master-name="main">
<fo:repeatable-page-master-alternatives>
<fo:conditional-page-master-reference master-reference="OddPage" odd-or-even="odd"/>
<fo:conditional-page-master-reference master-reference="EvenPage" odd-or-even="even"/>
</fo:repeatable-page-master-alternatives>
</fo:page-sequence-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="main" font-family="serif" line-height="1.6">
<fo:flow flow-name="xsl-region-body">
<fo:block font-size="2em" font-weight="bold">
AH Formatter V6 サンプル集
</fo:block>
<fo:block text-align="end">
最終更新日:2016年9月12日
</fo:block>
<fo:block text-align="center" font-size="2em" font-weight="bold">
目次
</fo:block>
<fo:block font-size="1.2em" start-indent="1em" font-weight="bold">
ページの領域と構造に関する見本
</fo:block>
<fo:block start-indent="2em">
XSL 基本仕様のサンプル
</fo:block>
<fo:block text-align-last="justify" start-indent="3em" end-indent="2em">
ページ内の各領域の紹介
<fo:leader leader-pattern="dots" baseline-shift="3pt"/>
<fo:basic-link internal-destination="p10">
<fo:page-number-citation ref-id="p10"/>
</fo:basic-link>
</fo:block>
</fo:flow>
</fo:page-sequence>
<fo:page-sequence master-reference="main">
<fo:static-content flow-name="OddPageHeader">
<fo:block font-size="0.8em" text-align="outside" line-height="4mm">
<fo:retrieve-marker retrieve-position="first-starting-within-page" retrieve-class-name="header-section-title"/>
</fo:block>
</fo:static-content>
<fo:static-content flow-name="EvenPageFooter">
<fo:block font-size="9pt" text-align="outside" line-height="4mm">
<fo:inline font-size="9.5pt">
<fo:page-number/>
|
</fo:inline>
<fo:retrieve-marker retrieve-boundary="page-sequence" retrieve-position="first-starting-within-page" retrieve-class-name="section-title"/>
</fo:block>
</fo:static-content>
<fo:static-content flow-name="OddPageFooter">
<fo:block font-size="9pt" text-align="outside" line-height="4mm">
<fo:retrieve-marker retrieve-boundary="page-sequence" retrieve-position="first-starting-within-page" retrieve-class-name="section-title"/>
<fo:inline font-size="9.5pt">
|
<fo:page-number/>
</fo:inline>
</fo:block>
</fo:static-content>
<fo:flow flow-name="xsl-region-body">
<fo:block>
<fo:marker marker-class-name="header-section-title">
ページの領域と構造に関する見本
</fo:marker>
<fo:block font-family="serif" line-height="6mm" id="p10">
ページ内の各領域の紹介
</fo:block>
</fo:block>
<fo:block margin="0" padding="0" space-before="0" border="solid 0.1pt black" text-align="center" line-height="1">
<fo:external-graphic src="./fo/structure/region-1.pdf#page=1-" content-width="162.2mm"/>
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>Output:

page 2