作者:快乐俱乐部老巢_260 | 来源:互联网 | 2023-09-04 19:47
IoftenusesimpleChinesephraseslike你好totestthatmycodecanhandlenon-asciicharacters.W
I often use simple Chinese phrases like "你好" to test that my code can handle non-ascii characters. Whenever I enter Chinese characters directly into Emacs, they just come out as question marks.
我经常使用像“你好”这样的简单中文短语来测试我的代码可以处理非ascii字符。每当我将中文字符直接输入Emacs时,它们就会出现问号。
Emacs can sometimes display characters properly if I open a premade text file but not always. For example, if I create a simple text file in Notepad with "你好" in it, the 好 displays fine but 你 just shows a box. Can Emacs handle Chinese characters? If so, how do I set it up?
如果我打开预制文本文件但是并非总是如此,Emacs有时可以正确显示字符。例如,如果我在记事本中创建一个带有“你好”的简单文本文件,那么好显示,但你只显示一个框。 Emacs可以处理汉字吗?如果是这样,我该如何设置?
I'm running Emacs 22.3.1 on Windows with the Courier New font, but I'm also curious about having this work on Linux. I have all the needed Eastern Language packages installed. I can edit in Chinese in Notepad with no problem.
我在Windows上使用Courier New字体运行Emacs 22.3.1,但我也对在Linux上运行这项工作感到好奇。我已经安装了所有需要的东方语言包。我可以在记事本中用中文编辑没问题。
4 个解决方案