使用带有 AntiAliased 或 ClearType 的 LogFont 会出现奇怪的结果
我想在 Windows CE 5 设备上使用自定义字体。它有效,但看起来不太好。所以我尝试看看启用抗锯齿或 ClearType 是否会更好。相反,情况甚至更糟。为了确保我尝试为默认字体 Tahoma 启用它,但效果并没有更好。
使用 http://inthehand 上的说明。 com/blogs/peterfoot/archive/2008/04/02/antialisasing-and-netcf.aspx,左边是预期结果,右边是我得到的结果。
以前有人遇到过这个问题吗?如果有的话,你是如何解决的?
I want to use a custom font on a Windows CE 5 device. It works, but it doesn't look that good. So I tried to see if it would be any better with anti-aliasing or ClearType enabled. Instead, it's even worse. Just to be sure I tried enabling it for the default font, Tahoma, but it's not any better.
Using the instructions on http://inthehand.com/blogs/peterfoot/archive/2008/04/02/antialisasing-and-netcf.aspx, at the left is the expected result and at the right is the result I'm getting.
Has anyone had this problem before, and if so how did you solve it?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果启用 ClearType 后桌面和资源管理器没有显示任何差异,则表明您的设备操作系统和/或显示驱动程序不支持 ClearType,可能还不支持抗锯齿功能。
当您使用尝试使用抗锯齿的代码时,会导致 GDI 向显示驱动程序发送数据,而显示驱动程序不“理解”如何渲染,因此渲染不正确。
返回您的 OEM 并询问他们是否有支持抗锯齿/ClearType 的操作系统映像(如果您拥有的映像不支持,则不太可能),并可能要求他们添加/实现它(对他们来说可能很简单在构建中设置 SYSGEN_GPE_CLEARTYPE)。
If the desktop and explorer show no difference when ClearType is enabled, that indicates that ClearType, and probably anti-aliasing is not supported by your device's OS and/or display driver.
What that's leading to when you use code that tries to use anti-aliasing is GDI sending data to the display driver that it doesn't "understand" how to render so it gets rendered incorrectly.
Go back to your OEM and ask if they have an OS image that has anti-aliasing/ClearType support (unlikely if the image you have doesn't) and maybe ask them to add/implement it (it might be as simple for them as setting SYSGEN_GPE_CLEARTYPE in the build).