def testWindowSize(self):
        """Test to see if window == too small for program to operate, and
        go into small window mode if necessary"""
        realmaxY, realmaxX = self.realstdscr.getmaxyx() # test size
        if realmaxY != self.realmaxY or realmaxX != self.realmaxX:
            self.resizeHandler()
        self.realmaxY, self.realmaxX = realmaxY, realmaxX
        #while self.realmaxX < 80 and not self.appState.playOnlyMode:
        while self.realmaxX < self.appState.minWindowWidth and not self.appState.playOnlyMode:
            self.smallWindowMode()   # go into small window loop.stdscr
Test to see if window == too small for program to operate, and
        go into small window mode if necessary
durdraw/durdraw_ui_curses.py