GroupBox
Namespace: Wisej.Web
Assembly: Wisej.Framework (4.1.0.0)
Represents a Wisej control that displays a frame around a group of controls with an optional caption.
- C#
- VB.NET
public class GroupBox : Control
Public Class GroupBox
Inherits Control
Constructors
GroupBox()
Initializes a new instance of the GroupBox class.
GroupBox(text, controls)
Initializes a new instance of the GroupBox class with the specified text.
| Name | Type | Description |
|---|---|---|
| text | String | The text to display on the GroupBox. |
| controls | Control[] | An array of control objects to add to the GroupBox. |
GroupBox(text, location, size, controls)
Initializes a new instance of the GroupBox class with the specified controls, text, and collapsed state.
| Name | Type | Description |
|---|---|---|
| text | String | The text to display on the GroupBox. |
| location | Point | Initial location. |
| size | Size | Initial size. |
| controls | Control[] | An array of control objects to add to the GroupBox. |
Properties
AllowHtml
Boolean: Returns or sets a value indicating that the control can display html in the Text property. (Default: False)
AutoSize
Boolean: Returns or sets a value that indicates whether the GroupBox resizes based on its contents. (Default: False)
Value: true if the GroupBox automatically resizes based on its contents; otherwise, false. The default is true.
AutoSizeMode
AutoSizeMode: Returns or sets the mode by which the Button automatically resizes itself. (Default: GrowOnly)
Value: One of the AutoSizeMode values. The default value is GrowOnly.
Checked
Boolean: Gets or sets whether the checkbox next to the group box title is checked or unchecked. (Default: True)
Value: true if the group box is checked; otherwise, false. The default is false.
Collapsed
Boolean: Returns or sets a value that indicates whether the GroupBox is collapsed or expanded. (Default: False)
CollapsedBounds
Rectangle: Returns the collapsed bounds.
DefaultPadding
Padding: Returns the Padding structure that contains the default padding settings for a GroupBox control.
Value: A Padding with all its edges set to three pixels.
DisplayRectangle
Rectangle: Returns a rectangle that represents the inner dimensions of the GroupBox control.
Value: A Rectangle with the inner dimensions of the GroupBox control.
RightToLeftLayout
Boolean: Enables or disables right-to-left layout when the value of RightToLeft is Yes (Default: False)
Value: true if right-to-left layout is turned on; otherwise, false. The default is false.
Selectable 2.5.22+
Boolean: Returns or sets whether the text in the control can be selected in the browser by the user by dragging the pointer. (Default: True)
Value: true to make the text selectable; otherwise, false. The default is false.
Not to be confused with Selectable, which corresponds to the Focusable property. When Selectable is set to true, the text of the control (i.e. a label or a button) can be highlighted in the browser and copied to the clipboard. It will also make the widget "focusable" but only in the browser.
ShowCheckBox
Boolean: Gets or sets whether the group box shows a checkbox next to the text. (Default: False)
ShowCloseButton
Boolean: Returns or sets a value that indicates the GroupBox displays the open/close button next to the title. (Default: False)
UseMnemonic
Boolean: Returns or sets whether the first character that is preceded by an ampersand (&) is used as the mnemonic key of the control. (Default: True)
Value: true if the first character that is preceded by an ampersand (&) is used as the mnemonic key of the control; otherwise, false. The default is true.
Methods
OnCheckedChanged(e)
Fires the CheckedChanged event.
OnControlAdded(e)
Fires the ControlAdded event.
| Parameter | Type | Description |
|---|---|---|
| e | ControlEventArgs | A ControlEventArgs that contains the event data. |
OnGroupBoxCollapsed(e)
Fires the GroupBoxCollapsed event.
OnGroupBoxExpanded(e)
Fires the GroupBoxExpanded event.
OnRightToLeftLayoutChanged(e)
Fires the RightToLeftLayoutChanged event.
OnWebEvent(e)
| Parameter | Type | Description |
|---|---|---|
| e | WisejEventArgs |
OnWebRender(config)
| Parameter | Type | Description |
|---|---|---|
| config | Object |
SetBoundsCore(x, y, width, height, specified)
Sets the specified bounds of the GroupBox control.
| Parameter | Type | Description |
|---|---|---|
| x | Int32 | The new Left property value of the control. |
| y | Int32 | The new Top property value of the control. |
| width | Int32 | The new Width property value of the control. |
| height | Int32 | The new Height property value of the control. |
| specified | BoundsSpecified | A combination of the BoundsSpecified values. |
Events
CheckedChanged
EventHandler Fired when the value of the Checked property changes.
GroupBoxCollapsed
EventHandler Fired when the groupbox is collapsed.
GroupBoxExpanded
EventHandler Fired when the groupbox is expanded.
RightToLeftLayoutChanged
EventHandler Fired when the value of the RightToLeftLayout property changes.
Implements
| Name | Description |
|---|---|
| IUserData | Provides access to the UserData and Tag properties associated to the component implementing this interface. |
| IBindableComponent | Bindable components implement this interface. |
| IDropTarget | Controls that support drag & drop operations implement this interface. |
| IWisejComponent | All wisej components implement this interface. |
| IWisejControl | All wisej controls derived from the Control class must implement this interface. |
| IWisejSerializable | Allows an object to serialize itself. |