틀:NumBlk/설명문서: 두 판 사이의 차이
새 문서: {{설명문서 안내}} This template creates a numbered block which is usually used to number mathematical formulae. This template can be used together with {{tl|EquationRef}} and {{tl|EquationNote}} to produce nicely formatted numbered equations if a back reference to an equation is wanted. == Parameters == Command: <nowiki>{{NumBlk|<1>|<2>|<3>|RawN=<>|LnSty=<>|Border=<>}}</nowiki> Parameters <nowiki>{{{1}}}</nowiki>, <nowiki>{{{2}}}</nowiki>, and <nowiki>{{{3}}}</nowiki> of... |
(차이 없음)
|
2022년 11월 10일 (목) 08:25 기준 최신판
틀:설명문서 안내 This template creates a numbered block which is usually used to number mathematical formulae. This template can be used together with 틀:Tl and 틀:Tl to produce nicely formatted numbered equations if a back reference to an equation is wanted.
Parameters
Command: {{NumBlk|<1>|<2>|<3>|RawN=<>|LnSty=<>|Border=<>}}
Parameters {{{1}}}, {{{2}}}, and {{{3}}} of this template are required. In addition, there are three optional parameters {{{RawN}}}, {{{LnSty}}} and {{{Border}}}.
- {{{1}}}: Specify indentation. The more colons (:) you put, the further indented the block will be, up to a limit of 20. This parameter can be empty if no indentation is needed.
- {{{2}}}: The body or content of the block.
- {{{3}}}: Specify the block number.
- {{{RawN}}}: If a non-empty non-whitespace value, no extra formatting will be applied to the block number.
- {{{LnSty}}}: Specify the line style.
- {{{Border}}}: If set, put a box around the equation. (Experimental.)
Examples
Equations may render HTML | |
|---|---|
|
|
|
|
|
|
|
|
|
Indentation | |
|
|
|
|
|
|
|
|
|
|
|
|
Formatting of equation number | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Line style | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Border | |
|
|
|
Positioning relative to surrounding images
Numbered blocks should be able to be placed around images that take up space on the left or right side of the screen. To ensure numbered block has access to the entire line, consider using a 틀:Tl-like template.
To illustrate, consider the example: 틀:Markupv 틀:Clear If it is desirable for the numbered block to span the entire line, a 틀:Tl should be placed before it. 틀:Markupv
Table caveat
Because 틀:NumBlk is implemented as a table, putting 틀:NumBlk within a table yields a nested table. Due to a bug in MediaWiki's handling of nested tables, 틀:Tl must be used carefully in this case. In particular, when indentation for the outer table is desired, use explicit 틀:Tag tags for indentation instead of a leading colon (:).
For example, 틀:Markupv which shows how the outer 틀:Tag tags give the same indentation as a single colon (:) preceding the table should.
For another example,
| Markup |
|
| Renders as |
which uses two sets of explicit tags to give the same indentation as two colons (::).