HypernovaDesktop Components · docs
Binarymission
WinFormsExtended Group Box › AdvancedGroupBox

AdvancedGroupBox

class.NET 6 / 8 / 10.NET Framework 4.8Binarymission.WinForms.Controls.Containers

The AdvancedGroupBox is a custom .NET Control that is designed to work as a features-rich, extended and instant replacement for the standard .NET GroupBox control.

public partial class AdvancedGroupBox : GroupBox

Inherits from / implements: GroupBox

Remarks

The Control's features include:

  • Customizable border color and styles (including dotted border)
  • Customizable border thickness
  • Customize separate font for Header text and the rest of the group-box control
  • Draw the Group-box background with either Linear gradient brush or a solid brush, with colors that you can choose
  • Draw the group-box's Header text area with border and a background, with header section border thickness and color customizable as well
  • Customize the left and right margin around the group-box header text
  • Customize the padding for the group-box border
  • Choose between drawing the group-box border to any location in the control - i.e. left aligned or right-aligned, or even center-aligned
  • Members at a glance

    AdvancedGroupBoxInitializes a new instance of the AdvancedGroupBox class.
    BackgroundBrushColor1Gets or sets the background brush color 1.
    BackgroundBrushColor2Gets or sets the background brush color 2.
    BorderColorGets or sets the color of the border.
    BorderThicknessGets or sets the border thickness.
    ControlBorderStyleGets or sets the control border style.
    DottedBorderDepthGets or sets the dotted border depth.
    DottedBorderGapGets or sets the dotted border gap.
    HeaderAlignmentGets or sets the header alignment.
    HeaderBackgroundColor1Gets or sets the header background color 1.
    HeaderBackgroundColor2Gets or sets the header background color 2.
    HeaderBackgroundLeftMarginGets or sets the header background left margin.
    HeaderBackgroundLinearGradientBrushGradientAngleGets or sets the header background linear gradient brush gradient angle.
    HeaderBackgroundRightMarginGets or sets the header background right margin.
    HeaderBorderColorGets or sets the color of the header border.
    HeaderBorderThicknessGets or sets the header border thickness.
    HeaderExtraHeightFactorGets or sets the header extra height factor.
    HeaderFontGets or sets the header text font.
    HeaderForeColorGets or sets the foreground color of the header text.
    HeaderSolidBrushBackgroundColorGets or sets the color of the header solid brush background.
    IsBackgroundDrawingUsingLinerGradientBrushGets or sets a value indicating whether the control draws its background using a LinearGradientBrush.
    IsHeaderBackgroundDrawingEnabledGets or sets a value indicating whether the control draws its header background.
    IsHeaderBackgroundGradientGets or sets a value indicating whether the control draws its header background with gradient brush.
    IsHeaderBorderDrawingEnabledGets or sets a value indicating whether the control should draw its header border.
    LinearGradientBrushGradientAngleGets or sets the linear gradient brush gradient angle.
    RoundedCornerTargetsGets or sets the rounded corner targets.
    RoundedCornersAngleGets or sets the rounded corners angle.
    ShouldDrawRoundedCornersGets or sets a value indicating whether the control should draw rounded corners.
    ShouldUpdateChildrenUponParentFormMoveSizeGets or sets a value indicating whether the control should update children upon parent form move or resize.
    TextLeftMarginGets or sets the Group box text left margin.
    TextRightMarginGets or sets the Group box text right margin.
    OnHandleCreatedRaises the HandleCreated event. AdvancedGroupBox overrides it so the control's own handling runs alongside the base behavior.
    OnPaintRaises the Paint event. AdvancedGroupBox overrides it so the control's own handling runs alongside the base behavior.

    Constructors

    AdvancedGroupBox

    public AdvancedGroupBox()

    Initializes a new instance of the AdvancedGroupBox class.

    Properties

    BackgroundBrushColor1

    public Color BackgroundBrushColor1

    Gets or sets the background brush color 1.

    BackgroundBrushColor2

    public Color BackgroundBrushColor2

    Gets or sets the background brush color 2.

    BorderColor

    public Color BorderColor

    Gets or sets the color of the border.

    BorderThickness

    public float BorderThickness

    Gets or sets the border thickness.

    ControlBorderStyle

    public GroupBoxBorderStyle ControlBorderStyle

    Gets or sets the control border style.

    DottedBorderDepth

    public int DottedBorderDepth

    Gets or sets the dotted border depth.

    DottedBorderGap

    public int DottedBorderGap

    Gets or sets the dotted border gap.

    HeaderAlignment

    public GroupBoxHeaderAlignment HeaderAlignment

    Gets or sets the header alignment.

    HeaderBackgroundColor1

    public Color HeaderBackgroundColor1

    Gets or sets the header background color 1.

    HeaderBackgroundColor2

    public Color HeaderBackgroundColor2

    Gets or sets the header background color 2.

    HeaderBackgroundLeftMargin

    public int HeaderBackgroundLeftMargin

    Gets or sets the header background left margin.

    HeaderBackgroundLinearGradientBrushGradientAngle

    public float HeaderBackgroundLinearGradientBrushGradientAngle

    Gets or sets the header background linear gradient brush gradient angle.

    HeaderBackgroundRightMargin

    public int HeaderBackgroundRightMargin

    Gets or sets the header background right margin.

    HeaderBorderColor

    public Color HeaderBorderColor

    Gets or sets the color of the header border.

    HeaderBorderThickness

    public int HeaderBorderThickness

    Gets or sets the header border thickness.

    HeaderExtraHeightFactor

    public int HeaderExtraHeightFactor

    Gets or sets the header extra height factor.

    HeaderFont

    public Font HeaderFont

    Gets or sets the header text font.

    HeaderForeColor

    public Color HeaderForeColor

    Gets or sets the foreground color of the header text.

    HeaderSolidBrushBackgroundColor

    public Color HeaderSolidBrushBackgroundColor

    Gets or sets the color of the header solid brush background.

    IsBackgroundDrawingUsingLinerGradientBrush

    public bool IsBackgroundDrawingUsingLinerGradientBrush

    Gets or sets a value indicating whether the control draws its background using a LinearGradientBrush.

    IsHeaderBackgroundDrawingEnabled

    public bool IsHeaderBackgroundDrawingEnabled

    Gets or sets a value indicating whether the control draws its header background.

    IsHeaderBackgroundGradient

    public bool IsHeaderBackgroundGradient

    Gets or sets a value indicating whether the control draws its header background with gradient brush.

    IsHeaderBorderDrawingEnabled

    public bool IsHeaderBorderDrawingEnabled

    Gets or sets a value indicating whether the control should draw its header border.

    LinearGradientBrushGradientAngle

    public float LinearGradientBrushGradientAngle

    Gets or sets the linear gradient brush gradient angle.

    RoundedCornerTargets

    public GroupBoxCornerTargets RoundedCornerTargets

    Gets or sets the rounded corner targets.

    RoundedCornersAngle

    public float RoundedCornersAngle

    Gets or sets the rounded corners angle.

    ShouldDrawRoundedCorners

    public bool ShouldDrawRoundedCorners

    Gets or sets a value indicating whether the control should draw rounded corners.

    ShouldUpdateChildrenUponParentFormMoveSize

    public bool ShouldUpdateChildrenUponParentFormMoveSize

    Gets or sets a value indicating whether the control should update children upon parent form move or resize.

    TextLeftMargin

    public int TextLeftMargin

    Gets or sets the Group box text left margin.

    TextRightMargin

    public int TextRightMargin

    Gets or sets the Group box text right margin.

    Methods

    OnHandleCreated

    protected override void OnHandleCreated(EventArgs e)

    Raises the HandleCreated event. AdvancedGroupBox overrides it so the control's own handling runs alongside the base behavior.

    e
    The data for the event.

    OnPaint

    protected override void OnPaint(PaintEventArgs e)

    Raises the Paint event. AdvancedGroupBox overrides it so the control's own handling runs alongside the base behavior.

    e
    The data for the event.