Template:INITOC: Difference between revisions

From Step Mods | Change The Game
No edit summary
No edit summary
Line 5: Line 5:
===Parameters===
===Parameters===
====Required====
====Required====
*''text'': Parameter-heading labels separated by <code><nowiki><br /></nowiki></code> or <code><nowiki><br></nowiki></code> HTML tags.
*''text'': List of {{tl|INISectionLabel}} helper template calls (no breaks or spaces in between). If for some reason this is used with out the helper template, enter parameter-heading labels separated by <code><nowiki><br /></nowiki></code> or <code><nowiki><br></nowiki></code> HTML tags.


====Optional====
====Optional====
Line 15: Line 15:


== Examples ==
== Examples ==
{{Fc|important|'''''NOTE:''' Do NOT add line breaks within the code. Instead use HTML <code><nowiki><br /></nowiki></code> or <code><nowiki><br></nowiki></code> tags between each parameter.''}}<br />
'''Code:''' (normal use with the helper template)
'''Code:''' (normal use with the helper template)
<pre>{{Columns|text={{INISectionLabel|ParamHead1}}<br />{{INISectionLabel|ParamHead2}}<br />{{INISectionLabel|ParamHead3}}<br />{{INISectionLabel|ParamHead4}}<br />{{INISectionLabel|ParamHead5}}<br />{{INISectionLabel|ParamHead6}}<br />{{INISectionLabel|ParamHead7}}<br />{{INISectionLabel|ParamHead8}}<br />{{INISectionLabel|ParamHead9}}<br />{{INISectionLabel|ParamHead10}}<br />{{INISectionLabel|ParamHead11}}<br />{{INISectionLabel|ParamHead12}}</pre>
<pre>{{Columns|text={{INISectionLabel|ParamHead1}}{{INISectionLabel|ParamHead2}}{{INISectionLabel|ParamHead3}}{{INISectionLabel|ParamHead4}}{{INISectionLabel|ParamHead5}}{{INISectionLabel|ParamHead6}}{{INISectionLabel|ParamHead7}}{{INISectionLabel|ParamHead8}}{{INISectionLabel|ParamHead9}}{{INISectionLabel|ParamHead10}}{{INISectionLabel|ParamHead11}}{{INISectionLabel|ParamHead12}}
}}</pre>
'''Result:'''
'''Result:'''
{{Columns|text={{INISectionLabel|ParamHead1}}<br />{{INISectionLabel|ParamHead2}}<br />{{INISectionLabel|ParamHead3}}<br />{{INISectionLabel|ParamHead4}}<br />{{INISectionLabel|ParamHead5}}<br />{{INISectionLabel|ParamHead6}}<br />{{INISectionLabel|ParamHead7}}<br />{{INISectionLabel|ParamHead8}}<br />{{INISectionLabel|ParamHead9}}<br />{{INISectionLabel|ParamHead10}}<br />{{INISectionLabel|ParamHead11}}<br />{{INISectionLabel|ParamHead12}}}}
{{Columns|text={{INISectionLabel|ParamHead1}}{{INISectionLabel|ParamHead2}}{{INISectionLabel|ParamHead3}}{{INISectionLabel|ParamHead4}}{{INISectionLabel|ParamHead5}}{{INISectionLabel|ParamHead6}}{{INISectionLabel|ParamHead7}}{{INISectionLabel|ParamHead8}}{{INISectionLabel|ParamHead9}}{{INISectionLabel|ParamHead10}}{{INISectionLabel|ParamHead11}}{{INISectionLabel|ParamHead12}}
}}


'''Code:''' (
'''Code:''' (
Line 29: Line 29:
|width=100%
|width=100%
|gapSize=10px
|gapSize=10px
|text={{INISectionLabel|ParamHead1}}<br />{{INISectionLabel|ParamHead2}}<br />{{INISectionLabel|ParamHead3}}<br />{{INISectionLabel|ParamHead4}}<br />{{INISectionLabel|ParamHead5}}<br />{{INISectionLabel|ParamHead6}}<br />{{INISectionLabel|ParamHead7}}<br />{{INISectionLabel|ParamHead8}}<br />{{INISectionLabel|ParamHead9}}<br />{{INISectionLabel|ParamHead10}}<br />{{INISectionLabel|ParamHead11}}<br />{{INISectionLabel|ParamHead12}}<br />{{INISectionLabel|ParamHead13}}<br />{{INISectionLabel|ParamHead14}}<br />{{INISectionLabel|ParamHead15<br /{{INISectionLabel|ParamHead16}}<br />{{INISectionLabel|ParamHead17}}<br />{{INISectionLabel|ParamHead18}}<br />{{INISectionLabel|ParamHead19}}<br />{{INISectionLabel|ParamHead20
|text={{INISectionLabel|ParamHead1}}{{INISectionLabel|ParamHead2}}{{INISectionLabel|ParamHead3}}{{INISectionLabel|ParamHead4}}{{INISectionLabel|ParamHead5}}{{INISectionLabel|ParamHead6}}{{INISectionLabel|ParamHead7}}{{INISectionLabel|ParamHead8}}{{INISectionLabel|ParamHead9}}{{INISectionLabel|ParamHead10}}{{INISectionLabel|ParamHead11}}{{INISectionLabel|ParamHead12}}{{INISectionLabel|ParamHead13}}{{INISectionLabel|ParamHead14}}{{INISectionLabel|ParamHead15<br /{{INISectionLabel|ParamHead16}}{{INISectionLabel|ParamHead17}}{{INISectionLabel|ParamHead18}}{{INISectionLabel|ParamHead19}}{{INISectionLabel|ParamHead20}}
}}</pre>
}}</pre>
'''Result:'''
'''Result:'''
Line 38: Line 38:
|width=100%
|width=100%
|gapSize=10px
|gapSize=10px
|text={{INISectionLabel|ParamHead1}}<br />{{INISectionLabel|ParamHead2}}<br />{{INISectionLabel|ParamHead3}}<br />{{INISectionLabel|ParamHead4}}<br />{{INISectionLabel|ParamHead5}}<br />{{INISectionLabel|ParamHead6}}<br />{{INISectionLabel|ParamHead7}}<br />{{INISectionLabel|ParamHead8}}<br />{{INISectionLabel|ParamHead9}}<br />{{INISectionLabel|ParamHead10}}<br />{{INISectionLabel|ParamHead11}}<br />{{INISectionLabel|ParamHead12}}<br />{{INISectionLabel|ParamHead13}}<br />{{INISectionLabel|ParamHead14}}<br />{{INISectionLabel|ParamHead15<br /{{INISectionLabel|ParamHead16}}<br />{{INISectionLabel|ParamHead17}}<br />{{INISectionLabel|ParamHead18}}<br />{{INISectionLabel|ParamHead19}}<br />{{INISectionLabel|ParamHead20}}
|text={{INISectionLabel|ParamHead1}}{{INISectionLabel|ParamHead2}}{{INISectionLabel|ParamHead3}}{{INISectionLabel|ParamHead4}}{{INISectionLabel|ParamHead5}}{{INISectionLabel|ParamHead6}}{{INISectionLabel|ParamHead7}}{{INISectionLabel|ParamHead8}}{{INISectionLabel|ParamHead9}}{{INISectionLabel|ParamHead10}}{{INISectionLabel|ParamHead11}}{{INISectionLabel|ParamHead12}}{{INISectionLabel|ParamHead13}}{{INISectionLabel|ParamHead14}}{{INISectionLabel|ParamHead15<br /{{INISectionLabel|ParamHead16}}{{INISectionLabel|ParamHead17}}{{INISectionLabel|ParamHead18}}{{INISectionLabel|ParamHead19}}{{INISectionLabel|ParamHead20}}
}}
}}



Revision as of 18:23, July 1, 2015

Purpose & Usage

This template should be used in conjunction with the helper template, Template:Tl. This template provides a method for laying out a custom table of contents listing subpage links to respective INI parameters. These subpage links are, in turn, handled using Template:Tl.

Parameters

Required

  • text: List of Template:Tl helper template calls (no breaks or spaces in between). If for some reason this is used with out the helper template, enter parameter-heading labels separated by <br /> or <br> HTML tags.

Optional

  • borderColor: Sets the color of the borders. Enter the hex code (excluding # prefix) Default is #555.
  • width: Sets the width of the entire block of columned content. Enter an integer in pixels. Default is 65%.
  • columns: Sets the number of columns to use. Enter an integer. Default is 3.
  • gapSize: Sets the whitespace width between columns (analogous to padding). Enter an integer in pixels. Default is 25px.
  • borderSize: Sets the border width between columns (placed in center of the gap). Enter an integer in pixels. Default is 1px.

Examples

Code: (normal use with the helper template)

{{Columns|text={{INISectionLabel|ParamHead1}}{{INISectionLabel|ParamHead2}}{{INISectionLabel|ParamHead3}}{{INISectionLabel|ParamHead4}}{{INISectionLabel|ParamHead5}}{{INISectionLabel|ParamHead6}}{{INISectionLabel|ParamHead7}}{{INISectionLabel|ParamHead8}}{{INISectionLabel|ParamHead9}}{{INISectionLabel|ParamHead10}}{{INISectionLabel|ParamHead11}}{{INISectionLabel|ParamHead12}}
}}

Result: Template:Columns

Code: (

{{Columns
|borderColor=#55aa55
|borderSize=1px
|columns=4
|width=100%
|gapSize=10px
|text={{INISectionLabel|ParamHead1}}{{INISectionLabel|ParamHead2}}{{INISectionLabel|ParamHead3}}{{INISectionLabel|ParamHead4}}{{INISectionLabel|ParamHead5}}{{INISectionLabel|ParamHead6}}{{INISectionLabel|ParamHead7}}{{INISectionLabel|ParamHead8}}{{INISectionLabel|ParamHead9}}{{INISectionLabel|ParamHead10}}{{INISectionLabel|ParamHead11}}{{INISectionLabel|ParamHead12}}{{INISectionLabel|ParamHead13}}{{INISectionLabel|ParamHead14}}{{INISectionLabel|ParamHead15<br /{{INISectionLabel|ParamHead16}}{{INISectionLabel|ParamHead17}}{{INISectionLabel|ParamHead18}}{{INISectionLabel|ParamHead19}}{{INISectionLabel|ParamHead20}}
}}

Result: {{Columns |borderColor=#55aa55 |borderSize=1px |columns=4 |width=100% |gapSize=10px |text=Template:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabelTemplate:INISectionLabel

Code: (can be used without helper template)

{{Columns|text=ParamHead1<br />ParamHead2<br />ParamHead3}}

Result: Template:Columns

See Also