Skip to main content

TcxCustomEditButton Class

The base class for buttons displayed in an editor.

Declaration

TcxCustomEditButton = class(
    TCollectionItem
)

Remarks

An editor button is a button within the editor client area. Editor buttons implement built-in or custom editor functionality. Editors maintain a collection of buttons accessible through the Properties.Buttons property.

VCL Editors Library: An Editor with Three Buttons

An editor button can have a border and/or an opaque background depending on the parent editor’s look & feel settings.

VCL Editors Library: An Editor with Three Opaque Buttons

To execute custom code in response to a click on an editor button, you can associate the button with an action object (a TBasicAction descendant instance) or handle the parent editor’s Properties.OnButtonClick event.

Main API Members

The list below outlines key members of the TcxCustomEditButton class that allow you to configure editor buttons.

Action
Allows you to associate the editor button with an action object. A click on the button executes the associated action.
Caption | ContentAlignment
Specify the caption and its position within the button.
Default
Allows you to set the editor button as default. An editor can have only one default button at a time.
Enabled
Specifies if the editor button is enabled. If a user clicks the button when it is enabled, the parent editor raises the Properties.OnButtonClick event.
Hint
Specifies a hint for the editor button.
HotTrackMode
Allows you to switch between available hot-track modes for the editor button. This property has no effect if the Transparent property is set to True.
Glyph | ImageIndex
Specify a custom editor button glyph.
Kind | Mode
Allow you to switch between available button content types and usage scenarios.
LeftAlignment
Aligns the button to the left or right border of the parent editor.
Stretchable
Allows you to stretch the button together with the parent editor.
Transparent
Enables transparency for the editor button background.
Visible
Hides or displays the editor button.
Width
Allows you to explicitly specify the width of the editor button.

Terminal TcxCustomEditButton Class Descendants

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

TcxEditButton
A button displayed within an editor.
TdxBreadcrumbEditButton
A button displayed in a breadcrumb editor.

Inheritance

See Also