HeaderPane
Main
Hide

SftButton/DLL 3.0 - Button Control

Share Link
Print

Borders

The button's border is selected through the nBorderStyle field on SFTBUTTON_CONTROL. Three styles are supported:

StyleAppearance
SFTBUTTON_BORDER_THIN (0)A thin single-pixel border. Useful for dense toolbars and flat designs.
SFTBUTTON_BORDER_STANDARD (1)The classic raised-edge 3D border. This is the default.
SFTBUTTON_BORDER_PIXEL1 (2)A single-pixel flat border drawn with the appropriate edge color. Useful for strongly colored buttons where the 3D edge would clash.

By default, the border is drawn only when the button is in the pressed, hover or focus state. Set fBorderAlways to TRUE to draw the border in every state.

3D edge colors

colorDarkEdge, colorLightEdge, colorShadowEdge and colorWhiteEdge on SFTBUTTON_CONTROL control the four facets of the 3D edge that SFTBUTTON_BORDER_STANDARD draws. Each field can be SFTBUTTON_NOCOLOR to use the appropriate system color (COLOR_3DDKSHADOW, COLOR_3DLIGHT, COLOR_3DSHADOW, COLOR_3DHIGHLIGHT). See Colors and Gradients.

Theme

When Windows themes are active (nUseThemes SFTBUTTON_THEME_YES), the theme paints the border; caller-supplied edge colors are ignored. Themes are automatically suppressed when dark mode or high contrast is active. See Using Themes.

Default-button outline

A button marked as the dialog default (fDefault TRUE) renders an extra outline around the border. Set fHideDefault to TRUE to suppress that outline if the application supplies its own default-button visual.


Last Updated 04/25/2026 - (email)
© 2026 Softel vdm, Inc.