[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[pygame] Font render is chopped in half.



I am wondering if anyone can help me. I am trying to get this font rendered but it seems to be only rendering half of what it should be. I have tested the font in Pyglet and it renders fine in that, just not in Pygame. Anything I am missing? Any help would be appreciated.
 
Here is the code and attached is the font.
 
import pygame
 
pygame.init()
screen = pygame.display.set_mode((256, 256))
screen.fill((159, 182, 205))
 
font = pygame.font.Font('PowerClear.ttf', 17)
 
surf = font.render('Why is this half written?', True, (255,255, 255), (159, 182, 205))
 
screen.blit(surf, surf.get_rect())
 
pygame.display.update()
 
while True:
   for event in pygame.event.get():
      if event.type == pygame.QUIT:
         sys.exit()

Attachment: PowerClear.ttf
Description: Binary data