Previous

Table of Contents

Bottom     

Next     


Quick Table of Contents
1 Introduction and Overview
    1.1 Processing a Stylesheet
    1.2 Benefits of XSL

1 Introduction and Overview導入及び概要

This specification defines the Extensible Stylesheet Language (XSL). この規定この標準仕様書(TS)は,拡張可能なスタイルシート言語(XSL)を定義する。 XSL is a language for expressing stylesheets. XSLは,スタイルシートを表現する言語である。 Given a class of arbitrarily structured XML [XML] or [XML 1.1] documents or data files, designers use an XSL stylesheet to express their intentions about how that structured content should be presented; that is, how the source content should be styled, laid out, and paginated onto some presentation medium, such as a window in a Web browser or a hand-held device, or a set of physical pages in a catalog, report, pamphlet, or book. 任意に構造化されたXML([XML 1.0]又は[XML 1.1])文書又はデータファイルのクラスがあるとき,設計者は,XSLスタイルシートを使用して,その構造化された内容をどのように表示するのが望ましいか,すなわち,ウェブブラウザ又はハンドヘルド装置のウィンドウ,又はカタログ,報告書,パンフレットや書籍における物理的なページの集合,といった表示メディア上に,ソース内容がどのようにスタイル付けされ,レイアウトされ,ページ付けされるのが望ましいか,に関する設計者の意図を表現する

注記

原規定では,外部文書への参照は,[XML 1.0]などといった記述から参照箇所にリンクされている。ただし,この規格標準仕様書(TS)では参照箇所へのリンクは記載しない。代わりに,この記法によって,附属書Cの対応する項目を参照する。

1.1 Processing a Stylesheet スタイルシートの処理

An XSL stylesheet processor accepts a document or data in XML and an XSL stylesheet and produces the presentation of that XML source content that was intended by the designer of that stylesheet. XSLスタイルシートプロセサは,XMLの文書又はデータ,及びXSLスタイルシートを受け取って,そのスタイルシートの設計者が意図したXMLソース内容の表示を作成する。 There are two aspects of this presentation process: この表示処理には二つの局面が存在する。 first, constructing a result tree from the XML source tree and second, interpreting the result tree to produce formatted results suitable for presentation on a display, on paper, in speech, or onto other media. 第1は,XMLのソース木から結果木を構築することであり,第2は,結果木を解釈して,ディスプレイ上,紙面上,音声,又はその他のメディア上での表示に適するフォーマット結果を生成することである。 The first aspect is called tree transformation and the second is called formatting. 第1の局面を木変換と呼び,第2の局面をフォーマット化と呼ぶ。 The process of formatting is performed by the formatter. フォーマット化の処理はフォーマッタが実行する。 This formatter may simply be a rendering engine inside a browser. このフォーマッタは,単にウェブブラウザ内のレンダリングエンジンであってもよい。

Tree transformation allows the structure of the result tree to be significantly different from the structure of the source tree. 木変換は,結果木の構造をソース木の構造とは大きく異なるものにすることを可能にする。 For example, one could add a table-of-contents as a filtered selection of an original source document, or one could rearrange source data into a sorted tabular presentation. 例えば,元のソース文書をフィルタ処理した選択として目次を追加できたり,ソースデータをソートされた表形式の表示に再整理できたりする。 In constructing the result tree, the tree transformation process also adds the information necessary to format that result tree. 結果木を構築する際に,木変換処理は,その結果木をフォーマットするのに必要な情報も追加する。

Formatting is enabled by including formatting semantics in the result tree. フォーマット化は,結果木にフォーマット化セマンティクスを含めることによって可能となる。 Formatting semantics are expressed in terms of a catalog of classes of formatting objects. フォーマット化セマンティクスは,フォーマット化オブジェクトのクラスのカタログによって表現される。 The nodes of the result tree are formatting objects. 結果木のノードがフォーマット化オブジェクトになる。 The classes of formatting objects denote typographic abstractions such as page, paragraph, table, and so forth. フォーマット化オブジェクトのクラスは,ページ,段落,表などの組版抽象化を示す。 Finer control over the presentation of these abstractions is provided by a set of formatting properties, such as those controlling indents, word- and letter spacing, and widow, orphan, and hyphenation control. 字下げ制御,単語間隔及び文字間隔の制御,ウィドウ及びオーファンの制御,並びにハイフン付けの制御といったフォーマット化特性の集合によって,これらの抽象化の表示に関するより精密な制御が与えられる。 In XSL, the classes of formatting objects and formatting properties provide the vocabulary for expressing presentation intent. XSLでは,フォーマット化オブジェクト及びフォーマット化特性のクラスが,表示の意図を表現するための語彙語い(彙)を与える。

The XSL processing model is intended to be conceptual only. XSL処理モデルは,概念的であることだけを意図している。 An implementation is not mandated to provide these as separate processes. 実装は,これらを別の処理として提供することを必須必す(須)(以降“必須”と表記する)としていない。 Furthermore, implementations are free to process the source document in any way that produces the same result as if it were processed using the conceptual XSL processing model. 更に,実装は,概念的XSL処理モデルを使用して処理される場合と同じ結果を生成するのならば,どのような方法でソース文書を処理してもよい。 A diagram depicting the detailed conceptual model is shown below. 詳細な概念的モデルを描いた図を図1.1に示す。

The XSL two processes: transformation and formatting   [D]

XSL Two Processes: Transformation & Formatting 図1.1 — XSLの二つの処理,変換及びフォーマット化

1.1.1 Tree Transformations 木変換

Tree transformation constructs the result tree. 木変換が結果木を構築する。 In XSL, this tree is called the element and attribute tree, with objects primarily in the "formatting object" namespace. XSLでは,この木は要素及び属性の木と呼ばれ,主として“フォーマット化オブジェクト”名前空間(以下fo名前空間と略す)の中のオブジェクトをもつ。 In this tree, a formatting object is represented as an XML element, with the properties represented by a set of XML attribute-value pairs. この木では,フォーマット化オブジェクトは,XML要素として表現され,XMLの属性及び値のペアの集合によって表現される特性をもつ。 The content of the formatting object is the content of the XML element. フォーマット化オブジェクトの内容は,XML要素の内容である。 Tree transformation is defined in the XSLT Recommendation [XSLT]. 木変換は,XSLT勧告[XSLT]で規定される。 A diagram depicting this conceptual process is shown below. この概念的処理を描いた図を図1.2に示す。

The XSL Transformation process   [D]

Transform to Another Vocabulary 図1.2 — 他の語彙語い(彙)への変換

The XSL stylesheet is used in tree transformation. XSLスタイルシートは木変換で使用される。 A stylesheet contains a set of tree construction rules. スタイルシートは木構築規則の集合を含む。 The tree construction rules have two parts: 木構築規則は二つの部分をもつ。 a pattern that is matched against elements in the source tree and a template that constructs a portion of the result tree. その一つはソース木の中の要素とマッチするパタンであり,もう一つは結果木の一部を構築するテンプレートである。 This allows a stylesheet to be applicable to a wide class of documents that have similar source tree structures. これによって,類似したソース木構造をもつ広範な分野の文書に対してスタイルシートを適用することが可能になる。

In some implementations of XSL/XSLT, the result of tree construction can be output as an XML document. XSLXSLTの実装には,木構築の結果をXML文書として出力できるものもある。 This would allow an XML document which contains formatting objects and formatting properties to be output. これは,フォーマット化オブジェクト及びフォーマット化特性を含むXML文書を出力することを可能にする。 This capability is neither necessary for an XSL processor nor is it encouraged. この機能は,XSLプロセサにとって必要なものではなく,奨励されてもいない。 There are, however, cases where this is important, such as a server preparing input for a known client; しかし,既知のクライアントのための入力を準備するサーバのように,これが重要となる場合がある。 for example, the way that a WAP (http://www.wapforum.org/faqs/index.htm) server prepares specialized input for a WAP capable hand held device. 例えば,WAP(http://www.wapforum.org/faqs/index.htm)サーバが,WAP処理可能なハンドヘルド装置のために特殊化された入力を準備する方法がこの場合にあたる。 To preserve accessibility, designers of Web systems should not develop architectures that require (or use) the transmission of documents containing formatting objects and properties unless either the transmitter knows that the client can accept formatting objects and properties or the transmitted document contains a reference to the source document(s) used in the construction of the document with the formatting objects and properties. クライアントがフォーマット化のオブジェクト及び特性を受け取ることができることを送信側が知らないか,又は送信された文書がフォーマット化のオブジェクト及び特性をもつ文書の構築に際して使用されるソース文書への参照を含まないかのいずれかの場合,アクセス可能性を保つために,ウェブシステムの設計者は,フォーマット化のオブジェクト及び特性を含む文書の送信を要求(又は使用)する体系を開発しないことが望ましい。

1.1.2 Formatting フォーマット化

Formatting interprets the result tree in its formatting object tree form to produce the presentation intended by the designer of the stylesheet from which the XML element and attribute tree in the "fo" namespace was constructed. フォーマット化は,フォーマット化オブジェクト木形式の結果木を解釈し,fo名前空間におけるXMLの要素及び属性の木が構築されたスタイルシートの設計者が意図する表示を生成する。

The vocabulary of formatting objects supported by XSL - the set of fo: element types - represents the set of typographic abstractions available to the designer. XSLが対応するフォーマット化オブジェクトの語彙語い(彙),つまりfo:要素型の集合は,設計者に利用可能な組版抽象化の集合を表現する。 Semantically, each formatting object represents a specification for a part of the pagination, layout, and styling information that will be applied to the content of that formatting object as a result of formatting the whole result tree. セマンティクスの上では,各フォーマット化オブジェクトは,ページ付け,レイアウト及びスタイル付けの情報の一部に関する規定を表現する。それらの情報は,結果木全体をフォーマット化した結果として,そのフォーマット化オブジェクトの内容に適用される。 Each formatting object class represents a particular kind of formatting behavior. 各フォーマット化オブジェクトのクラスは,特定の種類のフォーマット化の振舞いを表現する。 For example, the block formatting object class represents the breaking of the content of a paragraph into lines. 例えば,ブロックフォーマット化オブジェクトクラスは,段落内容の行への分割を表現する。 Other parts of the specification may come from other formatting objects; 規定の他の部分は,他のフォーマット化オブジェクトから導かれてもよい。 for example, the formatting of a paragraph (block formatting object) depends on both the specification of properties on the block formatting object and the specification of the layout structure into which the block is placed by the formatter. 例えば,段落のフォーマット化(ブロックフォーマット化オブジェクト)は,ブロックフォーマット化オブジェクトの特性の規定にも,フォーマッタがブロックを配置するレイアウト構造の規定にも依存する。

The properties associated with an instance of a formatting object control the formatting of that object. フォーマット化オブジェクトのインスタンスと関連付けされる特性は,そのオブジェクトのフォーマット化を制御する。 Some of the properties, for example "color", directly specify the formatted result. 例えば“color”などの幾つかの特性は,フォーマット結果を直接指定する。 Other properties, for example 'space-before', only constrain the set of possible formatted results without specifying any particular formatted result. “space-before”などの他の特性は,特定のフォーマット結果を指定せず,可能なフォーマット結果の集合を制約するだけである。 The formatter may make choices among other possible considerations such as esthetics. フォーマッタは,例えば概観など他の観点から選択を行うこともできる。

Formatting consists of the generation of a tree of geometric areas, called the area tree. フォーマット化は,領域木と呼ばれる幾何的領域の木の生成から成る。 The geometric areas are positioned on a sequence of one or more pages (a browser typically uses a single page). 幾何的領域は,一連のいくつかのページ(ウェブブラウザは通常,1ページを使用する)上に位置付けされる。 Each geometric area has a position on the page, a specification of what to display in that area and may have a background, padding, and borders. 各幾何的領域は,ページの上に置かれ,その領域に何を表示するかの指定をもつ。背景,パディング及び境界をもってもよい。 For example, formatting a single character generates an area sufficiently large enough to hold the glyph that is used to present the character visually and the glyph is what is displayed in this area. 例えば,単一文字のフォーマット化は,文字を視覚的に表示するのに使うグリフを保持するために十分な大きさの領域を生成し,このグリフがこの領域に表示される。 These areas may be nested. これらの領域は入れ子になってもよい。 For example, the glyph may be positioned within a line, within a block, within a page. 例えば,グリフは,行内,ブロック内,ページ内などに位置付けされてもよい。

Rendering takes the area tree, the abstract model of the presentation (in terms of pages and their collections of areas), and causes a presentation to appear on the relevant medium, such as a browser window on a computer display screen or sheets of paper. レンダリングは,領域木,すなわち(領域のページ及びその集まりによる)表示の抽象モデルを取り込んで,コンピュータ表示画面上のウェブブラウザウィンドウ又は紙シートなどの関連メディア上へ表示を行う。 The semantics of rendering are not described in detail in this specification. この規定この標準仕様書(TS)では,レンダリングのセマンティクスは,詳細に記述されない。

The first step in formatting is to "objectify" the element and attribute tree obtained via an XSLT transformation. フォーマット化の第1段階は,XSLT変換によって得られる要素及び属性の木を“オブジェクト化する”ことである。 Objectifying the tree basically consists of turning the elements in the tree into formatting object nodes and the attributes into property specifications. 木をオブジェクト化することとは,基本的には,木の要素をフォーマット化オブジェクトノードに転じ,属性を特性指定に転じることから構成される。 The result of this step is the formatting object tree. この段階の結果は,フォーマット化オブジェクト木となる。

Objectification of the FO tree   [D]

Build the XSL Formatting Object Tree 図1.3 — XSLフォーマット化オブジェクト木の構築

As part of the step of objectifying, the characters that occur in the result tree are replaced by fo:character nodes. オブジェクト化の段階の一部として,結果木に現れる文字は,fo:characterノードによって置換される。 Characters in text nodes which consist solely of white space characters and which are children of elements whose corresponding formatting objects do not permit fo:character nodes as children are ignored. 空白文字だけから構成され,対応するフォーマット化オブジェクトがfo:characterノードを子として許容しない要素の子であるテキストノードの文字は無視される。 Other characters within elements whose corresponding formatting objects do not permit fo:character nodes as children are errors. 対応するフォーマット化オブジェクトがfo:characterノードを子として許容しない要素内の他の文字は誤りである。

The content of the fo:instream-foreign-object is not objectified; fo:instream-foreign-objectの内容はオブジェクト化されない。 instead the object representing the fo:instream-foreign-object element points to the appropriate node in the element and attribute tree. その代わりに,fo:instream-foreign-object要素を表現するオブジェクトは,要素及び属性の木の適切なノードを指し示す。 Similarly any non-XSL namespace child element of fo:declarations is not objectified; 同様に,fo:declarationのどのような非XSL名前空間の子要素もオブジェクト化されない。 instead the object representing the fo:declarations element points to the appropriate node in the element and attribute tree. その代わりに,fo:declaration要素を表現するオブジェクトは,要素及び属性の木の適切なノードを指し示す。

The second phase in formatting is to refine the formatting object tree to produce the refined formatting object tree. フォーマット化の第2段階は,フォーマット化オブジェクト木を洗練化し,洗練化されたフォーマット化オブジェクト木を生成することである。 The refinement process handles the mapping from properties to traits. 洗練化の過程は,特性(property)から特色(trait)への対応付けを扱う。 This consists of: これは,次からなる。 (1) shorthand expansion into individual properties, (2) mapping of corresponding properties, (3) determining computed values (may include expression evaluation), (4) handling white-space-treatment and linefeed-treatment property effects, and (5) inheritance. Details on refinement are found in 5 Property Refinement / Resolution.

  1. 個々の特性への簡略記述の展開。
  2. 対応する特性の対応付け。
  3. 計算値の決定(式評価を含んでもよい)。
  4. white-space-treatment特性及びlinefeed-treatment特性の効果の取扱い。
  5. 継承。

洗練化の詳細については,5 特性の洗練化及び解決 にある。

The refinement step is depicted in the diagram below. 洗練化の段階を,図1.4に示す。

Refinement of the FO tree   [D]

Refine the Formatting Object Tree 図1.4 — フォーマット化オブジェクト木の洗練化

The third step in formatting is the construction of the area tree. フォーマット化の第3段階は,領域木の構築である。 The area tree is generated as described in the semantics of each formatting object. 領域木は,各フォーマット化オブジェクトのセマンティクスに記述されるとおりに生成される。 The traits applicable to each formatting object class control how the areas are generated. 各フォーマット化オブジェクトクラスに適用可能な特色は,領域の生成方法を制御する。 Although every formatting property may be specified on every formatting object, for each formatting object class, only a subset of the formatting properties are used to determine the traits for objects of that class. すべてのフォーマット化特性は,すべてのフォーマット化オブジェクトに指定されてもよいが,各フォーマット化オブジェクトクラスに対しては,フォーマット化特性の部分集合だけが,そのクラスのオブジェクトのための特色を決定するのに使われる。

Area generation is depicted in the diagram below. 領域生成を図1.5と図1.6に示す。

Area tree generation   [D]

Generate the Area Tree 図1.5 — 領域木の生成

FO-to-area process summary   [D]

Summary of the Process 図1.6 — 処理の概要

1.2 Benefits of XSL XSLの利点

Unlike the case of HTML, element names in XML have no intrinsic presentation semantics. HTMLの場合と異なり,XMLの要素名は,基本の表示セマンティクスをもたない。 Absent a stylesheet, a processor could not possibly know how to render the content of an XML document other than as an undifferentiated string of characters. スタイルシートなしには,プロセサは,画一的な文字列として以外に,XML文書の内容をどのようにレンダリングするかを知ることはできない。 XSL provides a comprehensive model and a vocabulary for writing such stylesheets using XML syntax. XSLは,XML構文を用いてスタイルシートを書くための広範なモデル及び語彙語い(彙)を提供する。

This document is intended for implementors of such XSL processors. この文書は,これらのXSLプロセサを実装する者のためのものである Although it can be used as a reference manual for writers of XSL stylesheets, it is not tutorial in nature. XSLスタイルシートを書く者のための参照マニュアルとしてこの文書を使用することはできるが,この文書は,本来,解説資料ではない。

XSL builds on the prior work on Cascading Style Sheets [CSS2] and the Document Style Semantics and Specification Language [DSSSL]. XSLは,段階スタイルシート[CSS2]及び文書スタイル意味指定言語[DSSSL]の先行する作業の上に構築されている。 While many of XSL's formatting objects and properties correspond to the common set of properties, this would not be sufficient by itself to accomplish all the goals of XSL. XSLのフォーマット化のオブジェクト及び特性の多くは,特性の共通的な集合に対応するが,それだけでは,XSLのすべての目的を達成するのに十分ではない。 In particular, XSL introduces a model for pagination and layout that extends what is currently available and that can in turn be extended, in a straightforward way, to page structures beyond the simple page models described in this specification. 特にXSLは,ページ付け及びレイアウトのモデルを導入している。これは,現在利用可能なものを拡張し,この規定この標準仕様書(TS)に示される簡単なページモデルを越えるページ構造へと,直接的な方法で順次拡張することができる。

1.2.1 Paging and Scrolling ページ送り及びスクロール

Doing both scrollable document windows and pagination introduces new complexities to the styling (and pagination) of XML content. スクロール可能な文書ウィンドウ及びページ付けの両方を実行することは,XML内容のスタイル付け(及びページ付け)に新たな複雑さを招く。 Because pagination introduces arbitrary boundaries (pages or regions on pages) on the content, concepts such as the control of spacing at page, region, and block boundaries become extremely important. ページ付けは,内容の上に任意の境界(ページ又はページ上の区画)を導入するので,ページ,区画及びブロック境界における間隔の制御などの概念が極めて重要になる。 There are also concepts related to adjusting the spaces between lines (to adjust the page vertically) and between words and letters (to justify the lines of text). (ページを上下方向に調整するための)行間の間隔調整,並びに(テキストを両端揃えするための)単語及び文字の間の間隔調整に関連する概念も存在する。 These do not always arise with simple scrollable document windows, such as those found in today's browsers. これらは,必ずしも今日のウェブブラウザに見られるような,単純でスクロール可能な文書ウィンドウで生ずるものとは限らない。 However, there is a correspondence between a page with multiple regions, such as a body, header, footer, and left and right sidebars, and a Web presentation using "frames". しかし,本体,上下の余白及び左右の余白といった多くの区画をもつページと,“フレーム”を使用するウェブ表示との間には一致がある。 The distribution of content into the regions is basically the same in both cases, and XSL handles both cases in an analogous fashion. 区画への内容の分配は,基本的にはいずれの場合においても同じであって,XSLは,類似の方法で両方の場合を扱う。

XSL was developed to give designers control over the features needed when documents are paginated as well as to provide an equivalent "frame" based structure for browsing on the Web. XSLは,ウェブ上での閲覧に関して等価な“フレーム”に基づく構造を与えるためだけでなく,文書がページ付けされるときに必要な機能に対する制御を設計者に与えるために開発された。 To achieve this control, XSL has extended the set of formatting objects and formatting properties beyond those available in either CSS2 or DSSSL. この制御を達成するために,XSLは,CSS2又はDSSSLで利用可能なそれらを超えて,フォーマット化オブジェクト及びフォーマット化特性の集合を拡張した。 In addition, the selection of XML source components that can be styled (elements, attributes, text nodes, comments, and processing instructions) is based on XSLT and XPath [XPath], thus providing the user with an extremely powerful selection mechanism. 更に,スタイル付け可能なXMLソース構成要素(要素,属性,テキストノード,注釈及び処理命令)の選択は,XSLT及びXPath[XPath]に基づいており,利用者に極めて強力な選択機構を提供する。

The design of the formatting objects and properties extensions was first inspired by DSSSL. フォーマット化のオブジェクト及び特性の拡張の設計は,最初はDSSSLによる影響を受けた。 The actual extensions, however, do not always look like the DSSSL constructs on which they were based. しかし実際の拡張は,その基礎となったDSSSL構築要素に必ずしも類似してはいない。 To either conform more closely with the CSS2 specification or to handle cases more simply than in DSSSL, some extensions have diverged from DSSSL. CSS2規定により忠実に準拠させるか,又はDSSSLよりも簡単に問題に対処するかのいずれかのために,DSSSLから離れた拡張もある。

There are several ways in which extensions were made. 拡張が行われた方法には幾つかある。 In some cases, it sufficed to add new values, as in the case of those added to reflect a variety of writing-modes, such as top-to-bottom and bottom-to-top, rather than just left-to-right and right-to-left. 表記方向が右向き及び左向きだけでなく,下向き及び上向きといった多様な表記方法を反映するために値を追加した場合など,新しい値を追加することで十分だった場合がある。

In other cases, common properties that are expressed in CSS2 as one property with multiple simultaneous values, were split into several new properties to provide independent control over independent aspects of the property. 同時に複数の値をもつ一つの特性としてCSS2で表現される共通特性を,その特性の独立の側面を独立に制御するために,幾つかの新しい特性に分割する場合もある。 For example, the "white-space" property was split into four properties: a "white-space-treatment" property that controls how white space is processed, a "linefeed-treatment" property that controls how line feeds are processed, a "white-space-collapse" property that controls how multiple consecutive spaces are collapsed, and a "wrap-option" property that controls whether lines are automatically wrapped when they encounter a boundary, such as the edge of a column. 例えば,“white-space”特性は,次の四つの特性,すなわち,どのように空白を処理するかを制御する“space-treatment”特性,どのように改行を処理するかを制御する“linefeed-treatment”特性,複数の連続する空白をどのように縮退するかを制御する“white-space-collapse”特性,及び行が段の端などの境界に遭遇した際に行が自動的にどのようにラップされるかを制御する“wrap-option”特性,に分割された。 The effect of splitting a property into two or more (sub-)properties is to make the equivalent existing CSS2 property a "shorthand" for the set of sub-properties it subsumes. 一つの特性を複数の(下位)特性に分割することの効果は,等価な既存のCSS2の特性を,それが含まれる下位特性の集合に対する“簡略記述”とすることになる。

In still other cases, it was necessary to create new properties. 更に,新しい特性を生成することが必要になった他の場合もある。 For example, there are a number of new properties that control how hyphenation is done. 例えば,どのようにハイフン付けを行うかを制御する,多くの新しい特性がある。 These include identifying the script and country the text is from as well as such properties as "hyphenation-character" (which varies from script to script). これらは,(スクリプトごとに変化する)“hyphenation-character”などの特性だけでなく,テキストが属するスクリプト及び国名を識別することを含んでいる。

Some of the formatting objects and many of the properties in XSL come from the CSS2 specification, ensuring compatibility between the two. XSLにおける幾つかのフォーマット化オブジェクト及び多くの特性は,CSS2規定から来ており,両者間の互換性を確保している。

There are four classes of XSL properties that can be identified as: XSL特性には,次のように識別可能な四つのクラスが存在する。

  1. CSS properties by copy (unchanged from their CSS2 semantics) 複製によるCSS2特性(CSS2のセマンティクスからの変更はない)。

  2. CSS properties with extended values 拡張された値をもつCSS特性。

  3. CSS properties broken apart and/or extended 分離及び/又は拡張されたCSS特性。

  4. XSL-only properties XSLだけの特性。

1.2.2 Selectors and Tree Construction 選択子及び木構築

As mentioned above, XSL uses XSLT and XPath for tree construction and pattern selection, thus providing a high degree of control over how portions of the source content are presented, and what properties are associated with those content portions, even where mixed namespaces are involved. 前述のとおり,XSLは木構築及びパタン選択のためにXSLT及びXPathを使用し,混在した名前空間が関与する場合でも,どのようにソース内容の部分が表示されるか,及びどの特性がその内容部分と関連付けされるかに対して高度の制御を与える。

For example, the patterns of XPath allow the selection of a portion of a string or the Nth text node in a paragraph. 例えば,XPathのパタンは,文字列の一部又は段落のN番目のテキストノードの選択を可能にする。 This allows users to have a rule that makes all third paragraphs in procedural steps appear in bold, for instance. これによって利用者は,例えば,処理段階にある第3番目の段落すべてを太字で表すという規則をもつことができる。 In addition, properties can be associated with a content portion based on the numeric value of that content portion or attributes on the containing element. 更に,包含要素の内容部分又は属性の数値に基づいて,特性をその内容部分と関連付けることができる。 This allows one to have a style rule that makes negative values appear in "red" and positive values appear in "black". これによって,負の値を“赤”で表し,正の値を“黒”で表すというスタイル付け規則をもつことができる。 Also, text can be generated depending on a particular context in the source tree, or portions of the source tree may be presented multiple times with different styles. ソース木の特定の文脈に依存してテキストを生成できたり,ソース木の一部を異なるスタイルで複数回表示したりすることも可能になる。

1.2.3 An Extended Page Layout Model 拡張ページレイアウトモデル

There is a set of formatting objects in XSL to describe both the layout structure of a page or "frame" (how big is the body; are there multiple columns; are there headers, footers, or sidebars; how big are these) and the rules by which the XML source content is placed into these "containers". XSLには,フォーマット化オブジェクトとして,ページ又はフレームのレイアウト構造(本体の大きさはどのくらいか,複数の段があるか,上下余白又は側線があるか,これらの大きさはどのくらいかなど),及びXMLソース内容をこれらの“コンテナ”に配置する規則が存在する。

The layout structure is defined in terms of one or more instances of a "simple-page-master" formatting object. レイアウト構造は,“単純ページマスタ”フォーマット化オブジェクトの一つ以上のインスタンスによって定義される。 This formatting object allows one to define independently filled regions for the body (with multiple columns), a header, a footer, and sidebars on a page. このフォーマット化オブジェクトは,ページ上の(複数の段をもつ)本体,上下余白及び側線に対して,独立して埋められる区画を定義することができる。 These simple-page-masters can be used in page sequences that specify in which order the various simple-page-masters shall be used. これらの単純ページマスタは,その様々な単純ページマスタをどの順序で使わなければならないかを指定するページシーケンスにおいて使用できる。 The page sequence also specifies how styled content is to fill those pages. ページシーケンスは,どのようにスタイル付けされた内容がそれらのページを埋めるかをも指定する。 This model allows one to specify a sequence of simple-page-masters for a book chapter where the page instances are automatically generated by the formatter or an explicit sequence of pages such as used in a magazine layout. このモデルは,ページのインスタンスがフォーマッタによって自動的に生成される本の章のための単純ページマスタのシーケンスを指定したり,雑誌のレイアウトで使われるような明示的なページシーケンスを指定することを可能にする。 Styled content is assigned to the various regions on a page by associating the name of the region with names attached to styled content in the result tree. スタイル付けされた内容は,区画の名前を,結果木のスタイル付けされた内容に付加される名前に関連付けることによって,ページの様々な区画に割り当てられる。

In addition to these layout formatting objects and properties, there are properties designed to provide the level of control over formatting that is typical of paginated documents. これらのレイアウトフォーマット化のオブジェクト及び特性に加えて,ページ付けされた文書に典型的なフォーマット化に対して,制御のレベルを提供するために設計された特性が存在する。 This includes control over hyphenation, and expanding the control over text that is kept with other text in the same line, column, or on the same page. これは,ハイフン付けに対する制御を含み,同一の行若しくは段の中にある,又は同一のページ上にある他のテキストに続くテキストに対する制御の展開を含む。

1.2.4 A Comprehensive Area Model 広範な領域モデル

The extension of the properties and formatting objects, particularly in the area on control over the spacing of blocks, lines, and page regions and within lines, necessitated an extension of the CSS2 box formatting model. 特性及びフォーマット化オブジェクトの拡張,特に,ブロック,行及びページ区画の間隔に対する制御,並びに行内制御に関する領域でのそれらの拡張は,CSS2のボックスフォーマット化モデルの拡張を必要とした。 This extended model is described in 4 Area Model of this specification. この拡張モデルは,この規定この標準仕様書(TS)4 領域モデル に示される。 The CSS2 box model is a subset of this model. CSS2のボックスモデルは,このモデルの部分集合である。 See the mapping of the CSS2 box model terminology to the XSL Area Model terminology in 7.2 XSL Areas and the CSS Box Model. 7.2 XSL領域及びCSSボックスモデル における,CSS2のボックスモデルの用語とXSL領域モデルの用語との対応付けを参照されたい。 The area model provides a vocabulary for describing the relationships and space-adjustment between letters, words, lines, and blocks. 領域モデルは,文字,単語,行及びブロックの間の関係と,間隔調整との記述のための語彙語い(彙)を提供する。

1.2.5 Internationalization and Writing-Modes 国際化及び表記方法

There are some scripts, in particular in the Far East, that are typically set with words proceeding from top-to-bottom and lines proceeding either from right-to-left (most common) or from left-to-right. 特に極東がそうだが,下向きに文字が進行し,左向き(最も普通)又は右向きのいずれかに行が進行するのを典型的な設定とするスクリプトがある。 Other directions are also used. 他の方向も使用される。 Properties expressed in terms of a fixed, absolute frame of reference (using top, bottom, left, and right) and which apply only to a notion of words proceeding from left to right or right to left do not generalize well to text written in those scripts. (上下左右を用いた)固定した絶対参照フレームによって表現される特性,及び右向き又は左向きの単語の進行の概念だけに適用される特性は,これらのスクリプトで書かれたテキストに対して十分には一般化されていない。

For this reason XSL (and before it DSSSL) uses a relative frame of reference for the formatting object and property descriptions. そのために,XSL(及びその前はDSSSL)は,フォーマット化のオブジェクト及び特性の記述には,相対参照フレームを使用する。 Just as the CSS2 frame of reference has four directions (top, bottom, left and right), so does the XSL relative frame of reference have four directions (before, after, start, and end), but these are relative to the "writing-mode". CSS2の参照フレームが(上下左右の)4方向をもつのと同様に,XSLの相対参照フレームは,(前,後,開始及び終了の)4方向をもつが,これらは表記方法に対して相対的である。 The "writing-mode" property is a way of controlling the directions needed by a formatter to correctly place glyphs, words, lines, blocks, etc. on the page or screen. “writing-mode”(表記方法)特性は,ページ又は画面の上にグリフ,単語,行,ブロックなどを正しく配置するために,フォーマッタが必要とする方向を制御する手段である。 The "writing-mode" expresses the basic directions noted above. 表記方向は,これらの基本方向を表現する。 There are writing-modes for "left-to-right - top-to-bottom" (denoted as "lr-tb"), "right-to-left - top-to-bottom" (denoted as "rl-tb"), "top-to-bottom - right-to-left" (denoted as "tb-rl") and more. 表記方法には,“右向き‍–‍下向き”(“lr-tb”と表す),“左向き‍–‍下向き”(“rl-tb”と表す),“下向き‍–‍左向き”(“tb-rl”と表す)などがある。 See 7.29.7 writing-mode for the description of the "writing-mode" property. “writing-mode”特性の記述については,7.29.7 writing-mode を参照されたい。 Typically, the writing-mode value specifies two directions: 通常,表記方法の値は,二つの方向を指定する。 the first is the inline-progression-direction which determines the direction in which words will be placed and the second is the block-progression-direction which determines the direction in which blocks (and lines) are placed one after another. 最初の指定は,行内進行方向であって,単語を配置する方向を決定する。次の指定は,ブロック進行方向であって,ブロック(及び行)を順次配置する方向を決定する。 In addition, the inline-progression-direction for a sequence of characters may be implicitly determined using bidirectional character types for those characters from the Unicode Character Database [UNICODE Character Database] for those characters and the Unicode bidirectional (BIDI) algorithm [UNICODE UAX #9]. 更に,文字のシーケンスのための行内進行方向は,それらの文字のためのUnicode文字データベース[UNICODE Character Database]及びUnicode双方向(BIDI)アルゴリズム[UNICODE UAX #9]によるそれらの文字の双方向性文字型を用いて,暗黙的に決定されてもよい。

Besides the directions that are explicit in the name of the value of the "writing-mode" property, the writing-mode determines other directions needed by the formatter, such as the shift-direction (used for subscripts and superscripts), etc. “writing-mode”特性の値の名前において明示的である方向に加えて,“writing-mode”特性は,(下付き文字及び上付き文字に使用する)シフト方向などの,フォーマッタが必要とする他の方向を決定する。

1.2.6 Linking リンク付け

Because XML, unlike HTML, has no built-in semantics, there is no built-in notion of a hypertext link. HTMLとは異なり,XMLは組込みセマンティクスをもたないので,ハイパテキストリンクの組込みの概念はない。 In this context, "link" refers to "hypertext link" as defined in http://www.w3.org/TR/html401/struct/links.html#h-12.1 as well as some of the aspects of "link" as defined in http://www.w3.org/TR/xlink/#intro, where "link is a relationship between two or more resources or portions of resources, made explicit by an XLink linking element". この文脈において,“リンク”とは, http://www.w3.org/TR/html401/struct/links.html#h-12.1 で定義される“ハイパテキストリンク”,並びに http://www.w3.org/TR/xlink/#intro で定義されている,“リンクとは,XLinkのリンク付け要素によって明示的に作成される,二つ以上の資源又は資源の部分の間の関係である”というリンクの幾つかの局面にも言及する。 Therefore, XSL has a formatting object that expresses the dual semantics of formatting the content of the link reference and the semantics of following the link. したがって,XSLには,リンク参照の内容をフォーマット化するセマンティクスと,リンクをたどるセマンティクスの二つを表現するフォーマット化オブジェクトがある。

XSL provides a few mechanisms for changing the presentation of a link target that is being visited. XSLは,たどったリンクターゲットの表示を変更する幾つかの機構を提供する。 One of these mechanisms permits indicating the link target as such; これらの機構の一つは,リンクターゲットを次のように表示することを可能にする。 another allows for control over the placement of the link target in the viewing area; still another permits some degree of control over the way the link target is displayed in relationship to the originating link anchor. すなわち,表示領域の中でのリンクターゲットの配置に関する制御を考慮する一方で,元のリンクアンカと関係付けてリンク先が表示される方法に関する制御をある程度は許可する。

XSL also provides a general mechanism for changing the way elements are formatted depending on their active state. XSLは,要素の活性状態に応じて,要素をフォーマットする方法を変更するための一般的機構も提供する。 This is particularly useful in relation to links, to indicate whether a given link reference has already been visited, or to apply a given style depending on whether the mouse, for instance, is hovering over the link reference or not. これは,与えられたリンク参照が既にたどり済みであるかどうかを示すために,又は例えば,マウスがリンク参照の上で留まっているかどうかなどに応じて,特定のスタイルを適用するために,リンクに関係して特に有用になる。