def METHOD_NAME(self):
    """Calculate a size"""
    (total_halfx, total_halfy) = (self.rect.right, self.rect.top)
    if self._colorbar.orientation in ["bottom", "top"]:
        (total_major_axis, total_minor_axis) = (total_halfx, total_halfy)
    else:
        (total_major_axis, total_minor_axis) = (total_halfy, total_halfx)
    major_axis = total_major_axis * (1.0 -
                                     self._major_axis_padding)
    minor_axis = major_axis * self._minor_axis_ratio
    # if the minor axis is "leaking" from the padding, then clamp
    minor_axis = np.minimum(minor_axis,
                            total_minor_axis *
                            (1.0 - self._minor_axis_padding))
    return (major_axis, minor_axis)