def METHOD_NAME(self):
    if not self.file.closed and self.file.isatty():
        # ANSI Control Sequence DECTCEM 2 does not work in Jupyter
        self.file.write("\033[?25h")
        self.file.flush()