CheckGroupBox Class

Represents a GroupBox control with a CheckBox that can be checked or unchecked to enable or disable the content of the group box.

See the online help for an animated image example.

Definition

Namespace: KGySoft.WinForms.Controls
Assembly: KGySoft.WinForms (in KGySoft.WinForms.dll) Version: 5.0.1
C#
[ToolboxBitmapAttribute(typeof(CheckGroupBox), "Resources.Toolbox.CheckGroupBox.png")]
public class CheckGroupBox : GroupBox, 
	ICustomLocalizable, IToolTipTargetProvider
Inheritance
Object    MarshalByRefObject    Component    Control    GroupBox    CheckGroupBox
Implements
ICustomLocalizable, IToolTipTargetProvider

Examples

The following animated image illustrates the behavior of the CheckGroupBox class:

CheckGroupBox in the KGySoft.Drawing.ImagingTools application

  Tip

The image above is from the KGy SOFT Imaging Tools application, but you can also use the example application that has many CheckGroupBox instances on the controls test pages. At the Releases page of the project repository you can download its executable binaries.

Constructors

CheckGroupBox Initializes a new instance of the CheckGroupBox class.

Properties

CheckBox Gets the AdvancedCheckBox control, which serves as the checkbox of the CheckGroupBox control.
Checked Gets or sets whether the CheckBox of the CheckGroupBox control is checked. When checked, the content of the group box is enabled, otherwise it is disabled.
Default value: .
FlatStyle Gets or sets the flat style appearance of the CheckBox and the GroupBox.
Default value: Standard.
ForeColorGets or sets the foreground color of the control.
(Overrides ControlForeColor)
Text Gets or sets the text of the CheckGroupBox. That is, the text of the CheckBox control.
(Overrides GroupBoxText)
UseCompatibleTextRendering Gets or sets whether to use the text rendering engine compatible with .NET Framework 1.x (GDI+) or not (GDI).
Default value: .

Methods

DisposeReleases the unmanaged resources used by the Control and its child controls and optionally releases the managed resources.
(Overrides ControlDispose(Boolean))
OnCheckedChanged Raises the CheckedChanged event.
OnHandleCreatedRaises the HandleCreated event.
(Overrides ControlOnHandleCreated(EventArgs))
OnPaintRaises the Paint event.
(Overrides GroupBoxOnPaint(PaintEventArgs))
OnPaintBackgroundPaints the background of the control.
(Overrides ControlOnPaintBackground(PaintEventArgs))
OnRightToLeftChangedRaises the RightToLeftChanged event.
(Overrides ControlOnRightToLeftChanged(EventArgs))
OnSizeChangedRaises the SizeChanged event.
(Overrides ControlOnSizeChanged(EventArgs))
OnTextChangedRaises the TextChanged event.
(Overrides ControlOnTextChanged(EventArgs))
WndProcProcesses Windows messages.
(Overrides GroupBoxWndProc(Message))

Events

CheckedChanged Occurs when the CheckBox is checked or unchecked.

Extension Methods

GetFormatFlags Gets the formatting flags for the text of a custom drawn control.
(Defined by ControlExtensions)
GetScale Gets the current scale factor of the specified control. If per-monitor DPI awareness is not enabled, it always returns SystemScale.
(Defined by ScaleHelper)
GetScrollBarSize Gets the recommended width and height of scrollbars matching the current scaling of the specified control.
(Defined by ScaleHelper)
HasDefaultScaling Gets whether the display that the specified control belongs to has the same DPI as the initial DPI of the primary display.
(Defined by ScaleHelper)
ScaleHeight Scales the specified height by the vertical scale factor of the control.
(Defined by ScaleHelper)
ScaleSize Scales the specified size by the scale factor of the control.
(Defined by ScaleHelper)
ScaleWidth Scales the specified width by the horizontal scale factor of the control.
(Defined by ScaleHelper)
SetControlEnabled Sets the Enabled property of the child controls within the specified root control, or the Enabled property of the specified control itself, if it is not a recognized container control. By this way pages of a TabControl will remain selectable, a SplitContainer remains resizable, etc.
(Defined by ControlExtensions)
SetControlReadonly Recursively sets the read-only state in the children of the specified root control. Affects TextBoxBase and IReadOnlyCapable instances.
(Defined by ControlExtensions)
SetDoubleBuffered Sets the double buffered state of a control
(Defined by ControlExtensions)
SetStyle Sets a specified ControlStyles flag to either or . It calls the protected Control.SetStyle method on the specified control as if it was a public method.
(Defined by ControlExtensions)

See Also