且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

原始Win32中的Rich Edit控件

更新时间:2023-02-27 08:20:11

使用MFC,RichEdit控件可以正常工作.

Using MFC, RichEdit controls just work.

使用InitCommonControlsEx()进行加载-ICC_USEREX_CLASSES不会加载RichEdit AFAIK,您不需要它,因为它只会加载不包含richedit的标准"通用控件.显然,您只需要调用此选项即可在Windows中启用视觉样式",而不必让RichEdits正常工作.

Loading with InitCommonControlsEx() - ICC_USEREX_CLASSES doesn't load RichEdit AFAIK, you don't need it as it only does the 'standard' common controls, which don't include richedit. Apparently you only need to call this to enable 'visual styles' in Windows, not to get RichEdits working.

如果您使用的是2008,则要包含Msftedit.dll并改用MSFTEDIT_CLASS(MS有时是向后兼容的垃圾).

If you're using 2008, you want to include Msftedit.dll and use the MSFTEDIT_CLASS instead (MS are rubbish for backward compatibilty sometimes).

文档确实建议您正在正确地进行Win32编程.

The docs do suggest you're doing it right for Win32 programming.