How to add monospaced text?
-
16-04-2021 - |
質問
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?
解決
I just realized that Courier New is monospaced too and it seems to work pretty fine.
他のヒント
You could download a monospace font from somewhere and use it as discussed here. Adding an external font to WP7 app
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:
<TextBlock FontSize="36" FontFamily="Segoe UI Mono"/>
所属していません StackOverflow