ComponentFactory.Krypton.Toolkit.ButtonSpecFormWindowMin.GetVisible C# (CSharp) Method

GetVisible() public method

Gets the button visible value.
public GetVisible ( IPalette palette ) : bool
palette IPalette Palette to use for inheriting values.
return bool
        public override bool GetVisible(IPalette palette)
        {
            // We do not show if the custom chrome is combined with composition,
            // in which case the form buttons are handled by the composition
            if (KryptonForm.ApplyComposition && KryptonForm.ApplyCustomChrome)
                return false;

            // The minimize button is never present on tool windows
            switch (KryptonForm.FormBorderStyle)
            {
                case FormBorderStyle.FixedToolWindow:
                case FormBorderStyle.SizableToolWindow:
                    return false;
            }

            // Have all buttons been turned off?
            if (!KryptonForm.ControlBox)
                return false;

            // Has the minimize/maximize buttons been turned off?
            if (!KryptonForm.MinimizeBox && !KryptonForm.MaximizeBox)
                return false;

            return true;
        }