模板:Smallcaps
{{{1}}}
此模板目前缺乏相關中文使用說明。請知曉此模板目的及使用方法的編輯者協助[{{fullurl:Template:Documentation/template page/doc|action=edit}} 編寫說明文件]或者翻譯其他語言版本。 本模板可能使用了參數,若無完整的使用說明將不便於他人了解、引用、維護與修改。 |
Usage
[編輯]{{Smallcaps|Your Text}}
will display the lowercase part of Your Text as typographical small caps. Your source text is not altered (a copy-paste will give it in its original form), only the way it is displayed. You can most especially use this template for names/surnames disambiguation and all-caps words or pronounceable acronyms.
Diacritics (å, ç, é, ğ, ı, ñ, ø, ş, ü, etc.) are handled. However, because the job is performed by each reader's browser, inconsistencies in CSS implementations can lead to some browsers not converting certain rare diacritics.
Use of this template does not generate any automatic categorization. As with most templates, if the argument contains an = sign, the argument should be prefixed with 1=. And for wikilinks, you need to use piping. There is a parsing problem with MediaWiki which causes unexpected behavior when a template with one style is used within a template with another style.
Technically, the templates wraps the standard <SPAN STYLE="font-variant:small-caps;">Your Text</SPAN>
.
Code examples
[編輯]Code | Gives | |
---|---|---|
Y | {{Smallcaps|The ''Name'' of the 2<SUP>nd</SUP> Game}} | The Name of the 2nd Game |
Y | Leonardo {{Smallcaps|DiCaprio}} (born 1974) | Leonardo DiCaprio (born 1974) |
Y | {{Smallcaps|Nesbø, Vågen, Louÿs, Zúñiga, Kabaağaçlı}} | Nesbø, Vågen, Louÿs, Zúñiga, Kabaağaçlı |
When your text uses an = sign: | ||
N | {{Smallcaps|2+2=4}} | {{{1}}} |
Y | {{Smallcaps|1=2+2=4}} | 2+2=4 |
When your text uses a template: | ||
N | {{Smallcaps|Being {{Green|Green}} is Easy}} | Being Template:Green is Easy |
N | {{Smallcaps|Being {{Green{{!}}Green}} is Easy}} | Green}} is Easy |
Y | {{Smallcaps|1=Being {{Green|Green}} is Easy}} | Being Template:Green is Easy |
Y | {{Green|1=Being {{Smallcaps|Green}} is Easy}} | Template:Green |
Y | {{Colors|green|yellow|3=Being {{Smallcaps|Green}} is Easy}} | Template:Colors |
When your text uses a | pipe: | ||
N | {{Smallcaps|Before|afteR}} | Before |
N | {{Smallcaps|1=Before{{!}}afteR}} | afteR |
Y | {{Smallcaps|1=Before|afteR}} | Before|afteR |
When your text uses a link: | ||
N | [[{{Smallcaps|Mao}} Zedong]] | [[Mao Zedong]] |
Y | [[Mao Zedong|{{Smallcaps|Mao}} Zedong]] | Mao Zedong |
Reasons to use
[編輯]This template is useful for typographical uses including:
- To lighten ALL-CAPS words or pronounceable acronyms, such as:
- To lighten ALL-CAPS surnames mandated by some referencing styles:
- Piccadilly has been compared to a Parisian boulevard (Dickens 1879).
- Dickens, C., Jr (1879). "Piccadilly" in Dickens's Dictionary of London.
- To disambiguate Western names and surnames at a glance:
- Many Spanish names are tricky to decompose:
- Jorge Luis Borges, but Adolfo Bioy Casares (both filed under "B")
- Many Spanish names are tricky to decompose:
- To disambiguate Eastern surnames and names at a glance:
- Most Chinese names retain their surname-first order:
- Most Japanese names are reversed in the West:
- Akira Kurosawa or Motojirō Kajii (usually reversed)
- But Edogawa Ranpo (kept due to wordplay "EdgarA–llanPoe) vs. Ranpo Edogawa (some modern uses)
See also
[編輯]Templates that change the display (copy-paste will get the original text):
Magic words that rewrite the output (copy-paste will get the text as displayed):
- {{lc:}} – lower case output of the full text
- {{uc:}} – upper case output of the full text
- {{lcfirst:}} – lower case output of the first character only
- {{ucfirst:}} – upper case output of the first character only
上述文件嵌入自Template:Smallcaps/doc。 (編輯 | 歷史) 編者可以在本模板的沙盒 (建立 | 鏡像)和測試樣例 (建立)頁面進行實驗。 請在/doc子頁面中添加分類。 本模板的子頁面。 |