Back to Devexpress

TcxCustomCheckBox Class

vcl-cxcheckbox-74f4f450.md

latest5.0 KB
Original Source

TcxCustomCheckBox Class

The base class for unbound and data-aware check box editors.

Declaration

delphi
TcxCustomCheckBox = class(
    TcxCustomEdit
)

Remarks

A check box editor allows users to switch between two or three states of an option.

Main API Members

The list below outlines key members of the TcxCustomCheckBox class. These members allow you to configure check box editors.

Appearance Settings

Style | StyleDisabled | StyleFocused | StyleHot | StyleReadOnly

Allow you to define individual appearance settings for different editor states.

Tip

To apply the same style settings to multiple editors, use a TcxEditStyleController component. If you need to apply the same style settings to all editors in your application, you can use a TcxDefaultEditStyleController component.

StylesProvides access to individual styles applied to the editor in different states.TransparentSpecifies if the check box is transparent in GDI render mode.

Content-Related APIs

CheckedSpecifies if the editor is checked or unchecked.EditValueSpecifies the edit value.State | Toggle

Switch between checked, unchecked, and grayed states.

Note

You need to set the Properties.AllowGrayed property to True to add the grayed (intermediate) state to the check box editor.

Editor Settings and Repository Items

ActivePropertiesProvides access to the current check box settings regardless of their source. This property set does not allow you to customize editor settings.GetPropertiesClassReturns the actual editor settings type.PropertiesAllows you to customize check box settings directly if the editor does not have an assigned repository item.RepositoryItemSpecifies a repository item as an external source of check box settings. A repository item has priority over other editor settings.

General-Purpose API Members

EnabledSpecifies if the editor is enabled.CanModify

Identifies if the editor is in read-only mode.

Tip

You can use the Properties.ReadOnly property to enable or disable read-only mode for the check box editor.

ShowHintSpecifies if the standalone editor can display hints. To enable hints for an in-place editor in a container control, set its OptionsBehavior.CellHints[1] property to True.

Terminal TcxCustomCheckBox Class Descendants

Do not use the TcxCustomCheckBox class directly. Use the following descendants instead:

TcxCheckBoxAn unbound check box editor.TcxDBCheckBoxA data-aware check box editor.

Inheritance

Show 12 items

TObject TPersistent TComponent TControl TWinControl TCustomControl TcxCustomControl TcxControl TcxContainer TcxCustomEditContainer TcxCustomEdit TcxCustomCheckBox

Footnotes

  1. Set the following behavior properties to True or False to enable or disable in-place editor hints in corresponding container controls:

See Also

TcxCustomCheckBox Members

cxCheckBox Unit