Template:INITOC: Difference between revisions

From Step Mods | Change The Game
No edit summary
mNo edit summary
 
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<includeonly>{{#if:{{{notitle|}}}| |<h3>INI parameters by section</h3>}}<div style="padding:12px 12px; border:{{{borderSize|1px}}} solid {{{borderColor|#555}}}; width:{{{width|65%}}}; -webkit-column-count:{{{columns|3}}}; -moz-column-count:{{{columns|3}}}; column-count:{{{columns|3}}}; -webkit-column-gap:{{{gapSize|25px}}}; -moz-column-gap:{{{gapSize|25px}}}; column-gap:{{{gapSize|25px}}}; -webkit-column-rule:{{{borderSize|0px}}} solid {{{borderColor|#555}}}; -moz-column-rule:{{{borderSize|0px}}} solid {{{borderColor|#555}}}; column-rule:{{{borderSize|0px}}} solid {{{borderColor|#555}}};">{{{text|}}}</div></includeonly><noinclude>__NOTOC__
<includeonly><div class="toc" style="column-count:{{{columns|5}}};display:inline-block;font-size:{{{fontsize|15pt}}};padding:1rem;">{{#arraymap:{{{1}}}|*|x|[[/x|[x]]]<br />|}}</div></includeonly><noinclude>__NOTOC__ [[Category:Guide Templates]][https://stepmodifications.org/forum/topic/98292-initoc/ '''Forum Topic''']
 
== Purpose & Usage ==
== Purpose & Usage ==
This template should be used in conjunction with the helper template, {{tl|INISectionLabel}}. 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 {{tl|INISectionLabel}}.
This template provides a method for laying out a custom table of contents listing subpage links to respective INI parameters.


===Parameters===
===Parameters===
====Required====
====Required====
*''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.
*''parameter 1'': This should be a bulleted list of all the sections.


====Optional====
====Optional====
*''borderColor'': Sets the color of the borders. Enter the hex code (excluding # prefix) Default is #555.
*''columns'': This specifies the number of columns. Default is 5.
*''width'': Sets the width of the entire block of columned content. Enter an integer in pixels. Default is 65%.
*''fontsize'': This specifies the font size. Default is 15pt.
*''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.
*''notitle''" Omits the default h3 title for the TOC box. Enter any text, but a single integer ('0' or '1') is suggested.


== Examples ==
== Examples ==
'''Code:''' (normal use with the helper template)
'''Code:'''
<pre>{{INITOC
<pre>{{INITOC|columns=5|
|text={{INISectionLabel
*:Controls
|ParamHead1}}{{INISectionLabel
*Actor
|ParamHead2}}{{INISectionLabel
*Animation
|ParamHead3}}{{INISectionLabel
*Archive
|ParamHead4}}{{INISectionLabel
*Audio
|ParamHead5}}{{INISectionLabel
*BackgroundLoad
|ParamHead6}}{{INISectionLabel
*bLightAttenuation
|ParamHead7}}{{INISectionLabel
*BSPathing
|ParamHead8}}{{INISectionLabel
*BudgetCaps
|ParamHead9}}{{INISectionLabel
*Camera
|ParamHead10}}{{INISectionLabel
*CameraPath
|ParamHead11}}{{INISectionLabel
*Cart
|ParamHead12}}
*Clouds
}}</pre>
*Combat
'''Result:'''
*Controls
{{INITOC
*CopyProtectionStrings
|text={{INISectionLabel
*Debug
|ParamHead1}}{{INISectionLabel
*Decals
|ParamHead2}}{{INISectionLabel
*Dialogue
|ParamHead3}}{{INISectionLabel
*Display
|ParamHead4}}{{INISectionLabel
*FaceGen
|ParamHead5}}{{INISectionLabel
*Fonts
|ParamHead6}}{{INISectionLabel
*FootIK
|ParamHead7}}{{INISectionLabel
*Gameplay
|ParamHead8}}{{INISectionLabel
*General
|ParamHead9}}{{INISectionLabel
*GeneralWarnings
|ParamHead10}}{{INISectionLabel
*GethitShader
|ParamHead11}}{{INISectionLabel
*GrabIK
|ParamHead12}}
*Grass
}}<br />
*HAVOK
*HeadTracking
*Imagespace
*Interface
*Kinect
*Landscape
*LANGUAGE
*Light
*LightingShader
*LOD
*LookIK
*MAIN
*MapMenu
*Menu
*MESSAGES
*NavMeshGeneration
*Papyrus
*Pathfinding
*Pathing
*RagdollAnim
*RagdollFeedback
*SaveGame
*ScreenSplatter
*SpeedTree
*Terrain
*TerrainManager
*TestAllCells
*Trees
*VATS
*Verlet
*Voice
*Water
*Weather}}</pre>


'''Code:''' (fully parameterized)
''Result:''
<pre>{{INITOC
{{INITOC|columns=5|
|borderColor=#55aa55
*:Controls
|borderSize=1px
*Actor
|columns=4
*Animation
|width=90%
*Archive
|gapSize=10px
*Audio
|text={{INISectionLabel
*BackgroundLoad
|ParamHead1}}{{INISectionLabel
*bLightAttenuation
|ParamHead2}}{{INISectionLabel
*BSPathing
|ParamHead3}}{{INISectionLabel
*BudgetCaps
|ParamHead4}}{{INISectionLabel
*Camera
|ParamHead5}}{{INISectionLabel
*CameraPath
|ParamHead6}}{{INISectionLabel
*Cart
|ParamHead7}}{{INISectionLabel
*Clouds
|ParamHead8}}{{INISectionLabel
*Combat
|ParamHead9}}{{INISectionLabel
*Controls
|ParamHead10}}{{INISectionLabel
*CopyProtectionStrings
|ParamHead11}}{{INISectionLabel
*Debug
|ParamHead12}}{{INISectionLabel
*Decals
|ParamHead13}}{{INISectionLabel
*Dialogue
|ParamHead14}}{{INISectionLabel
*Display
|ParamHead15}}{{INISectionLabel
*FaceGen
|ParamHead16}}{{INISectionLabel
*Fonts
|ParamHead17}}{{INISectionLabel
*FootIK
|ParamHead18}}{{INISectionLabel
*Gameplay
|ParamHead19}}{{INISectionLabel
*General
|ParamHead20}}
*GeneralWarnings
}}</pre>
*GethitShader
'''Result:'''
*GrabIK
{{INITOC
*Grass
|borderColor=#55aa55
*HAVOK
|borderSize=1px
*HeadTracking
|columns=4
*Imagespace
|width=90%
*Interface
|gapSize=10px
*Kinect
|text={{INISectionLabel
*Landscape
|ParamHead1}}{{INISectionLabel
*LANGUAGE
|ParamHead2}}{{INISectionLabel
*Light
|ParamHead3}}{{INISectionLabel
*LightingShader
|ParamHead4}}{{INISectionLabel
*LOD
|ParamHead5}}{{INISectionLabel
*LookIK
|ParamHead6}}{{INISectionLabel
*MAIN
|ParamHead7}}{{INISectionLabel
*MapMenu
|ParamHead8}}{{INISectionLabel
*Menu
|ParamHead9}}{{INISectionLabel
*MESSAGES
|ParamHead10}}{{INISectionLabel
*NavMeshGeneration
|ParamHead11}}{{INISectionLabel
*Papyrus
|ParamHead12}}{{INISectionLabel
*Pathfinding
|ParamHead13}}{{INISectionLabel
*Pathing
|ParamHead14}}{{INISectionLabel
*RagdollAnim
|ParamHead15}}{{INISectionLabel
*RagdollFeedback
|ParamHead16}}{{INISectionLabel
*SaveGame
|ParamHead17}}{{INISectionLabel
*ScreenSplatter
|ParamHead18}}{{INISectionLabel
*SpeedTree
|ParamHead19}}{{INISectionLabel
*Terrain
|ParamHead20}}
*TerrainManager
}}<br />
*TestAllCells
*Trees
*VATS
*Verlet
*Voice
*Water
*Weather}}


'''Code:''' (title omitted; without helper template)
== See Also ==
<pre>
None
{{INITOC
|notitle=1
|text=ParamHead1<br />ParamHead2<br />ParamHead3<br />ParamHead4<br />ParamHead5<br />ParamHead6<br />ParamHead7<br />ParamHead8<br />ParamHead9}</pre>
'''Result:'''
{{INITOC
|notitle=1
|text=ParamHead1<br />ParamHead2<br />ParamHead3<br />ParamHead4<br />ParamHead5<br />ParamHead6<br />ParamHead7<br />ParamHead8<br />ParamHead9}}


== See Also ==
*[[Template:INISectionLabel]]
</noinclude>
</noinclude>

Latest revision as of 15:50, August 2, 2021

Forum Topic

Purpose & Usage

This template provides a method for laying out a custom table of contents listing subpage links to respective INI parameters.

Parameters

Required

  • parameter 1: This should be a bulleted list of all the sections.

Optional

  • columns: This specifies the number of columns. Default is 5.
  • fontsize: This specifies the font size. Default is 15pt.

Examples

Code:

{{INITOC|columns=5|
*:Controls
*Actor
*Animation
*Archive
*Audio
*BackgroundLoad
*bLightAttenuation
*BSPathing
*BudgetCaps
*Camera
*CameraPath
*Cart
*Clouds
*Combat
*Controls
*CopyProtectionStrings
*Debug
*Decals
*Dialogue
*Display
*FaceGen
*Fonts
*FootIK
*Gameplay
*General
*GeneralWarnings
*GethitShader
*GrabIK
*Grass
*HAVOK
*HeadTracking
*Imagespace
*Interface
*Kinect
*Landscape
*LANGUAGE
*Light
*LightingShader
*LOD
*LookIK
*MAIN
*MapMenu
*Menu
*MESSAGES
*NavMeshGeneration
*Papyrus
*Pathfinding
*Pathing
*RagdollAnim
*RagdollFeedback
*SaveGame
*ScreenSplatter
*SpeedTree
*Terrain
*TerrainManager
*TestAllCells
*Trees
*VATS
*Verlet
*Voice
*Water
*Weather}}

Result:

See Also

None