code: def get_script_str(self, reset=True):
          
          s = "\n".join(l for l in self._lines)
          if reset:
              self.reset()
          return s
docs: Returns a string with the script and reset the editor if reset is True