OPF
SpecDefinition referenceView source

Language

Inline language metadata for the presentation: a BCP-47 'bcp47' tag plus overrides of what engines know about it. Languages are an engine vocabulary, not catalog records, so there is no 'id'.

Metadata

Definition
#/$defs/Language
Form
object
Source
spec/schemas/opf.schema.json

Field index

FieldTypeReq.Description
namestring—Human-readable language name.
bcp47ref:LanguageTagyesBCP-47 language tag used for locale-aware rendering, proofing, and accessibility metadata. Use 'en-GB' for UK English; 'en-UK' is not a valid BCP-47 region form.
ooxmlLangstring—Culture tag for OOXML text-run language attributes (a:rPr/@lang, a:endParaRPr/@lang), in the language-[Script-]REGION form Office recognizes (e.g. 'ja-JP', 'ar-SA', 'ms-MY', 'nb-NO', 'fil-PH', 'zh-CN'). Without it, engines emit the curated tag of their language vocabulary (spec/reference/engine-vocabularies.json) for a tag without a region, and a region-bearing tag as written. Curated rather than inferred so output does not depend on the runtime's locale data.
codestring—ISO 639-3 or 639-2 language code carried for engines that prefer ISO codes.
directionenum—Base text direction for the language. When omitted, engines derive it from the script: Arabic (Arab), Hebrew (Hebr), Syriac (Syrc), Thaana (Thaa), N'Ko (Nkoo), Adlam (Adlm), Samaritan (Samr), Mandaic (Mand) and Hanifi Rohingya (Rohg) are right-to-left; every other script is left-to-right. The engine language vocabulary (spec/reference/engine-vocabularies.json) states it for the tags it knows.
direction · Allowed values
"ltr""rtl"
scriptstring—ISO 15924 script code of the language's writing system. The script selects the OOXML font slot the language's text uses: East Asian scripts (Hans, Hant, Hani, Jpan, Kore, Hang, Hira, Kana, Bopo, Yiii) use the eastAsian slot; complex scripts (for example Arab, Hebr, Syrc, Thaa, Deva, Beng, Guru, Gujr, Orya, Taml, Telu, Knda, Mlym, Sinh, Thai, Laoo, Tibt, Mymr, Khmr, Mong) use the complexScript slot; every other script (Latn, Cyrl, Grek, Armn, Geor, Ethi, ...) uses the latin slot. When omitted, engines infer it from the BCP-47 tag. The engine language vocabulary (spec/reference/engine-vocabularies.json) states it for the tags it knows. See docs/programs/font-fidelity-everywhere/script-font-model.md.
fontSchemeref:CatalogReference—Font-scheme reference (a bare id or 'name:id') for this language's script slot when targeting PowerPoint output. Its major/minor families fill the language's script slot (eastAsian or complexScript, chosen by 'script') unless the effective design font scheme sets that slot itself; the latin slot always follows the design font scheme. Without it, engines use the default script fonts of their language vocabulary.
googleFontSchemeref:CatalogReference—Font-scheme reference (a bare id or 'name:id') used in place of 'fontScheme' when resolving script fonts for Google Slides output.
summarystring—One-sentence note about coverage or font defaults.
descriptionstring—Longer prose describing the language record and any font-pairing rationale.
tagsarray<string>—Free-form labels for filtering and search.

name

typestringrequirednodefault—

Human-readable language name.

name.json
{
  "name": "English"
}

bcp47

typeref:LanguageTagrequiredyesdefault—

BCP-47 language tag used for locale-aware rendering, proofing, and accessibility metadata. Use 'en-GB' for UK English; 'en-UK' is not a valid BCP-47 region form.

bcp47.json
{
  "bcp47": "en"
}

ooxmlLang

typestringrequirednodefault—

Culture tag for OOXML text-run language attributes (a:rPr/@lang, a:endParaRPr/@lang), in the language-[Script-]REGION form Office recognizes (e.g. 'ja-JP', 'ar-SA', 'ms-MY', 'nb-NO', 'fil-PH', 'zh-CN'). Without it, engines emit the curated tag of their language vocabulary (spec/reference/engine-vocabularies.json) for a tag without a region, and a region-bearing tag as written. Curated rather than inferred so output does not depend on the runtime's locale data.

ooxmlLang.json
{
  "ooxmlLang": "en-US"
}

code

typestringrequirednodefault—

ISO 639-3 or 639-2 language code carried for engines that prefer ISO codes.

code.json
{
  "code": "ENG"
}

direction

typeenumrequirednodefault—

Base text direction for the language. When omitted, engines derive it from the script: Arabic (Arab), Hebrew (Hebr), Syriac (Syrc), Thaana (Thaa), N'Ko (Nkoo), Adlam (Adlm), Samaritan (Samr), Mandaic (Mand) and Hanifi Rohingya (Rohg) are right-to-left; every other script is left-to-right. The engine language vocabulary (spec/reference/engine-vocabularies.json) states it for the tags it knows.

direction · Allowed values
"ltr""rtl"
direction.json
{
  "direction": "ltr"
}

script

typestringrequirednodefault—

ISO 15924 script code of the language's writing system. The script selects the OOXML font slot the language's text uses: East Asian scripts (Hans, Hant, Hani, Jpan, Kore, Hang, Hira, Kana, Bopo, Yiii) use the eastAsian slot; complex scripts (for example Arab, Hebr, Syrc, Thaa, Deva, Beng, Guru, Gujr, Orya, Taml, Telu, Knda, Mlym, Sinh, Thai, Laoo, Tibt, Mymr, Khmr, Mong) use the complexScript slot; every other script (Latn, Cyrl, Grek, Armn, Geor, Ethi, ...) uses the latin slot. When omitted, engines infer it from the BCP-47 tag. The engine language vocabulary (spec/reference/engine-vocabularies.json) states it for the tags it knows. See docs/programs/font-fidelity-everywhere/script-font-model.md.

script.json
{
  "script": "Latn"
}

fontScheme

typeref:CatalogReferencerequirednodefault—

Font-scheme reference (a bare id or 'name:id') for this language's script slot when targeting PowerPoint output. Its major/minor families fill the language's script slot (eastAsian or complexScript, chosen by 'script') unless the effective design font scheme sets that slot itself; the latin slot always follows the design font scheme. Without it, engines use the default script fonts of their language vocabulary.

googleFontScheme

typeref:CatalogReferencerequirednodefault—

Font-scheme reference (a bare id or 'name:id') used in place of 'fontScheme' when resolving script fonts for Google Slides output.

summary

typestringrequirednodefault—

One-sentence note about coverage or font defaults.

description

typestringrequirednodefault—

Longer prose describing the language record and any font-pairing rationale.

tags

typearray<string>requirednodefault—

Free-form labels for filtering and search.

Complete definition constraints
Schema constraints
{
  "type": "object",
  "description": "Inline language metadata for the presentation: a BCP-47 'bcp47' tag plus overrides of what engines know about it. Languages are an engine vocabulary, not catalog records, so there is no 'id'.",
  "required": [
    "bcp47"
  ],
  "not": {
    "required": [
      "id"
    ]
  },
  "properties": {
    "name": {
      "type": "string",
      "description": "Human-readable language name.",
      "examples": [
        "English",
        "English (United Kingdom)",
        "Arabic (Saudi Arabia)"
      ]
    },
    "bcp47": {
      "$ref": "#/$defs/LanguageTag",
      "description": "BCP-47 language tag used for locale-aware rendering, proofing, and accessibility metadata. Use 'en-GB' for UK English; 'en-UK' is not a valid BCP-47 region form.",
      "examples": [
        "en",
        "en-US",
        "en-GB",
        "ar-SA",
        "zh-Hans"
      ]
    },
    "ooxmlLang": {
      "type": "string",
      "description": "Culture tag for OOXML text-run language attributes (a:rPr/@lang, a:endParaRPr/@lang), in the language-[Script-]REGION form Office recognizes (e.g. 'ja-JP', 'ar-SA', 'ms-MY', 'nb-NO', 'fil-PH', 'zh-CN'). Without it, engines emit the curated tag of their language vocabulary (spec/reference/engine-vocabularies.json) for a tag without a region, and a region-bearing tag as written. Curated rather than inferred so output does not depend on the runtime's locale data.",
      "examples": [
        "en-US",
        "ja-JP",
        "ar-SA",
        "ms-MY",
        "nb-NO",
        "zh-CN"
      ]
    },
    "code": {
      "type": "string",
      "description": "ISO 639-3 or 639-2 language code carried for engines that prefer ISO codes.",
      "examples": [
        "ENG",
        "ARA",
        "JPN",
        "ZHO"
      ]
    },
    "direction": {
      "type": "string",
      "enum": [
        "ltr",
        "rtl"
      ],
      "description": "Base text direction for the language. When omitted, engines derive it from the script: Arabic (Arab), Hebrew (Hebr), Syriac (Syrc), Thaana (Thaa), N'Ko (Nkoo), Adlam (Adlm), Samaritan (Samr), Mandaic (Mand) and Hanifi Rohingya (Rohg) are right-to-left; every other script is left-to-right. The engine language vocabulary (spec/reference/engine-vocabularies.json) states it for the tags it knows."
    },
    "script": {
      "type": "string",
      "description": "ISO 15924 script code of the language's writing system. The script selects the OOXML font slot the language's text uses: East Asian scripts (Hans, Hant, Hani, Jpan, Kore, Hang, Hira, Kana, Bopo, Yiii) use the eastAsian slot; complex scripts (for example Arab, Hebr, Syrc, Thaa, Deva, Beng, Guru, Gujr, Orya, Taml, Telu, Knda, Mlym, Sinh, Thai, Laoo, Tibt, Mymr, Khmr, Mong) use the complexScript slot; every other script (Latn, Cyrl, Grek, Armn, Geor, Ethi, ...) uses the latin slot. When omitted, engines infer it from the BCP-47 tag. The engine language vocabulary (spec/reference/engine-vocabularies.json) states it for the tags it knows. See docs/programs/font-fidelity-everywhere/script-font-model.md.",
      "examples": [
        "Latn",
        "Cyrl",
        "Grek",
        "Arab",
        "Hebr",
        "Jpan",
        "Kore",
        "Hans",
        "Hant",
        "Deva",
        "Thai"
      ]
    },
    "fontScheme": {
      "$ref": "#/$defs/CatalogReference",
      "description": "Font-scheme reference (a bare id or 'name:id') for this language's script slot when targeting PowerPoint output. Its major/minor families fill the language's script slot (eastAsian or complexScript, chosen by 'script') unless the effective design font scheme sets that slot itself; the latin slot always follows the design font scheme. Without it, engines use the default script fonts of their language vocabulary."
    },
    "googleFontScheme": {
      "$ref": "#/$defs/CatalogReference",
      "description": "Font-scheme reference (a bare id or 'name:id') used in place of 'fontScheme' when resolving script fonts for Google Slides output."
    },
    "summary": {
      "type": "string",
      "description": "One-sentence note about coverage or font defaults."
    },
    "description": {
      "type": "string",
      "description": "Longer prose describing the language record and any font-pairing rationale."
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Free-form labels for filtering and search."
    }
  }
}