Пространства имён

Шаблон:tdcl list/doc

Материал из cppreference.com

This is one of the family of templates used for creation of typedef declaration list.

tdcl templates are deprecated. Use dcl list equivalents

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

[править] Пример

  {{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