Quantcast
Channel: TypeDrawers
Viewing all articles
Browse latest Browse all 4153

Copy and scale uppercase kerning to small caps with a script

$
0
0
One more simple Robofab script to copy and scale uppercase kerning to small caps. With the 'factor' variable you can decide how much the kerning should be reduced to better fit small caps.

#FLM: ReType CopyKerningUC2sc V 1.0
# Copy & scale kerning from UC to sc

from robofab.world import CurrentFont

font = CurrentFont()
kerning = font.kerning

	
left = ['A','AE','C','D','E','F','G','H','I','J','K','L','M','N','O','OE','P','Thorn','Q','R','S','T','U','V','W','X','Y','Z']
middle= ['A','AE','C','D','E','F','G','H','I','J','K','L','M','N','O','OE','P','Thorn','Q','R','S','T','U','V','W','X','Y','Z']

#Modify this variable to adjust small caps kerning
factor = 10

for A in left:
	for B in middle:
		if kerning[A, B] is not None:
			kerning[str.lower(A)+'.sc', str.lower(B)+'.sc'] = (kerning[A, B]) - factor
								
print 'Klaar!!'

font.update()

Viewing all articles
Browse latest Browse all 4153

Trending Articles