#NEWLINE# def _parse_kerning( self , rx , sign , text , classes , unmatched ) : #NEWLINE# #INDENT# 'Parse kerning rules.' #NEWLINE# for rule in rx . findall ( text ) : #NEWLINE# #INDENT# ( left , right , val ) = rule #NEWLINE# val = int ( val ) #NEWLINE# if ( left in classes ) : #NEWLINE# #INDENT# left = classes [ left ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# left = [ left ] #NEWLINE# #UNINDENT# if ( right in classes ) : #NEWLINE# #INDENT# right = classes [ right ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# right = [ right ] #NEWLINE# #UNINDENT# for left_glyph in left : #NEWLINE# #INDENT# for right_glyph in key_match : #NEWLINE# #INDENT# key = ( sign , left_glyph , right_glyph ) #NEWLINE# key_match = ( self . _reverse_sign ( sign ) , left_glyph , right_glyph ) #NEWLINE# if ( val in unmatched [ key_match ] ) : #NEWLINE# #INDENT# unmatched [ key_match ] . remove ( val ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# unmatched [ key ] . append ( val )