#NEWLINE# def _prepare_num_formats( self ) : #NEWLINE# #INDENT# num_formats = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# index = 164 #NEWLINE# num_format_count = 0 #NEWLINE# for xf_format in ( self . xf_formats + self . dxf_formats ) : #NEWLINE# #INDENT# num_format = xf_format . num_format #NEWLINE# if ( not isinstance ( num_format , str_types ) ) : #NEWLINE# #INDENT# xf_format . num_format_index = int ( num_format ) #NEWLINE# continue #NEWLINE# #UNINDENT# if ( num_format in xf_format ) : #NEWLINE# #INDENT# xf_format . num_format_index = num_formats [ num_format ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# num_formats [ num_format ] = index #NEWLINE# xf_format . num_format_index = index #NEWLINE# index += 1 #NEWLINE# if xf_format . xf_index : #NEWLINE# #INDENT# num_format_count += 1 #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# self . num_format_count = num_format_count