aboutsummaryrefslogtreecommitdiff
path: root/doc_topics
diff options
context:
space:
mode:
authorThijs Schreijer <thijs@thijsschreijer.nl>2024-06-19 22:05:33 +0200
committerThijs Schreijer <thijs@thijsschreijer.nl>2024-06-19 22:05:33 +0200
commite0871d7be63dd428d4a2b9a3db4e033894165cef (patch)
tree9a844f267ec9ec99ba745680453b683dd73a6f5b /doc_topics
parent8996a5022fa82e5d5335f71580d0cd6b6d323c9b (diff)
downloadluasystem-e0871d7be63dd428d4a2b9a3db4e033894165cef.tar.gz
luasystem-e0871d7be63dd428d4a2b9a3db4e033894165cef.tar.bz2
luasystem-e0871d7be63dd428d4a2b9a3db4e033894165cef.zip
add system.CODEPAGE_UTF8 for 65001 codepage
Diffstat (limited to 'doc_topics')
-rw-r--r--doc_topics/03-terminal.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc_topics/03-terminal.md b/doc_topics/03-terminal.md
index 06a6b96..9bad359 100644
--- a/doc_topics/03-terminal.md
+++ b/doc_topics/03-terminal.md
@@ -51,8 +51,8 @@ recent versions of Lua also have UTF-8 support. So `luasystem` also focusses on
51 51
52On Windows UTF-8 output can be enabled by setting the output codepage like this: 52On Windows UTF-8 output can be enabled by setting the output codepage like this:
53 53
54 -- setup Windows output codepage to UTF-8; 65001 54 -- setup Windows output codepage to UTF-8
55 sys.setconsoleoutputcp(65001) 55 sys.setconsoleoutputcp(sys.CODEPAGE_UTF8)
56 56
57Terminal input is handled by the [`_getwchar()`](https://learn.microsoft.com/en-us/cpp/c-runtime-library/reference/getchar-getwchar) function on Windows which returns 57Terminal input is handled by the [`_getwchar()`](https://learn.microsoft.com/en-us/cpp/c-runtime-library/reference/getchar-getwchar) function on Windows which returns
58UTF-16 surrogate pairs. `luasystem` will automatically convert those to UTF-8. 58UTF-16 surrogate pairs. `luasystem` will automatically convert those to UTF-8.