Jump to content
 







Main menu
   


Navigation  



Main page
Contents
Current events
Random article
About Wikipedia
Contact us
Donate
 




Contribute  



Help
Learn to edit
Community portal
Recent changes
Upload file
 








Search  

































Create account

Log in
 









Create account
 Log in
 




Pages for logged out editors learn more  



Contributions
Talk
 



















Contents

   



(Top)
 


1 Usage  



1.1  Examples  





1.2  User style  







2 Error messaging  





3 Limitations  





4 See also  





5 Template data  














Template:Nihongo






Аԥсшәа
العربية
Arpetan
Asturianu
Avañe'
Авар
Azərbaycanca
تۆرکجه
Basa Bali

Banjar
 / Bân-lâm-gú
Basa Banyumasan
Башҡортса
Беларуская
Беларуская (тарашкевіца)

Български
Bosanski
Brezhoneg
Буряад
Català
Чӑвашла
Cebuano
Corsu
Cymraeg
Dansk
الدارجة

Español
Esperanto
Euskara
فارسی
Fiji Hindi
Føroyskt
Français
Galego

/Hak-kâ-ngî

Հայերեն
ि
Ilokano
Bahasa Indonesia
Ирон
Íslenska
Italiano
Jawa
Kapampangan
Къарачай-малкъар

Қазақша
Кыргызча
Ladin

Latina
Latviešu
Magyar
ि
Македонски




Bahasa Melayu
Minangkabau
 / Mìng-dĕ̤ng-nḡ
Монгол

Nederlands


Нохчийн
Norfuk / Pitkern
Norsk bokmål
Novial
Occitan
ି
Oʻzbekcha / ўзбекча


Polski
Português
Qırımtatarca
Română
Русский
Саха тыла
Scots
Shqip

Simple English
سنڌي
Slovenčina
Slovenščina
کوردی
Српски / srpski
Srpskohrvatski / српскохрватски
Sunda
Suomi
Svenska
Tagalog
Tarandíne
 


Тоҷикӣ
Türkçe
Basa Ugi
Українська
اردو
Vèneto
Tiếng Vit
Winaray

Zazaki

Betawi
 

Edit links
 









Template
Talk
 

















Read
View source
View history
 








Tools
   


Actions  



Read
View source
View history
 




General  



What links here
Related changes
Upload file
Special pages
Permanent link
Page information
Get shortened URL
Download QR code
Wikidata item
 




Print/export  



Download as PDF
Printable version
 




In other projects  



Wikiversity
 
















Appearance
   

 





Permanently protected template

From Wikipedia, the free encyclopedia
 


Usage

This template marks the kanji segment as being in Japanese kanji and/or kana, which helps user agents (web browsers and so on) to display it correctly.

Syntax:

Without lead=yes With lead=yes
{{Nihongo|<english>|<kanji/kana>|<rōmaji>|<extra>|<extra2>}} {{Nihongo|<english>|<kanji/kana>|<rōmaji>|lead=yes|extra=<extra>|extra2=<extra2>}}

Parameters:

Examples

Regular use
Code {{Nihongo|Tokyo Tower|東京タワー|Tōkyō tawā}}
Gives Tokyo Tower (東京タワー, Tōkyō tawā)
Use in lead
Code {{Nihongo|Tokyo Tower|東京タワー|Tōkyō tawā|lead=yes}}
Gives Tokyo Tower (Japanese: 東京タワー, Hepburn: Tōkyō tawā)
Without English
Code {{Nihongo||東京タワー|Tōkyō tawā}}
Gives Tōkyō tawā (東京タワー)
Without English, use in lead
Code {{Nihongo||東京タワー|Tōkyō tawā|lead=yes}}
Gives Tōkyō tawā (Japanese: 東京タワー)
With extra to add a literal translation
Code {{Nihongo|''Sokoban''|倉庫番|Sōko-ban|{{lit|warehouse keeper}}}}
Gives Sokoban (倉庫番, Sōko-ban, lit.'warehouse keeper')
With extra2
Code

; {{Nihongo||虚無僧|komusō|extra2='Priest of nothingness'}}
: Mendicant priest of the Fuke sect of Zen Buddhism.

Gives
komusō (虚無僧) 'Priest of nothingness'
Mendicant priest of the Fuke sect of Zen Buddhism.
Without extra2
Code

; {{Nihongo||虚無僧|komusō}} 'Priest of nothingness'
: Mendicant priest of the Fuke sect of Zen Buddhism.

Gives
komusō (虚無僧) 'Priest of nothingness'
Mendicant priest of the Fuke sect of Zen Buddhism.

User style

User style can be set by adding code similar to

@media screen, tv {
 *[lang="ja"] {
  color: green;
 }
}

tocommon.css.

Error messaging

This template emits one error message of its own:

error: {{nihongo}}: Japanese or romaji text required

One of the positional parameters <kanji/kana> ({{{2}}}), the 'Japanese' referred to in the error message or <rōmaji> ({{{3}}}) is required for proper operation of this template. Articles with these errors are collected in Category:Nihongo template errors (0).

This error often occurs because the template is malformed:

{{Nihongo|東京タワー}} instead of {{Nihongo||東京タワー}}; 東京タワー is in {{{1}}} (<english>) instead of {{{2}}} (<kanji/kana>). To resolve this error, add the missing pipe (|) or consider using {{lang}}or{{transl}}

Because this template uses {{lang}} and {{transl}} which emit their own error messages, see the help text for those at:

Category:Lang and lang-xx template errors – for error messages emitted by {{lang}}
Category:Transliteration template errors – for error messages emitted by {{transl}}

Limitations

This cannot be used within a Wikilink in an article or in any template or other page that is transcluded into an article.

See also

Template data

This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. See a monthly parameter usage report for Template:Nihongo in articles based on its TemplateData.

TemplateData for Nihongo

This template is used to display Japanese text, applying the correct code and formatting.

Template parameters[Edit template data]

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
English text1

The word as translated into English. Note this will sometimes be the actual Japanese word if it has been adopted into English.

Stringoptional
Kanji/kana text2

The word as written in Japanese (kanji, kana, Roman letters, and possibly other marks).

Stringrequired
Romanized (rōmaji) text3

Transliteration of the Japanese word, using Hepburn Romanization.

Stringoptional
Lead formattinglead

If set to yes, changes formatting style for the first instance of Japanese, usually in the lead. It gives the reader an idea what kind of non-English writing they are viewing.

Suggested values
yes
Auto value
yes
Stringoptional
Extra text inside parentheses4 extra

Adds extra text inside the parentheses.

Stringoptional
Extra text outside parentheses5 extra2

Adds extra text outside the parentheses. It is only useful in ";" definitions (it will be displayed without bold, whereas text following the template, will be bolded). Literal translations and linguistic glosses must use single quotation marks, not double.

Stringoptional

Retrieved from "https://en.wikipedia.org/w/index.php?title=Template:Nihongo&oldid=978907498"

Categories: 
Lua-based templates
Japonic multilingual support templates
WikiProject Japan templates
Hidden categories: 
Wikipedia template-protected templates
Templates not safe for use in citation templates
Templates using TemplateData
 



This page was last edited on 17 September 2020, at 17:04 (UTC).

Text is available under the Creative Commons Attribution-ShareAlike License 4.0; additional terms may apply. By using this site, you agree to the Terms of Use and Privacy Policy. Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization.



Privacy policy

About Wikipedia

Disclaimers

Contact Wikipedia

Code of Conduct

Developers

Statistics

Cookie statement

Mobile view



Wikimedia Foundation
Powered by MediaWiki