Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Language code collisions in name table helper functions #3733

Open
andrewsuzuki opened this issue Dec 24, 2024 · 1 comment
Open

Language code collisions in name table helper functions #3733

andrewsuzuki opened this issue Dec 24, 2024 · 1 comment

Comments

@andrewsuzuki
Copy link

_MAC_LANGUAGES has multiple language IDs with the same IETF BCP 47 string: es (6 and 27) and ga (35 and 146).

_WINDOWS_LANGUAGES also: es (0x0C0A and 0x040A) and sms (0x203B and 0x1C3B).

These dicts are reversed into _MAC_LANGUAGE_CODES and _WINDOWS_LANGUAGE_CODES, so the string only refers to one of the two language IDs in each case, when used in findMultilingualName or addMultilingualName.

macLang = _MAC_LANGUAGE_CODES.get(language.lower())

Perhaps give a warning in these special cases?

@dscorbett
Copy link
Member

According to the latest Windows language code list, 0x203B is sms-FI and 0x1C3B is sma-SE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants