TcxEditButton Class
A button displayed within an editor.
Declaration
TcxEditButton = class(
TcxCustomEditButton
)
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.
An editor button can have a border and/or an opaque background depending on the parent editor’s look & feel settings.
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 TcxEditButton
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
- Specifies 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.
Direct TcxEditButton Class Reference
The TcxEditButtons.Items property references a TcxEditButton
object.