资源文件是否编译为UNICODE或ANSI代码页? [英] Are resource files compiled as UNICODE or ANSI code-page?

查看:126
本文介绍了资源文件是否编译为UNICODE或ANSI代码页?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

首先 - 我的道歉如果这已经回答了一百次!不,我的搜索显然很糟糕,因为我没有运气回答这个基本问题:


如何将资源存储在EXE / DLL中?作为UNICODE(UCS-2,Windows本机内部字符格式),或使用资源块代码页的多字节字符?





  • 如何将UNICODE字符串嵌入资源(.rc)?

  • 可以将UNICODE(UCS-2)文本从VS 2012中插入到语言字符串中吗?

  • Windows是否仍然使用UCS-2或是否在内部使用UTF16?



我只是寻找一般答案,或链接到详细信息,而不是详细的how-to将UNICODE字符串放入.rc字符串表中。谢谢!

解决方案

WIN32中的所有资源字符串都编译为Unicode。有关详细信息,请参阅此处。 .rc脚本本身可以是ANSI(使用本地代码页)或具有适当BOM的UCS-2(参考)。


First - my apologies if this has been answered a hundred times over! D'oh!

But my search-fu apparently sucks, as I'm having no luck answering this basic question:

How are resources stored in the EXE/DLL? As UNICODE (UCS-2, Windows native internal character format), or as multibyte characters using the code-page of the resources block?

  • How does one embed UNICODE strings into one's resources (.rc)?
  • Can UNICODE (UCS-2) text be inserted into the language strings from within VS 2012?
  • Is Windows still using UCS-2, or is it using UTF16 internally?

I'm just looking for general answers, or links to details, rather than a detailed how-to for putting a UNICODE string into an .rc string table. Thanks!

解决方案

All resource strings in WIN32 are compiled as Unicode. See here for more info. The .rc script itself can be ANSI (using the local codepage) or UCS-2 with the appropriate BOM (reference).

这篇关于资源文件是否编译为UNICODE或ANSI代码页?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆