def leave_diff_mode(self):
        """Leave diff mode."""
        assert self.diff_mode
        self.diff_mode = False
        self.diff_context_model = None
        self.diff_from_source = False
        self.setColumnCount(2)
        self.refresh()