Jump to content

Template:Small-caps/doc

From Wikisource

This template simplifies formatting text in small caps, where lowercase letters are replaced with smaller capital letters.

Usage

[edit]

Example

{{Small-caps|Small caps}}
⇒ Small caps

Misuse for capitalization

[edit]

The use of this template to simulate smaller capitalised text is semantically incorrect:

Example: Improper use

{{Small-caps|this is incorrect. grammatically, there should be capitals in this sentence.}}
⇒ this is incorrect. grammatically, there should be capitals in this sentence.

The problems here are:

  • It copy/pastes as lowercase text, because the CSS only affects styling, not content.
  • Viewers that do not handle the CSS used for small-caps (font-variant) will display the text as all lowercase.

Example: Acceptable use

{{X-smaller|THIS IS CORRECT. IT IS CAPITALS, BUT IN A SMALLER FONT}}
⇒ THIS IS CORRECT. IT IS CAPITALS, BUT IN A SMALLER FONT

Example: Also acceptable use

{{All small caps|This is also correct. It is the "small-caps" variant, but the text is not all lowercase when copied.}}
⇒ This is also correct. It is the "small-caps" variant, but the text is not all lowercase when copied.

The template {{All small caps}} can be used to request the special small-caps glyphs (generally slightly proportionally wider than simply making the font smaller) for all letters, uppercase or lowercase, without having the text copy-paste as lowercase.

TemplateData

[edit]
This is the TemplateData documentation for this template used by VisualEditor and other tools.

Small-caps

Format text as small-caps. See also {{All small caps}}.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
11

The text to format as small caps

Stringrequired

See also

[edit]
  • {{Center Small Caps}} ({{Csc}}) which produces centered Small-caps
  • {{Font-variant normal}} to remove small caps in the middle of a span (for example in a template which produces a small-caps line)
  • {{Sm}} which produces standard small text
  • {{Small-caps block}} to formats text block in Small caps.
  • {{All small caps}} ({{Asc}}), which presents both upper and lower case as small-caps