如何添加等宽文本?
我需要在 TextBlock 中为我正在开发的 Windows Phone 7 应用程序使用等宽字体。我尝试了可用的那些,但它们似乎都不是等宽的。
我该怎么做?
I need a monospace font in the TextBlock for a Windows Phone 7 app that I am working on. I tried the ones available and none of them seem to be monospace.
How can I do this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我刚刚意识到 Courier New 也是等宽的,而且看起来效果很好。
I just realized that Courier New is monospaced too and it seems to work pretty fine.
您可以从某处下载等宽字体并按照此处讨论的方式使用它。
向 WP7 应用添加外部字体
You could download a monospace font from somewhere and use it as discussed here.
Adding an external font to WP7 app
Windows Phone 附带的另一种字体是 Segoe UI Mono。它可能看起来更好,因为它是默认的“Metro”(或现代)UI 类型系列的一部分。使用它如下:
Another font that's included with Windows Phone is Segoe UI Mono. It might look better since it is part of the default "Metro" (or Modern) UI type family. Use it as in: