def clamp_ip(self, *args):
        """Move rects in place according to clamp offset.

        *args is usually a single pygame.Rect instance or
        integers representing such instance (either
        isolated or in a sequence like a tuple or list).
        """
        ### get an union rect
        union = self.union_rect

        ### use it to retrieve the position in case of
        ### clamping and the current position

        clamped_pos = union.clamp(*args).topleft
        current_pos = union.topleft

        ### then move all rects by the distance needed
        ### to reach the clamped position
        self.move_ip(clamped_pos - Vector2(current_pos))
Move rects in place according to clamp offset.

        *args is usually a single pygame.Rect instance or
        integers representing such instance (either
        isolated or in a sequence like a tuple or list).
        
nodezator/rectsman/sizepos.py