Lines Matching refs:font
122 font = None
130 if name_id <= last_name_id and font is not None:
131 fonts.append(font)
132 font = None
134 if font is None:
135 font = FontInfo()
137 font.family = namerecord.text.strip()
139 font.style = namerecord.text.strip()
141 font.ends_in_regular = ends_in_regular(namerecord.text)
142 font.fullname = namerecord.text.strip()
144 font.version = get_version(namerecord.text)
145 if font is not None:
146 fonts.append(font)
153 font = None
158 font = fonts_iterator.next()
159 font = update_font_name(font)
162 namerecord.text = font.family
164 namerecord.text = font.fullname
167 def update_font_name(font): argument
173 if font.family is None or font.style is None:
175 if font.version is not None:
176 new_family = font.family + font.version
178 new_family = font.family
179 if font.style is 'Regular' and not font.ends_in_regular:
180 font.fullname = new_family
182 font.fullname = new_family + ' ' + font.style
183 font.family = new_family
184 return font