对于大多数的14个月左右我已经发布Linked List, I’ve been using small stars as the permalink markers for each entryInstead of small graphic images for the markers, I use a Unicode HTML entity:
& # 9733;一个省,黑星。
However, when viewed using Safari on my new Mac Mini (running a stock installation of 10.4.2, with no third-party fonts, and all of the fonts that shipped with the Mini enabled), they looked like this:
My first thought was that it must be a problem with my CSS, that I’d somehow introduced a bug that caused the
永久链接class to be rendered too smallBut after bumping up the font size a few clicks I could see that it wasn’t even the correct star shape — it’s a less angular, more childish star:
Testing on a few different Macs, all running Safari 2.0 and Mac OS X 10.4.2, produced inconsistent resultsSome displayed the stars as intended, others didn’t与卡米诺and Firefox, however, the stars displayed correctly on every systemOnly in Safari did the results vary.
Most of the characters in the Unicode character set aren’t represented in most typefaces; so, when you ask for one of them and the “current font” has no glyph to represent the character, the system uses an appropriate glyph from a font that不represent the character. Common text fonts like Helvetica, Times, Georgia, and Verdana (my text font here at 万博manbetx贴吧) don’t have built-in glyphs for the
& # 9733;明星。
So, I copied the star character displayed in Safari and pasted it into TextEditI then opened the Fonts palette to see which font was being used to display the glyphOn the systems where it displayed correctly, the font for the star was Hiragino Kaku Gothic Pro, a Japanese sans serif.1On the systems where it displayed incorrectly, the font was Mshtakan, an Armenian typeface.
So, the problem is that when Mshtakan is available, and the “current font” doesn’t contain the black star glyph, Web Kit uses the (ugly) glyph from Mshtakan rather than (correct) glyph from Hiragino Kaku Gothic.
这个问题可能不是Web工具包的错,Using the Character Palette, if you insert a black star in TextEdit while using a font that doesn’t contain the glyph, you’ll get the star from Mshtakan (if Mshtakan is available)What sucks about this is that of all the fonts that contain a glyph for this character,2Mshtakan is the only font that could be considered a poor choice.
The star varies slightly in size depending on the font (it’s a little smaller in Zapf Dingbats, for example), but only in Mshtakan is it significantly smaller, and only in Mshtakan is it a differently-shaped star.
The workaround was simple: in my CSS, I now ask for specific font families for my
Web Kit will now try to use the star from those fonts before resorting to Mshtakan.
Using Safari 2.0 on a 10.4.2 system with the Mshtakan font available, it looks like this:
Using Safari 2.0 on a 10.4.2 system that doesn’t have Mshtakan, it looks like this:
And using either Camino or Firefox, regardless if Mshtakan is available, it looks like this:
Note that the Gecko renderer (used in both Camino and Firefox) chooses the exact same star glyph, regardless of the specified fontI consider this more desirable than Web Kit’s “I’ll show you different stars depending on which fonts you have available” behavior.
如果你打开Safari的“使用ATSU所有文本”选项(通过Debug menu), Safari will display a proper star glyph by default, even when Mshtakan is available:
我不建议把狩猎的ATSUrendering option on, however, as it results in generally unsightly kerning.
而且，对于好奇，Nat熨斗sent the following screenshot of the demo page as displayed by IE 6 running on Windows 2000: