def pretty_str(self, indent: str="") -> str: """ :returns: A nicely formatted string describing the window, its tabs, and their sessions. """ session = indent + "Window id=%s frame=%s\n" % ( self.window_id, iterm2.util.frame_str(self.frame)) for tab in self.__tabs: session += tab.pretty_str(indent=indent + " ") return session