(self, fmt)
Returns a context manager that invokes set_format(fmt) on enter,
        and restores the old format on exit.
Returns a context manager that invokes set_format(fmt) on enter,
        and restores the old format on exit.
Returns a context manager that invokes set_format ( fmt ) on enter and restores the old format on exit .
def using_format(self, fmt):
        """
        Returns a context manager that invokes set_format(fmt) on enter,
        and restores the old format on exit.
        """
        old_repr = self._repr
        self.set_format(fmt)
        yield
        self._repr = old_repr
def using_format ( self , fmt ) : old_repr = self . _repr self . set_format ( fmt ) yield self . _repr = old_repr