#NEWLINE# def check_regular( filename ) : #NEWLINE# #INDENT# fontdata = fontToolsOpenFont ( filename ) #NEWLINE# isRegular = True #NEWLINE# if ( fontdata [ 'OS/2' ] . fsSelection & 17 ) : #NEWLINE# #INDENT# isRegular = False #NEWLINE# #UNINDENT# if ( fontdata [ 'head' ] . macStyle & 3 ) : #NEWLINE# #INDENT# isRegular = False #NEWLINE# #UNINDENT# return ( ( fontdata [ 'OS/2' ] . usWeightClass == 400 ) and isRegular )