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

fix: Set active CP to UTF-8 on Windows 10 and 11 #139

Merged
merged 1 commit into from
Feb 28, 2024

Conversation

BurningEnlightenment
Copy link
Contributor

This notably allows passing unicode filenames as commandline arguments to the demo utility bin/base64 without them being mangled in case the unicode filename cannot be represented in the currently active system code page.

Note that this only works/takes effect on Windows 10 Version 1903 and later. This is only integrated with CMake as I don't know how to portably invoke the resource compiler in a Makefile. I also added a test case for the CI.

See-Also: https://learn.microsoft.com/en-us/windows/apps/design/globalizing/use-utf8-code-page

Resolves #138

This notably allows passing unicode filenames as commandline arguments
to the demo utility `bin/base64` without them being mangled in case the
unicode filename cannot be represented in the currently active system
code page.

Note that this only works/takes effect on Windows 10 Version 1903 and
later.

See-Also: https://learn.microsoft.com/en-us/windows/apps/design/globalizing/use-utf8-code-page
@aklomp aklomp merged commit 29bb2fd into aklomp:master Feb 28, 2024
39 checks passed
@BurningEnlightenment BurningEnlightenment deleted the bugfix/bin-utf8-codepage branch March 29, 2024 21:04
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

Successfully merging this pull request may close these issues.

Codepage error on Windows
2 participants