Hi all
Does Kerning ignore marks?
1- If so, how can I have kerning with marks? Will it consider marks? at least did not ignore all marks
2- How can I write kerning conditional with 3 glyphs? (like this: if A then B then C: kerning between A and B is … otherwise is none)
When kerning with precomposed glyphs (base glyph component + mark components), you can kern as usual.
To take combining marks into consideration, you need to write feature code. There, you can control whether marks should be ignored or not.
Can you show me how?
Thanks
This is a wide-ranging topic. If you have specific needs, then I can help you with those once I know the details. If you want to learn the general idea, this book can help (section Lookup Flags):
One approach is Composition. It has better support in older applications, and it’s easier to control a kerning exceptions visually, and that’s why I prefer it.
- Generate a composite glyphs – with a sidebar filter or with recipes. In both cases you can generate about 570+ Latin composites at once. The recipes may looks like this:
A+acutecomb=Aacute
A+brevecomb=Abreve
- Set the Left and Right Groups of composite glyphs the same as groups of a base glyphs. For example, groups of
Aacute
should be the same asA
groups. It could be automated with a script. - Add the
ccmp
feature to compose base glyphs and marks to your composite glyphs (preferably limited by script and sometimes by language) that may looks like this:
sub A acutecomb by Aacute;
sub A brevecomb by Abreve;
More about diacritics and composite glyphs: Diacritics | Glyphs
Another approach is Decomposition. It doesn’t use a composite glyphs (the main goal is to reduce the file size like for webfonts), but relies solely on anchors, mark
and mkmk
features, and contextual kerning, as Florian mentioned: Contextual kerning | Glyphs. Also, in case of decomposition, the ccmp
feature should be reversed, to decompose instead of compose.
sub Aacute by A acutecomb;
sub Abreve by A brevecomb;
Thanks a lot
Much helpful
Thanks @FlorianPircher
Very helpful