RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TSpeedButton Class

TSpeedButton is a button that is used to execute commands or set modes.

Pascal
TSpeedButton = class(TGraphicControl);
C++
class TSpeedButton : public TGraphicControl;

Buttons

Use TSpeedButton to add a button to a group of buttons in a form. TSpeedButton introduces properties that can be used to set graphical images that represent the different button states (selected, unselected, disabled and so on). Use other properties to specify multiple images or to rearrange the images and text on the button. TSpeedButton also introduces properties that allow speed buttons to work together as a group. Speed buttons are commonly grouped in panels to create specialized tool bars and tool palettes. 

The recommended way to implement the response of the button when the user clicks on it is to assign an action from an action list as the value of the Action property. By setting the Action property, you make the button a client of the action, and the action handles updating the button's properties and responding when the user clicks the button. 

If you are not using an action to respond when the user clicks the button, then you can specify the button's response by writing an OnClick event handler.

Tip: To create a speed button with a client-aligned glyph that covers the button's edges, add a 1-pixel margin around the button's top and left edges and a 3-pixel margin around its bottom and right edges. Do this by manually editing the bitmap specified by the Glyph property.
 

 

TBitBtn 

TButton 

TToolButton 

Buttons and Similar Controls 

Speed Buttons 

Adding a Cool Bar Component 

Adding a Speed Button to a Panel 

Adding a Toolbar Using the Toolbar Component 

Adding a Tool Button 

Adding Hidden Toolbars 

Allowing Toggle Buttons 

Allowing Toggled Tool Buttons 

Assigning a Menu to a Tool Button 

Assigning a Speed Button's Glyph 

Assigning Images to Tool Buttons 

Creating a Group of Speed Buttons 

Creating Groups of Tool Buttons 

Hiding and Showing Toolbars 

Responding to Clicks 

Setting the Initial Condition of a Speed Button 

Setting Tool Button Appearance and Initial Conditions 

VCL Overview

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!