title: how can I sort out a missing required positional argument
body: <p>In my case this is the error I get when I run the code:</p>
  
  <pre><code>TypeError: __init__() missing 1 required positional argument: 'Screen'
  </code></pre>
  
  <p>Now usually this is easily fixable but for some weird reason I can't seem to solve the problem. I use to have a perfectly fine piece of code but now that I started messing around with it, my code is now riddled with errors. I would go back to my old code but once I sort out the errors this new code will by far be a lot better than the old one. Hey like they say, "You got to take everything one step at a time".</p>
  
  <p>The code (sorry for giving such large code but I don't know whether you may need the full code or not in my case):</p>
  
  <pre><code>import pygame
  import sys
  from pygame.locals import *
  
  white = (255,255,255)
  black = (0,0,0)
  objs = []
  MAIN_BUTTON = 1
  
  
  class Pane():
  
      def __init__(self, textToDisplay, coordinates, screen):
          self.textToDisplay = textToDisplay
          self.coordinates = coordinates
          self.screen = screen
  
      def drawPane(self):
          self.screen.blit(self.font.render(textToDisplay, True, (black)), (250, 115))
          pygame.draw.rect(self.screen, (black), self.coordinates, 2)
          pygame.display.update()
  
  
  class Screen():
  
      #constants/array(?) outlining the x,y boundaries of each of x10 panes
  
      #Remember to change co-ordinate values
      #number of panes
      NoOfPanes = 0
      Panes = []
  
      def __init__(self, Screen):
          pygame.init()
          pygame.display.set_caption('Box Test')
  
          self.font = pygame.font.SysFont('Arial', 25)
          Screen = pygame.display.set_mode((1000,600), 0, 32)
          self.screen = Screen #I'm guessing the error of my code is somewhere around here, however I thought that I had overcome the situation. Evidently I haven't "sigh"!
          self.screen.fill((white))
  
          pygame.display.update()
  
      def addPane(self, textToDisplay):
          #right now it is displaying them all change so that it checks how many
          #panes are on through (numberOfPanes = 0) 10 is limit display no more
          #than ten.
          paneLocs = [(175, 75, 200, 100), 
                      (0, 0, 200, 100), 
                      (600, 400, 200, 100), 
                      (175, 75, 200, 100), 
                      (175, 75, 200, 100), 
                      (175, 75, 200, 100), 
                      (175, 75, 200, 100), 
                      (175, 75, 200, 100), 
                      (175, 75, 200, 100), 
                      (175, 75, 200, 100)
                      ]
  
          if self.NoOfPanes &gt; 10:
              print("Limit Reached")            
          else:
              #self.Panes[self.NoOfPanes] = Pane(textToDisplay, paneLocs[self.NoOfPanes])
              #self.Panes[self.NoOfPanes].drawPane()
  
              myPane = Pane(textToDisplay, paneLocs[self.NoOfPanes])
              myPane.drawPane()
  
              self.NoOfPanes = self.NoOfPanes + 1
              pygame.display.update()
  
  
      def mousePosition(self):
          global clickPos
          global releasePos
          for event in pygame.event.get():
              if event.type == MAIN_BUTTON:
                  self.Pos = pygame.mouse.get_pos()
                  return MAIN_BUTTON
              else:
                  return False
  
  
  if __name__ == '__main__':
  
      myScreen = Screen()
      myScreen.addPane("1")
      myScreen.addPane("2")
      myScreen.addPane("3")
      myScreen.addPane("4")
  
      while True:
          ev = pygame.event.get()
          for event in ev:
              if event.type == pygame.MOUSEBUTTONUP:
                  posx,posy = pygame.mouse.get_pos()
                  if (posx &gt;= 175 and posx &lt;= 375) and (posy &gt;= 75 and posy &lt;= 175):
                      print("BOB") #Printing bob was for test purposes.
  
          for event in pygame.event.get():        
              if event.type == pygame.QUIT:
                  pygame.quit(); sys.exit();
  </code></pre>
  
  <p>Thank-you in advance for your time and effort.</p>