Skip to main content
Table of Contents

TTMSFNCToolBarButton.DropDownControl Property

Custom control to embed inside the button's drop-down popup. Assign any TControl descendant to show a custom picker or panel.

API unit family: TMSFNCToolBar Declaring type: TTMSFNCToolBarButton Inherited from: TTMSFNCDefaultToolBarButton Type: TControl

Syntax

FMX.TMSFNCToolBar.hppPascalC++
property DropDownControl: TControl;
__property Fmx::Controls::TControl* DropDownControl = {read=FDropDownControl, write=SetDropDownControl};

Usage examples

Attach a dropdown control to a toolbar button

Configures a toolbar button that opens an existing color picker as dropdown content.

Attach a dropdown control to a toolbar buttonPascalC++
procedure TForm1.ConfigureToolbarDropdown;
var
  Button: TTMSFNCToolBarButton;
begin
  Button := TMSFNCToolBar1.AddButton(120, 32, '', '', 'Color');
  Button.DropDownKind := ddkDropDownButton;
  Button.DropDownControl := TMSFNCColorPicker1;
  Button.DropDownWidth := 220;
  Button.DropDownHeight := 260;
end;
void __fastcall TForm1::ConfigureToolbarDropdown()
{
  TTMSFNCToolBarButton *Button = TMSFNCToolBar1->AddButton(120, 32, "", "", "Color");
  Button->DropDownKind = ddkDropDownButton;
  Button->DropDownControl = TMSFNCColorPicker1;
  Button->DropDownWidth = 220;
  Button->DropDownHeight = 260;
}

Read the related guide