ComponentFactory.Krypton.Toolkit.ViewLayoutMetricSpacer.GetPreferredSize C# (CSharp) Method

GetPreferredSize() public method

Discover the preferred size of the element.
public GetPreferredSize ( ViewLayoutContext context ) : Size
context ViewLayoutContext Layout context.
return System.Drawing.Size
        public override Size GetPreferredSize(ViewLayoutContext context)
        {
            Debug.Assert(context != null);

            // Get the sizing metric
            int length = _paletteMetric.GetMetricInt(ElementState, _metricInt);

            // Use the same size for vertical and horizontal
            return new Size(length, length);
        }