pygame.font.init()
font_path = pygame.font.match_font('bitstreamverasans')
if not font_path:
pygame.font.get_default_font()
font = pygame.font.Font(font_path, 12)
print(font.metrics("My text string"))
print(font.get_linesize(), font.get_height())
pygame.font.quit()¶