You will need to add the full screen parameter to the display declaration as follows:
import pygame, sys
from pygame.locals import *
pygame.init()
DISPLAYSURF = pygame.display.set_mode((400, 300), FULLSCREEN)
mainLoop = True
while mainLoop:
for event in pygame.event.get():
if event.type == pygame.QUIT:
mainLoop = False
pygame.display.update()
pygame.quit()
source
share