Size::ClampedToWidth

Size::ClampedToWidth
inline Size<T> ClampedToWidth(T w) const;
Description

ClampedToWidth clamps the current Width to an alternate value. The lesser value is chosen. The following expression may be used to represent the result:

   (result.Width, result.Height) = (min(Width, w), Height)
Parameters
Parameters 
Description 
T w 
A value that is clamped to the Width component of the current size. 
Return Value

A new Size whose Height is equal to that of the current size, and whose Width represents the clamp of the current Width with a passed value.

See Also