Hi all,
right now i’m working on a programm that does some manual typesetting on a pretty low level, i.e. it handles fonts as vector shapes and places them manually with no help from the OS (Windows in this case). The feature i’m trying to get right at this moment is kerning, and while it seems to work most of the time, there are some artifacts with Cambria. For example, he ’d’ and the ’e’ are too close, and ’tt’ or ’ty’ overlap. So i’ve taken a look into its kerning pairs table and found more than one entry for ’de’, the first one being -6 (at a font size of 40), which is the one used simply because it’s found first. Later on there are some entries with -3 and a couple more with -6, 6 entries total. Typically, i’d expect one kerning value per pair of characters. Is the fact that Cambria has more of them some kind of a glitch in the font, or, if not, which one should i choose? Any help on getting the right kerning values would be greatly appreciated.
Problems with manual kerning
-
- Top Typographer
- Posts: 2038
- Joined: Tue Sep 14, 2004 6:41 pm
- Location: Worcestershire, England
- Contact:
I do not know the answer to your question but decided to try to find out.
I have not found answer thus far yet have found the following web page at the Microsoft Typography webspace and mention it now in case it might be of use.
http://www.microsoft.com/typography/otspec/kern.htm
I am wondering whether perhaps the Cambria font was designed for use on an Apple Macintosh and perhaps uses the Apple extensions to kerning which the above-referenced Microsoft page mentions.
William Overington
11 April 2008
I have not found answer thus far yet have found the following web page at the Microsoft Typography webspace and mention it now in case it might be of use.
http://www.microsoft.com/typography/otspec/kern.htm
I am wondering whether perhaps the Cambria font was designed for use on an Apple Macintosh and perhaps uses the Apple extensions to kerning which the above-referenced Microsoft page mentions.
William Overington
11 April 2008
-
- Top Typographer
- Posts: 2038
- Joined: Tue Sep 14, 2004 6:41 pm
- Location: Worcestershire, England
- Contact:
I searched for kern apple at http://www.yahoo.com and found the following.
http://developer.apple.com/textfonts/TT ... 6kern.html
I have not studied it in detail, yet I did notice the following in the Mac OS-specific information section, which section is near the end of the document.
William Overington
11 April 2008
http://developer.apple.com/textfonts/TT ... 6kern.html
I have not studied it in detail, yet I did notice the following in the Mac OS-specific information section, which section is near the end of the document.
I hope that this helps.Fonts targeted for the Mac OS only should use the new format; fonts targeted for both the Mac OS and Windows should use the old format.
William Overington
11 April 2008
Thanks for the links, I'll take a look. Cambria is one of the fonts Microsoft released with Windows Vista, so it is probably not specifically targeted for Mac OS. I'd rather expect that it would work best with the Windows API, which i am using. If it helps, i can explain the details of my rendering pipeline, maybe there is a bug in there.
-
- Moderator
- Posts: 11194
- Joined: Fri Oct 04, 2002 12:41 am
- Location: Bilthoven, The Netherlands
- Contact:
Re: Problems with manual kerning
This is a bug that I reported to Microsoft's Typography group back in May 2007. Actually I know of 3 Vista fonts that contain duplicate kerning pairs in the kern table. Maybe SP1 will contains updates of these fonts.elpres wrote:Is the fact that Cambria has more of them some kind of a glitch in the font, or, if not, which one should i choose?
There is no guideline about this, so try to find out how Windows rasterizer copes with it.elpres wrote:Any help on getting the right kerning values would be greatly appreciated.
-
- Top Typographer
- Posts: 2038
- Joined: Tue Sep 14, 2004 6:41 pm
- Location: Worcestershire, England
- Contact:
Thank you for the further information. It looks like I was following a, well, not wrong, but an "inappropriate to this specific situation" route when I wondered about whether the font was something to do with the Apple extension to the kern table.elpres wrote:Thanks for the links, I'll take a look. Cambria is one of the fonts Microsoft released with Windows Vista, so it is probably not specifically targeted for Mac OS. I'd rather expect that it would work best with the Windows API, which i am using.
When you mentioned fonts and Vista, I remembered something and found this post.
viewtopic.php?t=1780
The licensing of the fonts is mentioned specifically on the Microsoft web page and it appears to me (I am not a lawyer!) to be quite generous to people using computers using the Windows operating system.
I have only done a little about kerning myself. In case it is of any use in trying with your program and analysing what is going on in your program I mention my Kern Deco fonts. As I made the fonts myself I know exactly what is in them as regards kerning. The kerning is very noticeable.
The kerning is in some of the uppercase character pairs. There is some documentation and examples with the fonts and maybe the large size of the kerns might perhaps show obviously in your program.
viewtopic.php?t=1823
There are 18 posts in the thread at the moment, yet the regular font is linked from the first post in the thread and, in fact, version 0.052 is now supplied by that link: the changes are that there are three new kerning pairs, namely PS, FS and JS, each at -512 font units.
In case it might help in testing, I mention that my Whiteboard Venetian typeface has regular, italic, bold and bold italic fonts and each has just one kerning pair, namely qu, set at -128 font units.
viewtopic.php?t=1989
I have tried looking at which kerning pairs Cambria displays in FontCreator and there was unpacking of a .TTC file and I ended up looking at a file CAMBRIA_0.ttf and could not find any kerning pairs for any of the de, tt, or ty pairs which you mention in your first post in this thread, though there are a lot of kerning pairs in the font so maybe I missed them.
William Overington
11 April 2008
Erwin, nice to know that you can confirm the bug in Cambria, instead of me missing something in the implementation. I've made a screenshot of a text string rendered with (from top to bottom) Calibri (another Vista font), Cambria and Arial, where the problems in Cambria are quite clear:
From how the other two fonts are rendered and how the kerning worked with Cambria's capital letters i'd assume that i'm doing it right. The actual proccess is rather straight forward and there's not much room to make a mistake.
I've also dumped the kerning tables for Arial and Cambria, if somebody wants to take a look. The latter has 9812 pairs, but a lot of duplicates, e.g. 20 times 'AC', all with the same kerning amount.
Thanks for your help.
From how the other two fonts are rendered and how the kerning worked with Cambria's capital letters i'd assume that i'm doing it right. The actual proccess is rather straight forward and there's not much room to make a mistake.
I've also dumped the kerning tables for Arial and Cambria, if somebody wants to take a look. The latter has 9812 pairs, but a lot of duplicates, e.g. 20 times 'AC', all with the same kerning amount.
Thanks for your help.
-
- Top Typographer
- Posts: 9888
- Joined: Tue Oct 29, 2002 5:28 am
- Location: Seven Kings, London UK
- Contact:
-
- Moderator
- Posts: 11194
- Joined: Fri Oct 04, 2002 12:41 am
- Location: Bilthoven, The Netherlands
- Contact: