Sign in Join
FPDoc Onlineexperiment

TToggleBox.AllowGrayed property

Member of TToggleBoxpublishedIn unit StdCtrls

Allows the check box to use a "grayed" state.

Declaration

pascal
property AllowGrayed:;

Description

If AllowGrayed is set to True, the check box has three possible values in the State property: checked, unchecked and grayed. If AllowGrayed is set to False, the check box has only two possible states: checked and unchecked.

This description is the one of StdCtrls.TCustomCheckBox.AllowGrayed.

See also

Example: tcustomcheckbox_allowgrayed.pas

pascal
{ This example uses a check box on a form. When the application runs, 
  the check box is initially checked. When the user clicks it,
  the check box is unchecked. Clicking it again grays the check box. }
procedure TForm1.FormCreate(Sender: TObject);
begin
  Checkbox1.AllowGrayed := True;
  Checkbox1.State := cbChecked;
end;

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.