-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathutf8.cpp
More file actions
25 lines (23 loc) · 995 Bytes
/
utf8.cpp
File metadata and controls
25 lines (23 loc) · 995 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#include <iostream>
using namespace std;
// Programming in Chinese with UTF-8 in C::B
// Compiler Options:
// -Wall -fexceptions -g -pedantic-errors -std=c++20 -fextended-identifiers -finput-charset=utf-8 -fexec-charset=utf-8
// C::B Settings on the menu
// Use the following registry file:
// Settings -> Editor -> Encoding Settings -> Use encoding when opening files = UTF-8
// Settings -> Editor -> Encoding Settings -> Use this encoding = As default encoding (bypass...)
// Settings -> Editor -> Encoding Settings -> If conversion fails using this settings above, try... = [tick]
// Registry:
// HKEY_CURRENT_USER\Console\$cb_code_runner full path$
// \CodePage = 65001
/* The following is a template of Registry file, replace thost $XXX$
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Console\$cb_code_runner full path$]
"CodePage"=dword:0000fde9
*/
int main() {
const char *姓名 = "阿巴阿巴阿巴";
cout << 姓名 << endl;
return 0;
}