Kern a group with other groups but not with each other?
-
skyrailhighline
- Posts: 17
- Joined: 25 Apr 2021
Kern a group with other groups but not with each other?
I want my small numerals to be kerned with other glyphs for example letters – superiors, but I don't need the superiors to be kerned with each other. Is this possible?
Re: Kern a group with other groups but not with each other?
This isn't explicitly possible as you describe it. What you can do is set one side of the superiors to "no kerning", which will disable all kerning between superiors, but keep kerning on one side of the superiors with all other glyphs.
Otherwise, enumerate all superior combinations and add them as independent pairs (userData key "KernOnIndependentPairs").
Otherwise, enumerate all superior combinations and add them as independent pairs (userData key "KernOnIndependentPairs").
- Tim Ahrens
- Site Admin
- Posts: 502
- Joined: 11 Jul 2019
Re: Kern a group with other groups but not with each other?
Setting one side to “No kerning” is a smart idea, and it will work.
Yes, that’s another possibility. Just for clarification: set them as independent pairs with value zero to “deactivate” them.
-
skyrailhighline
- Posts: 17
- Joined: 25 Apr 2021
Re: Kern a group with other groups but not with each other?
Thank you for the response. What's the quickest way to add them as independent pairs with value=0 – is there a programmatic way?
- Tim Ahrens
- Site Admin
- Posts: 502
- Joined: 11 Jul 2019
Re: Kern a group with other groups but not with each other?
You could use this script in the macro panel:
You may need to change glyphNames so as to reflect the ones you use (select them, right-click, copy glyph names space separated).
Then copy the output into a new tab, select all and set them as independent pairs. Then, set their value to zero.
Code: Select all
glyphNames = 'zeroinferior oneinferior twoinferior threeinferior fourinferior fiveinferior sixinferior seveninferior eightinferior nineinferior zerosuperior onesuperior twosuperior threesuperior foursuperior fivesuperior sixsuperior sevensuperior eightsuperior ninesuperior'
glyphNames = glyphNames.split()
for first in glyphNames:
for second in glyphNames:
print('/'+first+'/'+second)
Then copy the output into a new tab, select all and set them as independent pairs. Then, set their value to zero.