I’m writing a WPF app and the font that I am using only has problems running in WPF – it works fine using it in anything else (notepad, wordpad, etc.). The problem with WPF is that it falls back to another font sometimes. By “sometimes” I mean that only characters [a-zA-Z] appear to render correctly – everything else appears to be rendered as the default TextBox font.
Does anyone know if WPF has some sort of limitation for the fonts that it supports? It almost seems to be bug in WPF – the font works fine everywhere else.
The font that I’m trying to use is the “Scramble” TTF font (http://famousfonts.smackbomb.com/fonts/scrabble.php).
Numbers and spaces should be seen as a blank Scrabble/Scramble tile, but instead the number itself appears in the textbox I’m using.
The code I’m using:
<TextBox Text="Testing testing testing" FontFamily="Fonts/#Scramble" />
Has anyone else experienced something similar?
Any suggestions would rock!
Thanks!
From MSDN:
My guess would be that the font doesn’t support Unicode – the font itself was created in 1996, and since it’s intended to emulate Scrabble pieces, I’m not sure that the font author even considered localization.
EDIT
According to the font documentation, the font supports the letters, and any number is supposed to render a blank tile. Spaces don’t render a tile.