RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
Buttons.DrawButtonFace Function

Draws a push button.

Pascal
function DrawButtonFace(Canvas: TCanvas; const Client: TRect; BevelWidth: Integer; Style: TButtonStyle; IsRounded: Boolean; IsDown: Boolean; IsFocused: Boolean): TRect;
C++
TRect DrawButtonFace(TCanvas Canvas, const TRect Client, int BevelWidth, TButtonStyle Style, Boolean IsRounded, Boolean IsDown, Boolean IsFocused);

Use DrawButtonFace to draw a standard push button. DrawButtonFace draws the borders and background of the button. DrawButtonFace can be used by button controls that do not descend from TButtonControl, which must implement all their own rendering. 

Canvas is the drawing surface on which to render the button. 

Client indicates the boundaries of the button's client area on Canvas. 

BevelWidth is the width of the beveled edge on the outside of the button. This parameter is ignored. 

IsDown indicates whether the button is depressed. 

IsFocused indicates whether the button has keyboard focus. 

IsRounded indicates whether the button is a rounded button. 

Style describes the button style to be used, according to the parameters of TButtonStyle

DrawButtonFace returns the dimensions of the remaining usable area on the surface of the button after the edges and bevels have been drawn. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!