Translation:TOCStyles

From IDMLWiki

Jump to: navigation, search

Contents

10.8.8 目次スタイル

目次(TOC)は、InDesignドキュメントのコンテンツのリストです。ドキュメントには、複数の目次を設定できます。例えば、章の目次と図の目次です。目次スタイルで、目次の生成方法と書式設定を行います。

IDMLドキュメントでは、<TOCStyle>エレメントにTOCのプロパティを定義する属性があります。<TOCStyle>エレメント内の<TOCStyleElement>エレメントが、目次として抽出する段落と各段落の書式を定義します。

スキーマの例126 TOCStyle
  1. TOCStyle_Object = element TOCStyle {
  2.   attribute Self { xsd:string },
  3.   attribute TitleStyle{  xsd:string }?,
  4.   attribute Title { xsd:string }?,
  5.   attribute Name { xsd:string },
  6.   attribute RunIn{  xsd:boolean }?,
  7.   attribute IncludeHidden{  xsd:boolean }?,
  8.   attribute IncludeBookDocuments{  xsd:boolean }?,
  9.   attribute CreateBookmarks{  xsd:boolean }?,
  10.   attribute SetStoryDirection{  HorizontalOrVertical_EnumValue }?,
  11.   attribute NumberedParagraphs{  NumberedParagraphsOptions_EnumValue }?,
  12.   element Properties {
  13.     element Label { element KeyValuePair{  KeyValuePair_TypeDef }*
  14.     }?
  15.   }
  16.   ?
  17.   ,
  18. (
  19.   TOCStyleEntry_Object*
  20. )
  21. }
スキーマの例127 TOCStyleEntry
  1. TOCStyleEntry_Object = element TOCStyleEntry{ 
  2.   attribute Self { xsd:string },
  3.   attribute Name { xsd:string }?,
  4.   attribute Level { xsd:short }?,
  5.   attribute PageNumberPosition{  PageNumberPosition_EnumValue }?,
  6.   attribute Separator { xsd:string }?,
  7.   attribute SortAlphabet{  xsd:boolean }?,
  8.   element Properties {
  9.     element FormatStyle{ 
  10.       (object_type, xsd:string ) |
  11.       (string_type, xsd:string )
  12.     }?&
  13.     element PageNumberStyle{ 
  14.       (object_type, xsd:string ) |
  15.       (string_type, xsd:string )
  16.     }?&
  17.     element SeparatorStyle{ 
  18.       (object_type, xsd:string ) |
  19.       (string_type, xsd:string )
  20.     }?
  21.   }
  22.   ?
  23. }
表121 属性としてのTOCStyleプロパティ
名前 必須 説明
CreateBookmarks boolean trueのとき、PDFブックマークを作成
IncludeBookDocuments boolean trueのとき、ブックのドキュメントを含む。falseのとき、現在のドキュメントのみ。Note:現在のドキュメントがブックに登録されているときのみ
IncludeHidden boolean trueのとき、非表示レイヤーのテキストを含む(次回生成時に適用され、現在の目次は変更されない)
Name string TOCStyleの名前
NumberedParagraphs NumberedParagraphsOptions_EnumValue 段落の自動番号。IncludeFullParagraph、IncludeNumbersOnlyまたはExcludeNumbers
RunIn boolean trueのとき、1行にまとめる
SetStoryDirection HorizontalOrVertical_EnumValue フレームの方向。LeftToRightDirectionまたはRightToLeftDirection
Title string タイトル
TitleStyle string タイトルの段落スタイル
表122 属性としてのTOCStyleEntryプロパティ
名前 必須 説明
Level short レベル
Name string TOCStyleEntryの名前
PageNumberPosition PageNumberPosition_EnumValue ページ番号。AfterEntry、BeforeEntryまたはNone
Self string オブジェクトのユニークID
Separator string 項目と番号間
SortAlphabet boolean trueのとき、項目をアルファベット・50音順に並べる
表123 エレメントとしてのTOCStyleEntryプロパティ
名前 必須 説明
FormatStyle string 目次項目に割り当てる段落スタイル。
type = "object"
参照する段落スタイルのユニークID(<ParagraphStyle>エレメントのSelf属性)
または
type = "string"
デフォルト段落スタイル[段落スタイルなし]エレメントの参照($ID/[No paragraph style])
PageNumberStyle string ページ番号に割り当てる文字スタイル。
type = "object"
参照する文字スタイルのユニークID(<CharacterStyle>エレメントのSelf属性)
または
type = "string"
デフォルト文字スタイル[なし]エレメントの参照($ID/[No character style])
SeparatorStyle string 項目と番号間に割り当てる文字スタイル。
type = "object"
参照する文字スタイルのユニークID(<CharacterStyle>エレメントのSelf属性)
または
type = "string"
デフォルト文字スタイル[なし]エレメントの参照($ID/[No character style])
IDMLの例83 TOCStyle
  1. <TOCStyle Self="TOCStyle\kDefaultTOCStyleName" TitleStyle=" ParagraphStyle\ k[No paragraph style]" Title="Contents" Name="$ID/DefaultTOCStyleName" RunIn=" false" IncludeHidden=" false" IncludeBookDocuments=" false" CreateBookmarks=" true" SetStoryDirection=" Horizontal" NumberedParagraphs=" IncludeFullParagraph"/>
  2. <TOCStyle Self="TOCStyle\cExampleTOCStyle" TitleStyle=" ParagraphStyle\ cContentsTitle" Title="Contents" Name="ExampleTOCStyle" RunIn=" false" IncludeHidden=" false" IncludeBookDocuments=" false" CreateBookmarks=" true" NumberedParagraphs=" IncludeFullParagraph">
  3.   <TOCStyleEntry Self="ue4TOCStyleEntry0" Name="Headings:Heading1" Level="1" PageNumberPosition=" AfterEntry" Separator="$ID/^t" SortAlphabet=" false">
  4.     <Properties>
  5.       <FormatStyle type="object">ParagraphStyle\ TOCHeading1</FormatStyle>
  6.       <PageNumberStyle type="object">CharacterStyle\ PageNumber</ PageNumberStyle>
  7.       <SeparatorStyle type="object">CharacterStyle\ DotLeader</ SeparatorStyle>
  8.     </Properties>
  9.   </TOCStyleEntry>
  10.   <TOCStyleEntry Self="ue4TOCStyleEntry1" Name="Headings:Heading2" Level="2" PageNumberPosition=" AfterEntry" Separator="$ID/^t" SortAlphabet=" false">
  11.     <Properties>
  12.       <FormatStyle type="object">ParagraphStyle\ TOCHeading2</FormatStyle>
  13.       <PageNumberStyle type="object">CharacterStyle\ PageNumber</ PageNumberStyle>
  14.       <SeparatorStyle type="object">CharacterStyle\ DotLeader</ SeparatorStyle>
  15.     </Properties>
  16.   </TOCStyleEntry>
  17.   <TOCStyleEntry Self="ue4TOCStyleEntry2" Name="Headings:Heading3" Level="3" PageNumberPosition=" AfterEntry" Separator="$ID/^t" SortAlphabet=" false">
  18.     <Properties>
  19.       <FormatStyle type="object">ParagraphStyle\ TOCHeading3</FormatStyle>
  20.       <PageNumberStyle type="object">CharacterStyle\ PageNumber</ PageNumberStyle>
  21.       <SeparatorStyle type="object">CharacterStyle\ DotLeader</ SeparatorStyle>
  22.     </Properties>
  23.   </TOCStyleEntry>
  24. </TOCStyle>
図58 目次スタイル

Image:Fig058.png

Personal tools