Перейти к содержанию

Халип:Lang-it

Википедия — эркенаб энциклопедия сайталдасан материал

итал. {{{1}}}

Пайда босизе Пайда босизе

Халип:Language templates

The purpose of this template is to indicate that a span of text belongs to a particular language. It often makes no visible changes to the text but can prompt web browsers to use a more appropriate font or screen readers to use a particular kind of pronunciation and so on. See § Rationale for more information.

Синтаксис

     {{lang|мацӀалъул тэг|текст}}

Парансалъе бихьизабизе ккола код fr:

  • Гьелъ абуна: "{{lang|fr|Je suis française.}}" → Гьелъ абуна: "Je suis française."

Форматин

Автоматикияб италик

{{lang}}-алъ автоматикалго хӀалтизабула италик (курсив) {{{2}}} текст хъван буго Latn хатӀалда (латин алфабет ва элъул гӀатӀилъаби), яги эбго код мацӀазе жибгояб бугони, яги гьеб инициатун буго xx-Latn кодалъ:

  • {{lang|fr|Je suis française.}}Je suis française.
  • ''{{lang|fr|Je suis française.}}''Je suis française. – къватӀисеб куц рикӀкӀунаро
  • {{lang|he-Latn|la'az}} ({{lang|he|לעז}})la'az (לעז)
  • ''{{lang|he-Latn|la'az}}'' (''{{lang|he|לעז}}'')la'az (לעז) – he-Latn тексталда сверун бугеб куц риккӀунаро, хӀо жугьутӀ хъвагӀаз бихьизабураб материал мекъи кьола курсивалдалъун.

Latn хъвай италикалдалъун бихьизабизе гьечӀони, буго чанго батӀияб куц гьеб гьабизе: |italic=no – бихьизабула {{{2}}} битӀахъе чӀараб текстлъун; шаблоналда сверун бугеб жо риккӀунаро; шаблоналда жаниб бугеб италик мекъилъун бихьизабула:

  • {{lang|fr|Je suis française.|italic=no}}Je suis française.
  • ''{{lang|fr|Je suis française.|italic=no}}''Je suis française.
  • ''{{lang|fr|Je suis ''française''.|italic=no}}''[Je suis française.] Error: {{Lang}}: text has italic markup (help) – италик куцалъул конфликт лӀугьуна |italic=no параметргун.

|italic=unset – параметралъ свинарула шаблоналъул стилал; {{{2}}} стиллъизабун буго жанисебги къватӀисебги куцалда рекъон:

  • {{lang|fr|Je suis française.|italic=unset}}Je suis française.
  • ''{{lang|fr|Je suis française.|italic=unset}}''Je suis française.
  • {{lang|fr|''Je suis'' English.|italic=unset}}Je suis English.

{{noitalic}} гьединго бегьула хӀалтӀизабизе:

Parameters

lang supported parameters
parameter definition yields to alias
code IETF language tag for the content in text {{{1}}}
text non-English text {{{2}}}
rtl yes indicates that the writing system used for the content in text is right-to-left; accepted values are: no (default), yes IETF script subtag in code (if provided)
italic Халип:Crossref; accepted values are: yes, no, unset, invert, default italics,i
size specifies font size of the content in text; use a value suitable for use with the CSS font-size property; this should almost always be a relative value supplied in Халип:Mxt or Халип:Mxt units, not a fixed px value.
nocat inhibits automatic categorization; mirror version of cat; accepted values are: yes, y, true, t, on, 1
cat inhibits automatic categorization; mirror version of nocat; accepted values are: no, n, false, f, off, 0
lang |italic= parameter operation
|italic= value description example code result html markup
  • parameter not present;
  • parameter present, not set;
  • invalid value
  • module applies style from:
  •   auto-italics or
  •   script subtag latn;
  • else inherits from external markup;
  • invalid values treated as default
{{lang|ru|тундра}} тундра <span title="ГӀурус-мацӀаб текст"><span lang="ru">тундра</span></span>
Халип:Deprecated code tûndra <span title="ГӀурус-мацӀаб текст"><i lang="ru">tûndra</i></span>
Incorrect markup; this requires |ru-Latn.
{{lang|fr|toundra}} toundra <span title="Паранс-мацӀаб текст"><i lang="fr">toundra</i></span>
{{lang|ru-Latn|tûndra}} tûndra <span title="ГӀурус-мацӀаб текст"><i lang="ru-Latn">tûndra</i></span>
default {{lang|ru|тундра|italic=default}} тундра <span title="ГӀурус-мацӀаб текст"><span lang="ru">тундра</span></span>
{{lang|fr|toundra|italic=default}} toundra <span title="Паранс-мацӀаб текст"><i lang="fr">toundra</i></span>
{{lang|ru-Latn|tûndra|italic=default}} tûndra <span title="ГӀурус-мацӀаб текст"><i lang="ru-Latn">tûndra</i></span>
no
  • module applies upright style;
  • overrides auto-italics
  • overrides script subtag latn;
  • overrides external markup
{{lang|ru|тундра|italic=no}} тундра <span title="ГӀурус-мацӀаб текст"><span lang="ru" style="font-style: normal;">тундра</span></span>
{{lang|fr|toundra|italic=no}} toundra <span title="Паранс-мацӀаб текст"><span lang="fr" style="font-style: normal;">toundra</span></span>
{{lang|ru-Latn|tûndra|italic=no}} tûndra <span title="ГӀурус-мацӀаб текст"><span lang="ru-Latn" style="font-style: normal;">tûndra</span></span>
''{{lang|fr|toundra|italic=no}}'' toundra ''<span title="Паранс-мацӀаб текст"><span lang="fr" style="font-style: normal;">toundra</span></span>''
yes
  • module applies italic style;
  • ignores auto-italics;
  • ignores script subtag latn
{{lang|ru|тундра|italic=yes}} тундра <span title="ГӀурус-мацӀаб текст"><i lang="ru">тундра</i></span>
{{lang|ru-Latn|tûndra|italic=yes}} tûndra <span title="ГӀурус-мацӀаб текст"><i lang="ru-Latn">tûndra</i></span>
unset
  • module applies no style;
  • inherits style from external markup;
  • disables auto-italics
  • overrides script subtag latn;
{{lang|ru|тундра|italic=unset}} тундра <span title="ГӀурус-мацӀаб текст"><span lang="ru">тундра</span></span>
''{{lang|ru|тундра|italic=unset}}'' тундра ''<span title="ГӀурус-мацӀаб текст"><span lang="ru">тундра</span></span>''
{{lang|ru-Latn|tûndra|italic=unset}} tûndra <span title="ГӀурус-мацӀаб текст"><span lang="ru-Latn">tûndra</span></span>
''{{lang|ru-Latn|tûndra|italic=unset}}'' tûndra ''<span title="ГӀурус-мацӀаб текст"><span lang="ru-Latn">tûndra</span></span>''
invert
  • module applies no style;
  • inverts style in internal markupХалип:Dagger;
  • disables auto-italics
  • overrides script subtag latn;
{{lang|ru|тундра|italic=invert}} тундра <span title="ГӀурус-мацӀаб текст"><span lang="ru">''тундра''</span></span>
{{lang|ru|''тундра''|italic=invert}} тундра <span title="ГӀурус-мацӀаб текст"><span lang="ru">тундра</span></span>
{{lang|ru-Latn|tûndra|italic=invert}} tûndra <span title="ГӀурус-мацӀаб текст"><span lang="ru-Latn">''tûndra''</span></span>
{{lang|ru-Latn|''tûndra''|italic=invert}} tûndra <span title="ГӀурус-мацӀаб текст"><span lang="ru-Latn">tûndra</span></span>

Халип:Dagger compare |italic=invert to |italic=unset:

{{Lang|de|... ein neues Opernprojekt in Angriff: ''Das Käthchen von Heilbronn'', nach Heinrich von Kleists gleichnamigem Drama.|italic=invert}}
... ein neues Opernprojekt in Angriff: Das Käthchen von Heilbronn, nach Heinrich von Kleists gleichnamigem Drama.
{{Lang|de|''... ein neues Opernprojekt in Angriff: ''Das Käthchen von Heilbronn'', nach Heinrich von Kleists gleichnamigem Drama.''|italic=unset}}
... ein neues Opernprojekt in Angriff: Das Käthchen von Heilbronn, nach Heinrich von Kleists gleichnamigem Drama.

the function selector parameter

{{lang}} uses the Lua function lang() Module:Lang. That module also supports all of the {{lang-??}} templates using the Lua functions lang_xx_inherit() and lang_xx_italic(). The module has other functions that may be useful. The function selector parameter |fn= tells module:lang which function to execute. The available functions are:

  • is_ietf_tag – returns true if the provided IETF language tag is valid; nil else
    • {{lang|fn=is_ietf_tag|nv}} →true←
    • {{lang|fn=is_ietf_tag|xx}} →←
  • is_lang_name – returns true if the provided language name is valid; nil else
    • {{lang|fn=is_lang_name|navajo}} →←
    • {{lang|fn=is_lang_name|xxxxx}} →←
  • lang – the function that renders {{lang}}; listed here for completeness, this particular usage is more-or-less pointless
  • lang_xx_inherit – the function that renders {{lang-??}} template where the text is not italicized; can be used when a {{lang-??}} template, for example {{lang-aao}}, does not exist for a particular language:
    • {{lang|fn=lang_xx_inherit|code=aao|Algerian Saharan Arabic text}}Algerian Saharan Arabic: Algerian Saharan Arabic text
  • lang_xx_italic – the function that renders {{lang-??}} template where the text is italicized; can be used when a {{lang-??}} template, for example {{lang-svc}}, does not exist for a particular language:
    • {{lang|fn=lang_xx_italic|code=svc|Vincentian Creole English text}}Vincentian Creole English: Vincentian Creole English text
  • name_from_tag – returns the language name associated with the provided IETF language tag:
    • {{lang|fn=name_from_tag|apa}} → Apache languages
  • tag_from_name – returns the ISO 639 language code (sometimes IETF language tag) associated with the provided language name:
    • {{lang|fn=tag_from_name|havasupai}} → yuf-x-hav
  • transl – the function that renders {{transl}}; listed here for completeness, this particular usage is more-or-less pointless
    • {{lang|fn=transl|ar|DIN|al-Ḫawārizmī}}al-Ḫawārizmī

TemplateData

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

TemplateData for Lang-it

Indicate that a given span of text belongs to a particular language. Allows browsers to correctly present and pronounce foreign languages.

Параметры шаблона[Править данные шаблона]

Шаблон использует строчное форматирование параметров.

ПараметрОписаниеТипСтатус
Language tag1 code

A language tag, or an ISO 639 language code.

Пример
fr
Строковый (без форматирования)обязательный
Text2 text

The text belonging to the language specified.

Пример
Je suis française.
Строковый (без форматирования)обязательный
Right to leftrtl

Indicates that the language should be displayed from right to left.

По умолчанию
no
Пример
yes
Строковый (без форматирования)необязательный
Italicizeitalic italics i

Italicizes the text

По умолчанию
yes
Пример
no
Логическое значениенеобязательный
Font-sizesize

sets font-size

Пример
120%, 1.2em
Неизвестнонеобязательный
catcat

без описания

Неизвестнонеобязательный
nocatnocat

без описания

Неизвестнонеобязательный