Home | History | Annotate | Download | only in EmuRuntimeDxe

Lines Matching defs:Language

27 /// The size of a 3 character ISO639 language code.

372 Get index from supported language codes according to language string.
374 This code is used to get corresponding index in supported language codes. It can handle
375 RFC4646 and ISO639 language tags.
376 In ISO639 language tags, take 3-characters as a delimitation to find matched string and calculate the index.
377 In RFC4646 language tags, take semicolon as a delimitation to find matched string and calculate the index.
390 @param SupportedLang Platform supported language codes.
391 @param Lang Configured language.
394 @retval the index of language in the language codes.
423 // Compare RFC4646 language code
434 // Determine the length of the next language code in SupportedLang
452 Get language string from supported language codes according to index.
454 This code is used to get corresponding language string in supported language codes. It can handle
455 RFC4646 and ISO639 language tags.
456 In ISO639 language tags, take 3-characters as a delimitation. Find language string according to the index.
457 In RFC4646 language tags, take semicolon as a delimitation. Find language string according to the index.
470 @param SupportedLang Platform supported language codes.
471 @param Index the index in supported language codes.
474 @retval the language string in the language codes.
492 // according to the index of Lang string in SupportedLang string to get the language.
503 // take semicolon as delimitation, sequentially traverse supported language codes.
518 // according to the index of Lang string in SupportedLang string to get the language.
536 Returns a pointer to an allocated buffer that contains the best matching language
539 This function supports both ISO 639-2 and RFC 4646 language codes, but language
542 list of language codes to test against all the language codes in SupportedLanguages.
547 contains a set of language codes in the format
549 @param[in] Iso639Language If TRUE, then all language codes are assumed to be
550 in ISO 639-2 format. If FALSE, then all language
551 codes are assumed to be in RFC 4646 language format
554 language codes in the format specified by Iso639Language.
555 The first language code from each of these language
557 close match to any of the language codes in
559 language codes, and the matching algorithm from RFC 4647
562 language code from SupportedLanguages is returned. If
567 @retval NULL The best matching language could not be found in SupportedLanguages.
569 language.
571 language in SupportedLanguages.
583 CHAR8 *Language;
592 while ((Language = VA_ARG (Args, CHAR8 *)) != NULL) {
597 LanguageLength = MIN (3, AsciiStrLen (Language));
600 // If in RFC 4646 mode, then determine the length of the first RFC 4646 language code in Language
603 for (LanguageLength = 0; Language[LanguageLength] != 0 && Language[LanguageLength] != ';'; LanguageLength++);
607 // Trim back the length of Language used until it is empty
611 // Loop through all language codes in SupportedLanguages
615 // In RFC 4646 mode, then Loop through all language codes in SupportedLanguages
623 // Determine the length of the next language code in Supported
627 // If Language is longer than the Supported, then skip to the next language
634 // See if the first LanguageLength characters in Supported match Language
636 if (AsciiStrnCmp (Supported, Language, LanguageLength) == 0) {
647 // If ISO 639 mode, then each language can only be tested once
652 // If RFC 4646 mode, then trim Language from the right to the next '-' character
654 for (LanguageLength--; LanguageLength > 0 && Language[LanguageLength] != '-'; LanguageLength--);
726 // PlatformLang holds a single language from PlatformLangCodes,
800 // When setting PlatformLang, firstly get most matched language string from supported language codes.
805 // Get the corresponding index in language codes.
810 // Get the corresponding ISO639 language tag according to RFC4646 language tag.
833 // When setting Lang, firstly get most matched language string from supported language codes.
838 // Get the corresponding index in language codes.
843 // Get the corresponding RFC4646 language tag according to ISO639 language tag.