Template:tdcl list item

来自cppreference.com

|- | colspan="2" class="t-tdcl-list-sep" |

|- class="t-tdcl-list-item" | colspan="2" | {{{1}}} |-

[edit] [{{purge}}] Template documentation
This is one of the family of templates used for creation of typedef declaration list.

List template families

  • dcl list **** : For creation of member variable/function lists.
  • ddcl list **** : For creation of detailed declaration lists (those including actual declaration code)
  • sdcl list **** : For creation of lists representing various syntaxes of a language feature. Used in subpages of cpp/language
  • param list **** : For creation of lists explaining function parameters.
  • sb list **** : For creation of feature lists in navbars.

{{tdcl list begin}} - starts the declaration list

{{tdcl list header}} - adds explanation which header the feature comes from

{{tdcl list h1| heading}} - adds heading to the declaration list (h3 level)

{{tdcl list h2| heading}} - adds sub-heading to the declaration list (h5 level)

{{tdcl list sep}} - adds a separator

{{tdcl list hitem| name| explanation}} - adds a emphasized item to the declaration list

{{tdcl list item| name| explanation| notes=notes (可选)}} - adds a item to the declaration list. If explanation is omitted, the item spans through both columns.

{{tdcl list template| location}} - includes a template from location. It does nothing more than {{location}} and is included for consistency. The template should contain only {{tdcl list ...}} modules.

{{tdcl list end}} - ends the declaration list

[编辑] Example

 
  {{tdcl list begin}}
  {{tdcl list h1 | Member types}}
  {{tdcl list hitem | Type | Definition}}
  {{tdcl list item | {{tt|dragon_type}} | {{c|Dragon}} }}
  {{tdcl list item | {{tt|fire_type}} | {{c|dragon_traits<Dragon>::fire_type}} }}
  {{tdcl list end}}
  

The above results in the following:

[编辑] Member types

Type Definition
dragon_type Dragon
fire_type dragon_traits<Dragon>::fire_type